Skip to content

Commit

Permalink
Merge pull request #111 from varunvarma/plugin_signature
Browse files Browse the repository at this point in the history
Ignore plugin config from signature computation
  • Loading branch information
rexfury-of-oath authored Oct 23, 2019
2 parents a25191e + 281cdba commit 4c8fdd3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions tests/test_base_plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -104,8 +104,8 @@ def test_plugin_info_repr(self):
"Redis pool set: False, Message producer set: False, Kafka client set: False, " \
"Zookeeper client set: False], KV store class: PanoptesTestKeyValueStore, " \
"Last executed timestamp: 1458947997, Last executed key: plugin_metadata:plugin__name:" \
"61547fbb304169f2a076016678bc9cca:last_executed, Last results timestamp: 1458948005, " \
"Last results key: plugin_metadata:plugin__name:61547fbb304169f2a076016678bc9cca:last_results, " \
"0846d379300f4be100f824125fbbe575:last_executed, Last results timestamp: 1458948005, " \
"Last results key: plugin_metadata:plugin__name:0846d379300f4be100f824125fbbe575:last_results, " \
"Data: Data object passed, Lock: Lock is set"

self.assertEqual(repr(panoptes_plugin_info), repr_string)
Expand Down
2 changes: 1 addition & 1 deletion yahoo_panoptes/framework/plugins/panoptes_base_plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -515,7 +515,7 @@ def signature(self):
str: A hash of the plugin's config and data
"""
return hashlib.md5(json.dumps(self.config, sort_keys=True) + str(hash(self.data))).hexdigest()
return hashlib.md5(self.normalized_name + repr(self.data)).hexdigest()

@property
def lock(self):
Expand Down

0 comments on commit 4c8fdd3

Please sign in to comment.