noflo-ui
noflo-ui copied to clipboard
port case insensitivity
I'd like to request that noflo-ui treat port names, and all other names gathered from the runtime, in a case-sensitive fashion. I can't think of a good reason not to.
I thought about this for awhile and at first I was going to suggest that we add a caseSensitive
boolean metadata to the runtime registration, but then I thought better of it. noflo-ui should not need to know whether a runtime is case-sensitive or not, it should simply record component and port names exactly as they are provided to it from the runtime, and respond with those same names.
As it is now, noflo-ui will only work with case-insensitive runtimes, because it converts all port names to lowercase.
[edited for clarity]
Agreed completely
:+1:
I'm not a web dev, but I started digging through the code to try to get a sense of how difficult this would be to fix. What I gathered is that noflo.Graph
is the source of the case-insensitivity. I believe the UI is using this for its internal representation of the graph, but it is also used within the various noflo runtimes. So if we want to make noflo-ui case-sensitive, while maintaining the case-insensitivity of noflo's runtimes, we'll likely need a construction argument to tell noflo.Graph
how to deal with case-sensitivity. Alternately, the entire noflo ecosystem could be made case sensitive. I'll leave that call up to you all.
I dont think preserving the enforced lowercase behavior in NoFlo runtime is å requirement. Only place I can think of is the .fbp DSL, but that is independent og NoFlo.
I think I'm still seeing issues with case sensitive port names on the latest version of Flowhub.
I'm working on a project that's trying to use Rill, a Python-based runtime, with flowhub. All of Rill's example components have port names in upper case. In flowhub, after adding one of these components to the graph and modifying one of its inputs, another port appears that is lowercase. The lowercase version is sent to the runtime which results in errors since all the ports are in upper case.
Are non-lowercase port names supported? If so, is the runtime responsible for communicating if case sensitivity needs to be preserved?
I think the way to go here will be to make case sensitivity a setting you can toggle in graph properties.