Fix issue #89 - #118
Open
hardenchant wants to merge 1 commit into
Open
Conversation
Collaborator
|
Thanks for the PR! Can you add a test?
…-Tim Abbott (mobile)
On Fri, Mar 12, 2021, 05:36 Gleb Lysov ***@***.***> wrote:
Fix issue #89 <#89> with
Error:
psycopg2.ProgrammingError: can't adapt type 'CombinedExpression'
------------------------------
You can view, comment on, or merge this pull request online at:
#118
Commit Summary
- fix error psycopg2.ProgrammingError: can't adapt type
'CombinedExpression'
File Changes
- *M* bitfield/admin.py
<https://github.com/disqus/django-bitfield/pull/118/files#diff-18d0d373d4007ed912f5448a23cae656b854f98a231072c3a549f11eae0cd2a3>
(2)
Patch Links:
- https://github.com/disqus/django-bitfield/pull/118.patch
- https://github.com/disqus/django-bitfield/pull/118.diff
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#118>, or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAU6NWVT6LUCXPJAIQ7FM4TTDIKEVANCNFSM4ZCJTOGQ>
.
|
Collaborator
|
@iamahuman would you be up for finishing this PR? |
iamahuman
reviewed
May 28, 2021
| def queryset(self, request, queryset): | ||
| filter_kwargs = dict( | ||
| (p, BitHandler(v, ())) | ||
| (p, BitHandler(v, getattr(queryset.model, p))) |
Contributor
There was a problem hiding this comment.
Would getattr on a user-supplied model be a safe operation? I need to take a look at this later...
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fix issue #89 with Error:
psycopg2.ProgrammingError: can't adapt type 'CombinedExpression'