Skip to content

Conversation

nstelter-slac
Copy link
Collaborator

@nstelter-slac nstelter-slac commented Apr 24, 2025

We only defined and only accept the protocol in channel addresses when its all lowercase. ('pva', 'calc', 'ca', etc)
Used in an address, it looks like: 'ca://test:example'.

But sometimes we set the protocol to be uppercase, like in the testing when we use 'CA://MTEST'.

This fix just converts all protocols into lowercase to avoid an error, which imo is more user friendly than enforcing case-sensitive protocols

Found this issue when running tests on pyside6 since with it logger.error() calls are printed and fail the tests, but on pyqt5 we need to set 'log_cli=true' to get the same behavior. (which we currently don't do, but i'll set it in followup patch)

@nstelter-slac nstelter-slac added the pyside6 for adding pyside6 (qt6) support label Apr 24, 2025
@nstelter-slac nstelter-slac force-pushed the protocol_fix branch 2 times, most recently from 23accd0 to 6461bb7 Compare April 24, 2025 02:32
… all caps

We only defined and only accept the protocol in channel addresses when its all lowercase. ('pva', 'calc', 'ca', etc)
Used in a while address, it looks like: 'ca://test:example'.

But sometimes we set the protocol to be uppercase, like in the
testing when we use 'CA://MTEST'.

This fix just converts all protocols into lowercase to avoid an error,
which imo is more user friendly than enforcing case-sensitive protocols

Found this issue when running tests on pyside6 since with it logger.error() calls are printed and fail
the tests, but on pyqt5 we need to set 'log_cli=true' to get the same
behavior. (will set this in followup patch)
Copy link
Collaborator

@craftablescience craftablescience left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This change makes sense, despite my limited experience I don't think there are any conflicts between different protocols that would be introduced

@jbellister-slac jbellister-slac merged commit c83cb0a into slaclab:master Apr 25, 2025
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pyside6 for adding pyside6 (qt6) support
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants