Hide "Delete experiment" for model experiment without permission
What does this MR do and why?
Hide ""Delete experiment" for model experiment without permission
References
- Related to #509247 (closed)
MR acceptance checklist
Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.
Screenshots or screen recordings
| Before | After |
|---|---|
![]() |
![]() |
How to set up and validate locally
- Go to any project, and "Analyze/Experiments.
- First create some experiments and runs as below on rails console
project = Project.find(34)
user = User.find_by_username('test4')
Ml::CreateModelService.new(project, "model_1", user).execute
m = ::Ml::Model.find_by(name: "model_1")
12.times { |i| Ml::CreateCandidateService.new(m.default_experiment, {user: user}).execute }
- Now enter an experiment and some runs, and see the "Delete run" menu button as in screenshot
- Open the same URL in incognito mode for a public project; and see you can see everything except the delete button
Edited by Alper Akgun

