-
Notifications
You must be signed in to change notification settings - Fork 39
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
data migration for journalist association fix in draftreplies table #1184
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sssoleileraaa
requested review from
kushaldas and
redshiftzero
as code owners
November 5, 2020 21:54
sssoleileraaa
force-pushed
the
uuid-to-id-draftreplies
branch
from
November 5, 2020 22:12
77ce98b
to
92be3aa
Compare
Environment type: non-Qubes dev env
|
|
conorsch
approved these changes
Nov 5, 2020
This was referenced Nov 9, 2020
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes #1185
Description
Just like we did for the
replies
table, apply a data migration on thedraftreplies
table, see #1162 for context.Test Plan
pip install --require-hashes -r dev-requirements.txt
wget https://gist.githubusercontent.com/creviera/5ba70d50c12b6a6df6f98ed40ad09645/raw/5caef3339ceab1fc997ccb6b9e337bc8828ef12f/failed-reply
git apply failed-reply
journalist_id
column ofdraftreplies
table contains uuids for the failed draftreplies you just tried to sendpip install --require-hashes -r requirements/dev-requirements.txt
alembic.ini
points to thesvs.sqlite
db with your failed replies (edit this manually - I had to update sqlalchemy.url tosqlalchemy.url = sqlite:////home/creviera/.securedrop_client/svs.sqlite
)alembic stamp 7f682532afa2
alembic upgrade head
journalist_id
column ofdraftreplies
table no longer contains uuidsChecklist
If these changes modify code paths involving cryptography, the opening of files in VMs or network (via the RPC service) traffic, Qubes testing in the staging environment is required. For fine tuning of the graphical user interface, testing in any environment in Qubes is required. Please check as applicable:
If these changes add or remove files other than client code, the AppArmor profile may need to be updated. Please check as applicable:
If these changes modify the database schema, you should include a database migration. Please check as applicable:
main
and confirmed that the migration applies cleanlymain
and would like the reviewer to do so