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

Update monkeypatch to handle list of Schema classes #59

Merged
merged 1 commit into from
May 27, 2022

Conversation

digitaldogsbody
Copy link
Member

This updates the monkeypatcher to allow passing a list of Schema objects as well as a single one.

from ..loader import monkeypatch_schema
from ..skeleton import Manifest, Canvas

class ExampleHelper:
    def example_helper(self):
        return "First Example"

class ExampleHelper2:
    def example_helper2(self):
        return "Second example

monkeypatch_schema(Manifest, ExampleHelper)
monkeypatch_schema([Manifest, Canvas], ExampleHelper2)

@digitaldogsbody digitaldogsbody merged commit 5f543a9 into main May 27, 2022
@digitaldogsbody digitaldogsbody deleted the update_loader branch May 27, 2022 13:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants