Skip to content

Commit

Permalink
Fix code quality issues
Browse files Browse the repository at this point in the history
  • Loading branch information
javrasya committed Sep 7, 2019
1 parent ed6f333 commit b11f3d6
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
3 changes: 2 additions & 1 deletion river/core/riverobject.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
from river.core.workflowregistry import workflow_registry


# noinspection PyMethodMayBeStatic
class RiverObject(object):

def __init__(self, owner, field_name):
Expand All @@ -24,5 +25,5 @@ def __getattr__(self, field_name):
def all(self, cls):
return list([getattr(self, field_name) for field_name in workflow_registry.workflows[id(cls)]])

def all_field_names(self, cls):
def all_field_names(self, cls): # pylint: disable=no-self-use
return [field_name for field_name in workflow_registry.workflows[id(cls)]]
2 changes: 1 addition & 1 deletion river/hooking/backends/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ class BaseHookingBackend(object):
def register(self, hooking_cls, callback, workflow_object, field_name, override=False, *args, **kwargs):
raise NotImplementedError()

def unregister(self, hooking_cls, callback, workflow_object, field_name, override=False, *args, **kwargs):
def unregister(self, hooking_cls, workflow_object, field_name, *args, **kwargs):
raise NotImplementedError()

def get_callbacks(self, hooking_cls, workflow_object, field_name, *args, **kwargs):
Expand Down
2 changes: 1 addition & 1 deletion river/tests/core/test__instance_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -335,7 +335,7 @@ def test_shouldAllowCyclicTransitions(self):
permissions=[authorized_permission]
)

meta_4 = TransitionApprovalMetaFactory.create(
TransitionApprovalMetaFactory.create(
workflow=workflow,
source_state=cycle_state_3,
destination_state=off_the_cycle_state,
Expand Down

0 comments on commit b11f3d6

Please sign in to comment.