-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Revert "Replace display.format with .form and .precision"
This reverts commit 4ffddfa.
- Loading branch information
1 parent
3ae2d09
commit cd24363
Showing
6 changed files
with
37 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cd24363
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will this affect the data provided by QSRV, where EPICS 7.0.2.2 now gets us the desired 'form' and 'precision'?
cd24363
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No. #62 and epics-base/pva2pva#24 are independent from each other.
cd24363
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good. Do I have this correct:
The EPICS IOC, using QSRV, does and will continue to provide values with
form
andprecision
.The pvDataCPP, normative type, ... libraries can't easily be updated because of tests and paperwork.
cd24363
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The difficulty is with clients, as in AD, which use the
isCompatible()
tests from the ntCPP module (epics-base/normativeTypesCPP#15). These tests are extremely strict. Changing any aspect of thedisplay
sub-struct will cause eg. the AD client to reject the whole NTNDArray. So even were ntCPP updated, older clients would be unable to use newer servers.So we're in a situation where some degree of compatibility break seems inevitable...
cd24363
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cd24363
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The latest CS-Studio code checks if there's a "format" or the new "form" and "precision", so it handles both.
I think we should move forward, meaning the AD client needs to adjust to the new display info in a similar way.
cd24363
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Section 2 of the Normative Types specification says:
The combination of points 3 and 4 above explains why
isCompatible()
is checking index numbers for the fields — the spec says that all the required fields must be present in the order given, and any additional fields must come later on. I see no wiggle room there (which was probably intentional).ISTR suggesting that we might need to include both
display.format
anddisplay.form
fields for at least one release. In the meantime perhaps we should come up with a revised specification that says what we want it to say for future releases.For those that aren't aware, one type (maybe the only one, not sure) for which the order of fields really matters is the set of columns in an NTTable. The
value
field is a structure containing a series of scalar array sub-fields, one for each table column. The separatelabels
field is an array of strings that provides the column labels for those columns, and the indices for the sub-field and its label must be the same, so implementations must store the column fields using an order-preserving container such as an ordered dictionary in Python.cd24363
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I had this thought as well, but sadly this will not avoid a compatibility break. One of the tests in
NTField::isDisplay()
is:cd24363
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cd24363
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think that goes into the right direction.
On one extreme, you can argue that this is a change to the "normative types". So need to create paperwork to define a new version "epics:nt/NTScalar:2.0" with updated display definition.
On the other hand, the latest writeup I can find is
http://epics-pvdata.sourceforge.net/alpha/normativeTypes/normativeTypes.html,
"Editors Draft, 16-Mar-2015", which states
So even in the definition it was never fully defined.
Now it is being defined in a more practical way, and implementations naturally need to be updated, just like CS-Studio which has already been updated.
cd24363
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cd24363
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cf. epics-base/normativeTypesCPP#15