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 the user models to use declarative models #22

Closed
ZechCodes opened this issue Oct 5, 2021 · 2 comments
Closed

Update the user models to use declarative models #22

ZechCodes opened this issue Oct 5, 2021 · 2 comments

Comments

@ZechCodes
Copy link
Owner

Refer to the Using Declarative Models wiki.

Go through the users.py in dippy/core/api/models and do the following

  1. As the very first line add from __future__ import annotations as _
  2. Remove the import for the attrs module
  3. Import Model from dippy.core.model.models
  4. Remove all @attrs lines and update each class with to inherit Model
  5. Replace any attrib(...) assignments
  • You will need to import Field from dippy.core.models.fields
  • Replace attrib with Field
  1. Replace any json_arg(...) assignments the same way as attrib assignments

⚠️ Please make each file changed its own commit. ⚠️

@burning-eggs
Copy link
Collaborator

assign me :))))

ZechCodes added a commit that referenced this issue Oct 5, 2021
@burning-eggs
Copy link
Collaborator

This has been implemented in PR #24

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

No branches or pull requests

2 participants