the UX does not display the first argument of the Cons correctly
the UX does not allow us to use a function that is an argument as a function call
Description
Status | Subtype | Assigned | Task | ||
---|---|---|---|---|---|
Open | None | T289376 Add Map and Reduce (and other meta-functions?) as built-in functions | |||
Resolved | Jdforrester-WMF | T286974 Make it possible to implement Map function | |||
Resolved | SimoneThisDot | T289375 Make the UX able to have users implement the Map function (not type) |
Event Timeline
No, though I've proposed that (T289376). This is about Denny's attempt to implement it on NotWikiLambda in the parent patch, and the issues he ran into (see https://notwikilambda.toolforge.org/wiki/ZObject:Z10044 and https://notwikilambda.toolforge.org/wiki/ZObject:Z10045 for what the current renders are).
Here is the implementation of Map that I am using:
{ "Z1K1": "Z2", "Z2K1": { "Z1K1": "Z6", "Z6K1": "Z10124" }, "Z2K2": { "Z1K1": "Z14", "Z14K1": "Z10123", "Z14K2": { "Z1K1": "Z7", "Z7K1": "Z802", "Z802K1": { "Z1K1": "Z7", "Z7K1": "Z813", "Z813K1": { "Z1K1": "Z18", "Z18K1": { "Z1K1": "Z6", "Z6K1": "Z10123K2" } } }, "Z802K2": { "Z1K1": "Z18", "Z18K1": { "Z1K1": "Z6", "Z6K1": "Z10123K2" } }, "Z802K3": { "Z1K1": "Z7", "Z7K1": "Z810", "Z810K1": { "Z1K1": "Z7", "Z7K1": { "Z1K1": "Z18", "Z18K1": { "Z1K1": "Z6", "Z6K1": "Z10123K1" } }, "K1": { "Z1K1": "Z7", "Z7K1": "Z811", "Z811K1": { "Z1K1": "Z18", "Z18K1": { "Z1K1": "Z6", "Z6K1": "Z10123K2" } } } }, "Z810K2": { "Z1K1": "Z7", "Z7K1": "Z10123", "Z10123K1": { "Z1K1": "Z18", "Z18K1": { "Z1K1": "Z6", "Z6K1": "Z10123K1" } }, "Z10123K2": { "Z1K1": "Z7", "Z7K1": "Z812", "Z812K1": { "Z1K1": "Z18", "Z18K1": { "Z1K1": "Z6", "Z6K1": "Z10123K2" } } } } } } }, "Z2K3": { "Z1K1": "Z12", "Z12K1": [ { "Z1K1": "Z11", "Z11K1": "Z1002", "Z11K2": "Map composition" } ] }, "Z2K4": { "Z1K1": "Z32", "Z32K1": [ { "Z1K1": "Z31", "Z31K1": "Z1002", "Z31K2": [] } ] } }
This seems to work on the backend with a single element list. When I run it with negate on a list with one boolean, it totally does what I expect it to do.
(It does not work for a longer list, but I think that is a problem that is a different problem)
The originally filed issues in the description still persist:
- the UX does not display the first argument of the Z810/Prepend element to list correctly
See here:
The second problem also still persists:
- the UX does not allow us to use a function that is an argument as a function call
This can be seen here: I chose to add a function call, and it asks me to select the function. My function is the first argument, but I cannot select the argument for that.
Hi Adesoji, you moved it to Needs discussion, and wanted to ask what the questions are you have? Should we have a meeting, or how to proceed?
Not really a discussion but it needs some other tickets to be done first before we can work on it. We need to have Typed array sorted on the frontend and also the MAP, which i think @cmassaro is working on.
Change 755337 had a related patch set uploaded (by Simone Cuomo; author: Simone Cuomo):
[mediawiki/extensions/WikiLambda@master] Implement Map in the FE
@DVrandecic Can you check that waht I have done is what you expected.
You are now able to use a typedMap in the UI.
JKieserman moved this task from Incoming to Code Review on the Abstract Wikipedia team (Phase θ – Throttling) board.
@JKieserman Hey there, what's in Code Review on this? Or just a mis-click?