Skip to content

Conversation

@khushi1310
Copy link
Contributor

Fixes #5251

Proposed changes

Fixed an issue where updating experiment tags or description was triggering a duplicate name validation error.
In the UpdateChaosExperiment function, the duplicate name validation was being called unconditionally without checking if the experiment name had actually changed. This meant:

  • When you edit an existing experiment (e.g., adding tags/description)
  • The system checks if an experiment with that name already exists
  • It finds the current experiment itself as a "duplicate"
  • Returns the error: "experiment name should be unique, duplicate experiment found with name: khushitest2"

Types of changes

What types of changes does your code introduce to Litmus? Put an x in the boxes that apply

  • New feature (non-breaking change which adds functionality)
  • Bugfix (non-breaking change which fixes an issue)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation Update (if none of the other choices applies)

Checklist

Put an x in the boxes that apply. You can also fill these out after creating the PR. If you're unsure about any of them, don't hesitate to ask. We're here to help! This is simply a reminder of what we are going to look for before merging your code.

  • I have read the CONTRIBUTING doc
  • I have signed the commit for DCO to be passed.
  • Lint and unit tests pass locally with my changes
  • [] I have added tests that prove my fix is effective or that my feature works (if appropriate)
  • I have added necessary documentation (if appropriate)

Dependency

  • No dependencies required

Special notes for your reviewer:

Steps to Test:

  1. Create a new experiment with name "test1"
  2. Edit the experiment and add new tags
  3. Save changes - should work without duplicate name error
  4. Verify tags are saved correctly in db

Signed-off-by: khushi1310 <[email protected]>
@khushi1310 khushi1310 changed the title fixed_issue fixed_issue_ updating_experiment_tags_or_description Oct 23, 2025
@PriteshKiri PriteshKiri requested review from Jonsy13 and amityt October 24, 2025 05:50
@Jonsy13 Jonsy13 merged commit 9db0781 into litmuschaos:master Oct 27, 2025
18 of 19 checks passed
UJESH2K pushed a commit to UJESH2K/fix-server-addr that referenced this pull request Oct 28, 2025
Signed-off-by: khushi1310 <[email protected]>
Co-authored-by: Pritesh Kiri <[email protected]>
Co-authored-by: Vedant Shrotria <[email protected]>
Signed-off-by: UJESH KUMAR YADAV <[email protected]>
UJESH2K pushed a commit to UJESH2K/fix-server-addr that referenced this pull request Oct 28, 2025
Signed-off-by: khushi1310 <[email protected]>
Co-authored-by: Pritesh Kiri <[email protected]>
Co-authored-by: Vedant Shrotria <[email protected]>
Signed-off-by: UJESH KUMAR YADAV <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Hacktoberfest hacktoberfest-accepted Accepted for HacktoberFest

Projects

None yet

Development

Successfully merging this pull request may close these issues.

fix: Unable to save tags and description changes in existing experiments

4 participants