-
-
Notifications
You must be signed in to change notification settings - Fork 39
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Filter mapping by module ID instead of module label #969
Comments
Aren't module ids created from the labels behind the scenes and never made available to the user? |
Yes and I don't feel it's correct. Like I said earlier, a label should be a free text, in particular: an empty character or non-unique values between modules. These all should be allowed but it's not because we treat labels as identifier. |
That is a fair point, however, juggling labels AND ids is additional burden on the user. |
Yes. We can probably came up with some convenience features but I agree that managing two attributes is more or less twice as difficult as managing just one. This doesn't change the point that IMHO right now labels are misused as ids. Recent rollout of mapping feature just exposed such flaw. Until this, the concept of module id was just useless for the user. I think we need to rethink the concept of module ID. Until a new not-yet-anticipated feature / extension that requires an ID. |
I remember we discussed this briefly during the design of the module-specific mechanism, but decided to stick with the labels for the sake of moving on, because there weren't clear/better alternatives at the time. I concur @pawelru's thoughts, thanks for raising the topic again. |
We are in dead end with this one.
modules(
tm_xy("mod1", ,..., filters = teal_slices(teal_slice_age, teal_slice_sex),
modules(
label = "tab",
tm_xy("mod1", ...., filters = teal_slices(teal_slice_age)
)
) We would be able to map modules properly together even if they are nested.
And we rather should display this information in following way:
|
Another solutions are:
Just a reminder of early findings: #534 |
That's exactly what I was referring to. Use How about the following: add optional (!) This would address @chlebowa concern about throwing yet another technical requirement to the app developer which is totally valid point.
I believe this would be sorted out as well. We will be having the following structure:
From this, you can easily visualise this as a table and skip ID at all. |
Conceptually, I find it quite odd to map filter to module labels. It should be a module identifier instead. A label should be a free text but we tend to use it as identifier which is probably not the right thing to do.
@donyunardi comment from #972
Currently, this is how users define module specific mapping
We have an assertion to check for duplicate labels, which is good.
However, can we explore the possibility of using a module's
id
for this assignment? This could involve altering the module's structure and introducing theid
in the module's server.Here's what the code could look like:
The text was updated successfully, but these errors were encountered: