-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Documented that nothing should be defined outside the plugin class in Python storage plugins #867
Merged
jesper-friis
merged 6 commits into
master
from
866-document-that-dlite-plugins-should-not-define-anything-outside-the-plugin-class
Jul 3, 2024
Merged
Changes from all commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
8183180
Added warnings about defining stuff outside the plugin class in Pytho…
jesper-friis 8126195
Merge branch 'master' into 866-document-that-dlite-plugins-should-not…
jesper-friis 65e1594
Added example help function to the storage plugin template.
jesper-friis 2afbb72
Merge branch '866-document-that-dlite-plugins-should-not-define-anyth…
jesper-friis e0048d4
Removed @staticmethod from the example method
jesper-friis 0656af6
Merge branch 'master' into 866-document-that-dlite-plugins-should-not…
jesper-friis File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good, but can we add an example in https://github.com/SINTEF/dlite/blob/master/doc/user_guide/storage_plugin.py (doen't matter if it is not used), and in the template?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you mean the note added on line 3 in https://github.com/SINTEF/dlite/blob/81261950afd235dd4c280103bcca798c46ec9463/doc/user_guide/storage_plugin.py?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No I was thinking more along the lines
class plugin....:
....
...
def _local_help_function():
""" An optional class method or a function if desired.
Note that no functions or variables should be set outside the class
for a DLite plugin python file.
""
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added an example help method to the storage plugin template