Page MenuHomePhabricator

While creating converters through the UI, Z0 replacement inside function code doesn't work
Closed, ResolvedPublicBUG REPORT

Description

Description

Steps to reproduce:

  1. Go to https://wikifunctions.beta.wmflabs.org/w/index.php?title=Special:CreateObject&zid=Z46 to create a converter
  2. Select code and a programming language

Observed behavior:

  • The code snippet is initialized to "undefined()"
    • This is because the code component assumes it's code of an implementation, and takes the function name from the implementation function Zid
  • The function name should be the newly created object ID, so probably initialized to "Z0( Z0K1 )"
  • When hardcoding the function definition with Z0s, once saved, these Z0s are not replaced with the newly assigned Zid

Expected behavior (Acceptance criteria):

  • Anyone can create converters comfortably using solely the UI
  • All known fields should be pre-assigned
  • Function code scaffolding should be correctly created
  • Once saved, the Z0 should be replaced with the newly created Zid

Completion checklist

Event Timeline

Change #1046706 had a related patch set uploaded (by Genoveva Galarza; author: Genoveva Galarza):

[mediawiki/extensions/WikiLambda@master] Initialize ZCode properly for converters

https://gerrit.wikimedia.org/r/1046706

Change #1046706 merged by jenkins-bot:

[mediawiki/extensions/WikiLambda@master] Initialize ZCode properly for converters

https://gerrit.wikimedia.org/r/1046706

Change #1046758 had a related patch set uploaded (by Genoveva Galarza; author: Genoveva Galarza):

[mediawiki/extensions/WikiLambda@master] [WIP] Replace Z0 instances inside of code key Z16K2

https://gerrit.wikimedia.org/r/1046758

Jdforrester-WMF changed the task status from Open to In Progress.Jun 17 2024, 8:21 PM
Jdforrester-WMF assigned this task to gengh.

Change #1046758 merged by jenkins-bot:

[mediawiki/extensions/WikiLambda@master] Replace Z0 instances inside of code key Z16K2

https://gerrit.wikimedia.org/r/1046758