Make Lima a python namespace package #116
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
rationale
It would be nice for external lima python software to share the Lima namespace.
Example: If someone is writing a python camera plugin for Lima it would be nice if after installing,
it could be used with:
It could be done if Lima becomes a python namespace package (see here).
But for this it is necessary that all packages (including Lima itself) reduce their
Lima/__init__.py
to a single line:
Check here for a sample project using this python feature.
I propose also to add this information to the documentaion if the idea behind this PR is accepted so please don't merge the PR until I do!
Doubts
Seems the existing code in
Lima/__init__.py
is never activated becauseget_os
seems to be alwaysNone
. I assumed this was some old code that can be removed.`Also, it forces
LIMA_LINK_STRICT_VERSION
. I search the entire Lima project and I could not find any place where it could be used so I also assumed it can be removed.