Skip to content

Remove Lock class dependency from Election class #11

Description

@vbmade2000

There is an instantiation of Lock class inside Election class. This makes Election class dependent on Lock class. You can see instantiation at https://github.com/metaparticle-io/sync/blob/master/python/metaparticle_sync/election.py#L8:21.

IMHO, instance of Lock class should be supplied from outside. It removes dependency of Election class on Lock class. Also I believe it makes Election class more unit test friendly.

Let me know your thoughts. If you agree, I can send a PR.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions