Skip to content
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

Added required attribute to settings/plugins, refactor: allValues #5224

Merged
merged 4 commits into from
Jul 11, 2023

Conversation

wolflu05
Copy link
Contributor

@wolflu05 wolflu05 commented Jul 11, 2023

Needed for #4824 and also pretty handy for current plugins.

  • added required attribute to InvenTreeBaseSetting
  • added check_all_settings
  • added all_settings to get a dict of all defined settings including the InvenTreeBaseSetting object
  • refactored allValues to use new all_settings function
  • added docs for new check_settings function on plugin SettingsMixin

- added 'required' attribute to InvenTreeBaseSetting
- added 'check_all_settings'
- added 'all_settings' to get a list of all defined settings
- refactored 'allValues' to use new 'all_settings' function
- added docs for new 'check_setting' function on plugin SettingsMixin
@wolflu05 wolflu05 added enhancement This is an suggested enhancement or new feature plugin Plugin ecosystem refactor labels Jul 11, 2023
@wolflu05
Copy link
Contributor Author

Seems like the coveralls reporter broke due to some permissions. My last PR used v0.5.2 and it uploaded fine, also the last run with v0.6.0 from matmair worked. They changed to use a gzip algorithm between these changes. Would needed it this time actually to add some tests to cover the new updates.

Copy link
Member

@matmair matmair left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@matmair
Copy link
Member

matmair commented Jul 11, 2023

Coveralls does that from times to times, maybe try rerunning the action in a few hours. Their CI failing is a constituent joke around python devs.

@wolflu05 wolflu05 mentioned this pull request Jul 11, 2023
4 tasks
@wolflu05
Copy link
Contributor Author

wolflu05 commented Jul 11, 2023

This PR would be ready from my POV for review. (it also increases the coverage +0.04%)

@SchrodingersGat
Copy link
Member

Looks good, thanks @wolflu05

@SchrodingersGat SchrodingersGat merged commit ee27473 into inventree:master Jul 11, 2023
@wolflu05 wolflu05 deleted the feature/required-settings branch July 12, 2023 09:35
@wolflu05 wolflu05 mentioned this pull request Jul 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement This is an suggested enhancement or new feature plugin Plugin ecosystem refactor
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants