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

Run delete_all instead of destroy_all when removing old RES7 repositories #1100

Merged
merged 1 commit into from
Feb 26, 2024
Merged
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
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,13 @@ def change
# This migration removes the now obsolete repositories, since RMT does
# not remove these automatically.

# NOTE: We have a check in the repository model to stop users from
# deleting SUSE repositories. This is why need to run delete
# directly rather then destroying as usual.

# Affected repositories are:
# - 1963: https://updates.suse.com/repo/$RCE/RES7/src/
# - 1736: https://updates.suse.com/repo/$RCE/RES7/x86_64/
Repository.where(scc_id: [1963, 1736]).destroy_all
Repository.where(scc_id: [1963, 1736]).delete_all
end
end