PEP fixes

This commit is contained in:
Matthias 2022-01-10 02:15:58 +01:00
parent e80a71eb46
commit 7d160039b1
No known key found for this signature in database
GPG Key ID: F50EF5741D33E076
5 changed files with 5 additions and 1 deletions

View File

@ -21,6 +21,7 @@ from .status import is_worker_running
from plugin import plugin_registry
class InfoView(AjaxView):
""" Simple JSON endpoint for InvenTree information.
Use to confirm that the server is running, etc.

View File

@ -7,6 +7,7 @@ import plugin.integration
hash_barcode = mixin.hash_barcode
class BarcodePlugin(mixin.BarcodeMixin, plugin.integration.IntegrationPluginBase):
"""
Legacy barcode plugin definition - will be replaced

View File

@ -2,6 +2,7 @@
Plugin mixin classes for action plugin
"""
class ActionMixin:
"""
Mixin that enables custom actions

View File

@ -63,7 +63,6 @@ class BarcodeMixin:
self.data = barcode_data
def getStockItem(self):
"""
Attempt to retrieve a StockItem associated with this barcode.

View File

@ -185,6 +185,7 @@ class PluginsRegistry:
logger.info(f'Collected {len(self.plugin_modules)} plugins!')
logger.info(", ".join([a.__module__ for a in self.plugin_modules]))
# endregion
# region registry functions
def with_mixin(self, mixin: str):
"""
@ -544,4 +545,5 @@ class PluginsRegistry:
get_plugin_error(error, do_raise=True)
# endregion
plugin_registry = PluginsRegistry()