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 model bakery to use bulk creation with M2M fields #1827

Open
richardebeling opened this issue Oct 24, 2022 · 1 comment
Open

Update model bakery to use bulk creation with M2M fields #1827

richardebeling opened this issue Oct 24, 2022 · 1 comment
Labels
[C] Tests and CI New or better testing and CI [P] Minor Minor priority [T] Refactoring Existing parts should become faster, more readable, or in any other way better.

Comments

@richardebeling
Copy link
Member

Model bakery closed their issue model-bakers/model_bakery#298 as solved. It prevented us from using _bulk_create in multiple places where we also create M2M entries. This should now work. We should update our version and see if we can improve test runtimes a bit further.

@richardebeling richardebeling added [C] Tests and CI New or better testing and CI [T] Refactoring Existing parts should become faster, more readable, or in any other way better. labels Oct 24, 2022
@janno42 janno42 added the [P] Minor Minor priority label Oct 30, 2022
@richardebeling richardebeling self-assigned this Jan 16, 2023
@richardebeling
Copy link
Member Author

As reported in the issue linked above, model-bakery still doesn't create the associations when using the reverse-name of a m2m relationship, so there are still some places where we can't use bulk_create=True.

@richardebeling richardebeling removed their assignment Jan 16, 2023
richardebeling pushed a commit to richardebeling/EvaP that referenced this issue Jan 16, 2023
richardebeling added a commit that referenced this issue Jan 16, 2023
* Update dependencies

* Remove outdated `type: ignore` annotations

* Use more bulk_create (ref #1827). Some usages still don't work as we would expect them to

Co-authored-by: Richard Ebeling <He3lixxx@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[C] Tests and CI New or better testing and CI [P] Minor Minor priority [T] Refactoring Existing parts should become faster, more readable, or in any other way better.
Development

No branches or pull requests

2 participants