Skip to content

Development #148

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

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open

Development #148

wants to merge 2 commits into from

Conversation

dmytrotsko
Copy link
Collaborator

No description provided.

Copy link

@melange396 melange396 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks good!

If you wanted to be a little less verbose you could subclass models.Manager and write a wrapper for get() as described in https://stackoverflow.com/a/3090342

Also mentioned there: you can use .objects.filter(id=row["XYZ"]).first() instead of .objects.get(...) to avoid the try/except, but that can have performance issues (probably not that bad with a db as small as this ¯\_(ツ)_/¯ ).

Try those only if you feel like it!!!

@korlaxxalrok korlaxxalrok removed their request for review June 10, 2025 23:57
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.

2 participants