Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Fix Query class to permit subclass creation#270

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
msiemens merged 2 commits intomsiemens:masterfromothalan:query_subclass
Jul 3, 2019

Conversation

@othalan
Copy link
Contributor

Creating a subclass of the Query class in order to implement custom queries currently fails because thegetattr method creates a new instance of the Query class using a hard-coded name rather than the type of the current instance. This can easily be fixed by usingtype(self)() to create the new class instance.

Creating a new subclass of Query is useful in order to simplify code scenarios where custom test functions are frequently used.

This pull request provides both a test and a fix for this problem.

@othalan
Copy link
ContributorAuthor

The checks seem to be failing because of errors communicating with coveralls, not because of any issue with this change.

@msiemensmsiemens merged commitf3b18d2 intomsiemens:masterJul 3, 2019
@msiemens
Copy link
Owner

That's a good idea, thanks@othalan 🙂

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

Reviewers

No reviews

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

2 participants

@othalan@msiemens

[8]ページ先頭

©2009-2025 Movatter.jp