Skip to content

fix: fix migration without using both sql and orm#9501

Merged
pauldambra merged 3 commits intomasterfrom
really_fix_layouts
Apr 25, 2022
Merged

fix: fix migration without using both sql and orm#9501
pauldambra merged 3 commits intomasterfrom
really_fix_layouts

Conversation

@pauldambra
Copy link
Copy Markdown
Member

Problem

see #9497

but loading the ID using SQL and then using it to load django ORM models managed to load IDs that didn't exist by the time they were queried for

Changes

This uses the django ORM to load dashboard tiles in pages of up to 500

gathers any tiles that need to be updated and then updates those up-to 500 tiles in one operation

How did you test this code?

running the tests

@pauldambra pauldambra requested a review from mariusandra April 22, 2022 15:20
Copy link
Copy Markdown
Collaborator

@mariusandra mariusandra left a comment

Choose a reason for hiding this comment

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

Friday evening, go for it!

@pauldambra pauldambra merged commit d14a4a5 into master Apr 25, 2022
@pauldambra pauldambra deleted the really_fix_layouts branch April 25, 2022 09:42
pauldambra added a commit that referenced this pull request May 13, 2022
* Revert "Revert "fix(dashboard-tiles): migrate doubly stringified layouts correctly (#9497)""

This reverts commit 4e5aa60.

* fix: fix migration without using both sql and orm

(cherry picked from commit d14a4a5)
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