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

Custom user model configuration #80

Open
1 of 7 tasks
TWeidi opened this issue Nov 3, 2020 · 2 comments
Open
1 of 7 tasks

Custom user model configuration #80

TWeidi opened this issue Nov 3, 2020 · 2 comments

Comments

@TWeidi
Copy link

TWeidi commented Nov 3, 2020

Prerequisites

  • Is it a bug?
  • Is it a new feature?
  • Is it a a question?
  • Can you reproduce the problem?
  • Are you running the latest version?
  • Did you check for similar issues?
  • Did you perform a cursory search?

For more information, see the CONTRIBUTING guide.

Description

Is it on purpose that one is not able to resolve a user from a custom Django model (called 'Component' in my case) that is related to a user via a ForeignKey? When I try to query the user field (called 'creator' in my case) I receive the following error message: "Cannot query field "creator" on type "ComponentNode""
The issue originates from the usage of the seemingly undocumented Meta property 'skip_registry' of graphenes 'DjangoObjectType' in the definition of the UserNode class.
What is the reason and purpose for setting 'skip_registry' to True?

Expected behavior

Access non-critical user properties (like username and id) from related objects

Actual behavior

The relation between a custom Django model and a user is not resolved from a graphql query to the custom model

@fgallese
Copy link

fgallese commented Jan 6, 2021

@TWeidi I'm facing this exact same issue. Did you manage to find a safe solution ?

@abbasegbeyemi
Copy link

Same thing here. Can anyone shed some light on why this has been configured this way?

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

No branches or pull requests

3 participants