You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@Ovnuniarchos Do you have a full example code that includes "changes made on the GDScript side"?
I was encountering the AFAICT original issue which appears to be gone in 9eceb16 (although I didn't try @bruvzg's specific example) so I wondered what was different with what you were observing and if I understood what you meant by "changes made on the GDScript side".
Related to what I'm trying to summarize here: #417
I tried reproducing it on Windows but was unable to do so. I used a library compiled in debug mode.
I tested in Godot 3.2.3 stable and some version of Godot 3.2.4 dated from december 2020. Using -v for verbose output, nothing showed up.
All my code is doing is this:
functest_pool_byte_array(): # Called from _readyprint("BEGIN test_pool_byte_array")
vartest=CustomReference.new()
vardata=PoolByteArray([1, 2, 3])
test.test_pool_byte_array(data)
# data[0] = 42 # Also tried this, no problemprint("END test_pool_byte_array")
C++:
voidCustomReference::test_pool_byte_array(godot::PoolByteArray data) {
PoolByteArray::Read r = data.read();
}
To properly figure this out, we need an actual minimal reproduction project (MRP), because it's still not clear under which circumstances this problem occurs (if it still occurs).
FYI there was a PR back in december 2019 which fixed a leak in PoolArrays: #355
Update: we found various cases of leaks when some methods of Dictionary and Array are used, like values() or duplicate(). The leak then becomes apparent when they contain either poolarrays or resources (and curiously doesn't otherwise). However, we could not find an issue with PoolArrays yet.
Seems like my example is faulty as it pertains to having a PoolArray or Resource in an Array and then duplicating it (or Dictionary and values()), as mentioned by @Zylann in the post above
Activity
Ovnuniarchos commentedon Jan 3, 2020
Confirmed in commit 7cbb846. Any PoolArray, even if it's not accessed, will leak as soon as a change is made on any of the PAs (GDS side or GDN side).
Ovnuniarchos commentedon Jun 13, 2020
Still failing in commit 9eceb16 , but only changes made on the GDScript side trigger the leak.
follower commentedon Jun 22, 2020
@Ovnuniarchos Do you have a full example code that includes "changes made on the GDScript side"?
I was encountering the AFAICT original issue which appears to be gone in 9eceb16 (although I didn't try @bruvzg's specific example) so I wondered what was different with what you were observing and if I understood what you meant by "changes made on the GDScript side".
Related to what I'm trying to summarize here: #417
2shady4u commentedon Jan 6, 2021
@follower I'm still having this issue on the latest master for my SQLite plugin:
https://github.com/2shady4u/godot-sqlite/tree/feature-add-blobs
So I don't think it's fixed yet? 🤔
Zylann commentedon Jan 6, 2021
I tried reproducing it on Windows but was unable to do so. I used a library compiled in debug mode.
I tested in Godot 3.2.3 stable and some version of Godot 3.2.4 dated from december 2020. Using
-vfor verbose output, nothing showed up.All my code is doing is this:
C++:
To properly figure this out, we need an actual minimal reproduction project (MRP), because it's still not clear under which circumstances this problem occurs (if it still occurs).
FYI there was a PR back in december 2019 which fixed a leak in PoolArrays: #355
Zylann commentedon Jan 6, 2021
Update: we found various cases of leaks when some methods of
DictionaryandArrayare used, likevalues()orduplicate(). The leak then becomes apparent when they contain either poolarrays or resources (and curiously doesn't otherwise). However, we could not find an issue with PoolArrays yet.2shady4u commentedon Jan 6, 2021
Seems like my example is faulty as it pertains to having a PoolArray or Resource in an
Arrayand then duplicating it (orDictionaryandvalues()), as mentioned by @Zylann in the post above