Enum fields trimmed when they shouldn't be
维护者通常 2 天内回复
还没有人认领这个 Issue。
评估
调研方向
Start by tracing how Phoebus reads and writes enum string values for PVs, focusing on where trailing whitespace may be trimmed. Reproduce the reported mismatch with an IOC enum value that ends in whitespace, using both CA and PVA if available. Done means the written value preserves the whitespace and the IOC accepts the matching choice.
由索引模型根据 Issue 内容生成。
描述
MBBO ZRST-FFST fields in an IOC can be defined with trailing whitespace, and Phoebus correctly reads these in.
However, it appears that when Phoebus writes these strings to a PV it trims the whitespace, and sends this to try and match the value with the IOC, but it no longer matches as it is missing the trailing whitespace.
This causes the following error in the IOC:
recGblRecordError: <string_to_you_tried_to_set> Illegal choice PV: <record_name>
and the following error in Phoebus (when using CA):
Exception occured, code: gov.aps.jca.CAStatus\[PUTFAIL=20,WARNING=0\]=Could not perform a database value put for that channel, message: '<record_name>'.
or if using PVA it causes a much longer error message (~700 lines). Here is a snippet of that error:
WARNING [org.csstudio.display.builder.runtime] Widget Combo Box write error for value short test
java.lang.Exception: Cannot write <string_to_you_tried_to_set> to PV pva://<record_name>
at org.csstudio.display.builder.runtime.pv.RuntimePV.write(RuntimePV.java:114)
at org.csstudio.display.builder.runtime.WidgetRuntime.writePrimaryPV(WidgetRuntime.java:382)
at org.csstudio.display.builder.runtime.RuntimeUtil$1.handleWrite(RuntimeUtil.java:52)
at org.csstudio.display.builder.representation.ToolkitRepresentation.fireWrite(ToolkitRepresentation.java:682)
at org.csstudio.display.builder.representation.javafx.widgets.ComboRepresentation.confirm(ComboRepresentation.java:198)
at org.csstudio.display.builder.representation.javafx.widgets.ComboRepresentation.lambda$createJFXNode$0(ComboRepresentation.java:78)
at com.sun.javafx.application.PlatformImpl.lambda$runLater$10(PlatformImpl.java:456)
at java.base/java.security.AccessController.doPrivileged(AccessController.java:138)
at com.sun.javafx.application.PlatformImpl.lambda$runLater$11(PlatformImpl.java:455)
at com.sun.glass.ui.InvokeLaterDispatcher$Future.run(InvokeLaterDispatcher.java:95)
at com.sun.glass.ui.win.WinApplication._runLoop(Native Method)
at com.sun.glass.ui.win.WinApplication.lambda$runLoop$3(WinApplication.java:185)
at java.base/java.lang.Thread.run(Thread.java:1447)
Caused by: java.util.concurrent.TimeoutException
at java.base/java.util.concurrent.CompletableFuture.timedGet(CompletableFuture.java:2006)
at java.base/java.util.concurrent.CompletableFuture.get(CompletableFuture.java:2141)
at org.phoebus.pv.pva.PVA_PV.write(PVA_PV.java:197)
at org.csstudio.display.builder.runtime.pv.RuntimePV.write(RuntimePV.java:110)
... 12 more
I would imagine removing whitespace trimming when getting Enum string values would fix this but I am not familiar with Phoebus code.
- 主要语言
- Java
- 星标
- 130
- 派生
- 132
- 平均合并
- 3 天 1 小时
- 30 天内合并 PR
- 24
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 有 Pull Request 模板
- 没有贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
ControlSystemStudio/phoebus 的其他 Issue
-
难度 2/5 1-3 小时 新手友好度 72/100
ControlSystemStudio/phoebus#3979 ·
维护者通常 2 天内回复
-
难度 2/5 1-3 小时 新手友好度 80/100
ControlSystemStudio/phoebus#3962 ·
维护者通常 2 天内回复
-
难度 2/5 1-3 小时 新手友好度 65/100
ControlSystemStudio/phoebus#3865 · 1 条评论 ·
维护者通常 2 天内回复
-
难度 2/5 1-3 小时 新手友好度 52/100
ControlSystemStudio/phoebus#3980 ·
维护者通常 2 天内回复
-
难度 4/5 3-5 天 新手友好度 45/100
ControlSystemStudio/phoebus#3978 ·
维护者通常 2 天内回复
查看 ControlSystemStudio/phoebus 的全部 Issue
相似的 Issue
-
bug
难度 2/5 1-3 小时 新手友好度 82/100
adorsys/keycloak-config-cli#1709 ·
维护者通常 1 天内回复
-
! and-bugs
难度 2/5 1-3 小时 新手友好度 78/100
osmandapp/OsmAnd#26769 · 1 条评论 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 70/100
NationalSecurityAgency/ghidra#9997 · 2 条评论 ·
维护者通常 2 天内回复
-
[Bug] DefaultSerializationExceptionWrapper does not implement Cleanable, so cleanup() is never invoked by codecs可能已有人在做 @binbin0325 今天认领。 未关闭component/need-triage type/need-triage
难度 2/5 1-3 小时 新手友好度 75/100
维护者通常 1 天内回复
-
fix: tagged PDF fails with ClassCastException when a Form and its Image share an XObject name可能已有人在做 @hnc-jglee 今天认领。 未关闭
难度 2/5 1-3 小时 新手友好度 78/100
opendataloader-project/opendataloader-pdf#830 ·
维护者通常 1 天内回复