Skip to content

Commit

Permalink
frontend: regenerate devel repository when multiple builds are deleted
Browse files Browse the repository at this point in the history
Fix fedora-copr#3507

The issue was introduced in PR fedora-copr#3330. We previously did this on
the backend:

    devel = uses_devel_repo(self.front_url, ownername, projectname)

It looks like an unnecessary request, so I am sending the attribute
as a part of the action data.
  • Loading branch information
FrostyX committed Nov 20, 2024
1 parent a01d746 commit e4a08c0
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions frontend/coprs_frontend/coprs/logic/actions_logic.py
Original file line number Diff line number Diff line change
Expand Up @@ -224,6 +224,7 @@ def send_delete_multiple_builds(cls, builds):
# We can pick any random build because the assumption is, they are
# all from the same project
"storage": builds[0].copr.storage if builds else None,
"devel": builds[0].copr.devel_mode,
}

build_ids = []
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -312,6 +312,7 @@ def test_delete_mulitple_builds_no_resultdir(
},
'build_ids': [1, 2, 5],
'storage': StorageEnum.backend,
'devel': False,
}

with pytest.raises(NoResultFound):
Expand Down

0 comments on commit e4a08c0

Please sign in to comment.