Hashfyre / pyzure-cli

A CLI tool for Microsoft Azure Storage and Service Bus operations, built on Azure Python SDK, functionally a clone of azure-xplat-cli built on Azure NodeJS SDK
MIT License
1 stars 0 forks source link

More Pythonic nested import of modules. #21

Open 5310 opened 8 years ago

5310 commented 8 years ago

Currently we're using the sys.path.append() way of importing nested modules. And as page 26 of the linked presentation mentions, it gets the job done, but feels dirty.

There's still the alternative of adding an __init__.py at every nested level to handle normal Pythonic imports of nested modules though, as described in pages 30 and 31 of the same. Of course, it's more work, but feels less dirty? (I personally find dunder names to be pretty dirty regardless, but that's how Python rolls, so who'm I to complain!)

Perhaps we should evaluate it?

Hashfyre commented 8 years ago

Going through the presentation.