Skip to content

Conversation

@d3m3vilurr
Copy link

if call DeviceManager outside of the module, self.code['type_codes']
could be always empty

if call `DeviceManager` outside of the module, `self.code['type_codes']`
could be always empty
@rirze
Copy link

rirze commented Apr 28, 2020

This is such a critical bug that hasn't been merged yet...

The original code has a generator for the value of self.code['type_codes']. When the first instantiation of DeviceManager is created on module import, it exhausts the generator, meaning that any future instances of DeviceManager won't have any values for self.code['type_codes']. This PR is definitely the way to go-- by converting the whole data structure from a generator to the actual values so they can be reused.

Alas, I hope the contributor(s) merge this and other features.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants