fix(keys): force gc collection in keys setup to reduce memory fragmentation, probably at cost of performance

This commit is contained in:
Josh Klar committed 2021-06-20 13:55:18 -07:00
1 parent 6f8eb425b1
commit aeee945728
1 file changed
+3
+3
View File
@@ -1,3 +1,4 @@
import gc
from micropython import const
import kmk.handlers.stock as handlers
@@ -804,6 +805,8 @@ def make_key(code=None, names=tuple(), type=KEY_SIMPLE, **kwargs): # NOQA
register_key_names(key, names)
gc.collect()
return key