Page MenuHomePhabricator

DefaultView: ZString expanded mode: Unable to edit mode or change type when expanding a String ZObjectType
Closed, ResolvedPublicBUG REPORT

Description

Description

When editing a ZString object which type is not unbound (it could be any other type), the ZObjectType can be expanded, but it doesn't show any key-values.
This is probably to the way terminal objects are handled in the store, and how it behaves when trying to convert a terminal ZObject into a non-terminal one (e.g. changing a ZString and instead having a ZMonolingual string)

Steps to reproduce:

  1. Go to https://wikifunctions.beta.wmflabs.org/w/index.php?title=Z10112&view=default-view&action=edit
  2. Expand one of the values of the list under "Common names"

Observed behavior:

  • The key "Type" has an expansion toggle even if it cannot be edited
    Screenshot from 2023-03-31 16-25-31.png (183×400 px, 5 KB)
  • When expanding the key "Type", the key-value-set below is empty
    Screenshot from 2023-03-31 16-28-22.png (142×319 px, 4 KB)

Another example to replicate this locally

  1. Create a new ZObject locally of type String (by going to http://localhost:8080/wiki/Special:CreateZObject?zid=Z6, set a value for the object and save it)
  2. Go to the saved ZObject page in Default and Edit modes (by setting the url to ?view=default-view&action=edit)
  3. Expand the key "Value" and the key "Type"

Screenshot from 2023-03-31 16-45-42.png (179×283 px, 6 KB)

Screenshot from 2023-03-31 16-45-47.png (136×267 px, 4 KB)

Expected behavior (Acceptance criteria):

  • For non editable types, the toggle should not be present
  • For editable types, the toggle should appear but when expanding, the key-values (type: Reference, value: String) should be visible

Devices and Design (URLs or screenshots, if applicable):

  • Desktop: ...
  • Small screens/mobile: ...

Completion checklist

Event Timeline

Correction: it was resolved only partially, still some issues with String terminal state when the type is fully unbound.

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

[mediawiki/extensions/WikiLambda@master] Add missing terminal rule for Z1K1:Z6

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

Change 907823 merged by jenkins-bot:

[mediawiki/extensions/WikiLambda@master] Add missing terminal rule for Z1K1:Z6

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