#575 Batch build delete doesn't work for me
Closed: Fixed 4 years ago by frostyx. Opened 5 years ago by praiskup.

On the page https://copr.fedorainfracloud.org/coprs/g/pgjdbc/pgjdbc-travis/builds/ I've selected the last page of builds (pagination nr. 30), hit the mark all link/button (javascript), it selected 16 builds, I've hit the Delete all marked button, confirmed the Are you sure, you want to delete 16 builds from your copr? question, and nothing happened.


It works for me as expected under Firefox, Chromium, and google-chrome so it's hard to tell what's up. Is it what you described only one specific case that doesn't work? or it never works?
Can you open developer console (f12), click at "Console" and look for possible javascript errors?
Possibly also try to clear cache (ctrl-f5).

@clime wrote:

It works for me as expected under Firefox, Chromium, and google-chrome
so it's hard to tell what's up.

Doesn't work in Firefox and Chromium for me, I don't have Chrome.

Is it what you described only one specific case that doesn't work? or it never
works?

Ok, I now checked different project (non-@group project). Maybe that is only
about group projects?

Can you open developer console (f12), click at "Console" and look for possible
javascript errors?

No errors.

Possibly also try to clear cache (ctrl-f5).

Doesn't help.

Metadata Update from @frostyx:
- Issue assigned to frostyx

5 years ago

This is an interesting issue. I finally found a way to reproduce it.

It works for me as expected under Firefox, Chromium, and google-chrome
so it's hard to tell what's up.

Doesn't work in Firefox and Chromium for me, I don't have Chrome.

This issue is not browser related.

Ok, I now checked different project (non-@group project). Maybe that is only
about group projects?

+1

Reproducer:
1. Create a project called @somegroup/foo
2. Create a project called @someuser/foo
3. Build something in @somegroup/foo
4. Try to batch delete in @somegroup/foo
5. Batch delete should work properly
6. Delete the @someuser/foo project
7. Try to batch delete in @somegroup/foo
8. Batch delete should not work and you have reproduced this issue.

In other words - If you are trying to batch delete in a group project, it works only if you have a personal project with the same name.

I believe that these lines are the cause

  $.post("{{ url_for('coprs_ns.copr_delete_builds', username=copr.user.name, coprname=copr.name) }}", {"build_ids": build_ids}, function() {
    $(location).attr('href', '{{ copr_url('coprs_ns.copr_builds', copr) }}');
  });

thanks for investigation

I believe, that this is fixed by PR#616

Metadata Update from @frostyx:
- Issue close_status updated to: Fixed
- Issue status updated to: Closed (was: Open)

4 years ago

Login to comment on this ticket.

Metadata