Skip to content

Conversation

@DKastelic
Copy link
Contributor

Fixes #3612 by disallowing PVs (and nodes) with multiple leading slashes.

Trying to add a PV/node with multiple leading slashes raises an exception, which is handled by the GUI by opening an error dialog
and by the XmlModelReader by logging a warning.

Also fixes a bug where moving an alarm tree node to the same path it already has would delete it.

Checklist

  • Testing:

    • The feature has automated tests
      • Copied the AlarmTreePath unit test from the old CS Studio to Phoebus and added a test case for the new exception.
    • Tests were run
  • Documentation:

    • The feature is documented
      • The new exception has a javadoc comment and makePath has an added @throws tag
    • The documentation is up to date
    • Release notes:
      • Added an entry if the change is breaking or significant
      • Added an entry when adding a new feature

@shroffk shroffk requested a review from georgweiss December 1, 2025 14:44
@shroffk shroffk requested a review from kasemir January 5, 2026 19:28
@shroffk
Copy link
Member

shroffk commented Jan 5, 2026

Tested with some of the edge cases which are used

  1. slashes in pv and/or formula names
    e.g. sim://ramp =maxAlarmOf('ca://pv1','pva://struct/leaf')
image

this worked

  1. checking the error reporting
image

@shroffk shroffk merged commit db2ce5f into ControlSystemStudio:master Jan 5, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Alarm Tree breaks on duplicate PVs with slashes

3 participants