Closed JeffreyDavidsz closed 1 year ago
We should probably be more restrictive than just blocking spaces. I expect $():
will all also mess up our variable interpretation.
Could be worth looking into splitting label into 'label' and 'id'. id being used for variables, (needs a better name internally, we already have a non-friendly id), and label used for display only.
Just regex it to letters and numbers? for example ^[a-zA-Z0-9_.-]*$
?
+1 for the regex, but there should be at least one char
yeah Ill look into this for 3.0 I did something similar in 3.0 for the variable names coming from modules, as I realised they had the same flaw. But that was a safer change
haha, that was a good idea to look into this. I realised that in 3.0 it was possible to set an instance to have the label internal
which unsurprisingly causes a few issues.
I've fixed this and added the regex in 3.0, and it will fix up existing data as part of the upgrade and import process.
Looks like this is affecting VLC as well.
Is this a bug in companion itself or a module?
Is there an existing issue for this?
Describe the bug
When using a space in an instance name, variable start doing weird stuff (qlab instance for example)
Steps To Reproduce
load module put space in name see is remaining time works
Expected Behavior
should work
Environment (please complete the following information)
Additional context
No response