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

Fix tree structure issues due to an old WorkBench bug #5366

Draft
wants to merge 4 commits into
base: production
Choose a base branch
from
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 22 additions & 0 deletions specifyweb/specify/migrations/0012_fix_accepted_taxon.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# Generated by Django 3.2.15 on 2024-11-01 19:21

from django.db import migrations


class Migration(migrations.Migration):

dependencies = [
('specify', '0011_cascading_tree_nodes'),
]

operations = [
# Fixes an issue due to a bug in the WorkBench prior to 7.9.0 that did not
# set accepted nodes to IsAccepted = 1 when they were not synonyms.
# https://github.com/specify/specify7/issues/5131
migrations.RunSQL(
'UPDATE taxon t1 SET IsAccepted = TRUE WHERE t1.IsAccepted = 0 AND t1.AcceptedId IS NULL',
# This should not need to be reversed, but this allows for rollback without reversing the SQL
reverse_sql=''
)
]

Loading