golemfactory / golem-core-python

GNU General Public License v3.0
3 stars 2 forks source link

Refactored modules structure #95

Closed approxit closed 1 year ago

approxit commented 1 year ago

Brace yourselves, massive change diff is coming!

What I've done:

Imports are organized in following way:

That way, we can keep __init__.py clear enough to have stuff exposed for external use, when internal imports are not polluting everything.

For both scenarios I've chosen to use absolute imports, but maybe local imports for non-external stuff could be used too. We could also go with third path, where external imports are used from __init__.py but internal imports are imported separately from specific module.

Also, I'm not sure what suitable way could be done at the highest core level regarding imports. As modules are golem-api-based, it seems like its fair idea, but how about other modules like golem_node?

approxit commented 1 year ago

I haven't noticed that kind of mass-change fail. I've looked trough whole diff and found lots of other issues regarding this. It should be now fixed.