Conversation
|
If bpm(s) moves to diagnostic holder, bpm.py should ne moved in diagnostics directory. |
Yes, but @gubaidulinvadim suggested doing it later in another PR. Would you prefer to do it in this one? Personally, I don't mind. |
|
Everything has been merged here. I will rebase this afternoon and request a review. @JeanLucPons, @TeresiaOlsson, @GamelinAl, @simoneliuzzo, @kparasch, @gubaidulinvadim and anyone else: feel free to start reviewing right now, as things won't change much after the rebase. |
…alized-magnet array
| from ...tuning_tools.tune import Tune | ||
|
|
||
| name = "DEFAULT_TUNE_CORRECTION" | ||
| return self._validate_type(name, self._peer.get_tune_tuning(name), Tune) |
There was a problem hiding this comment.
Very minor comment. Could we simplify with:
return self._validate_type(name, self.get(name), Tune)
?
| and ``tool.dispersion``. | ||
| trm, crm, orm | ||
| Response-matrix measurement tools, looked up by name. | ||
| Backward-compatible aliases for ``tool.trm``, ``tool.crm`` and ``tool.orm``. |
There was a problem hiding this comment.
I tend to prefer breaking backward-compatibility this early in development.
If we say that sr.live.tool.orm is the preferred way to access the orm tool, we should enforce it.
kparasch
left a comment
There was a problem hiding this comment.
Looks ok to me, some minor comments only
6b654e1 to
db35db7
Compare
GamelinAl
left a comment
There was a problem hiding this comment.
Two issues:
- Compared to #199 we still miss the support of
ElementHolderget method for named arrays:sr.live.get("CELL08"). Only the old syntaxsr.live.get_elements("CELL08")is working. - We should also clean the API, I would say we can remove:
get_elementget_elementsget_all_elementsget_*_tuningget_betatron_tune_monitor
After this it should be good I think.
…older-api-refurbishment-review Remove ElementHolder backward-compatible tool aliases (PR #430 review)
Description
Integration PR for epic #199, ElementHolder API refurbishment. Aggregates the sub-features that split the historically monolithic ElementHolder into typed sub-holders (
.magnet(s),.bpm(s),.rf,.diagnostic,.tool, ...) reachable through Python properties, with typedget()and array access instead of the old untypedget_all*()andget_*s()list-returning methods.This branch is merged incrementally as each sub-issue lands, rather than opened as a single large PR, to keep review scoped per sub-feature.
Related Issue
Sub-issues and their status on this branch:
get_cfm()shortcut and dynamic attribute access on GenericArrayHolder based holders.masterclock.voltageis conceptually wrong,voltageneeds its own facade, acavityconcept was proposed, instead of hanging off the default RF plant. Re-opening this requires a new design, not a resubmission of Add an RF masterclock facade #427's diff.ToolHolder,tool.get(name=None), typedtune,trm,orbit,orm,chromaticity,crm,dispersionproperties with type validation. Tests added, full suite green. PR not yet opened.sr.live.bpm[...]has no wildcard support at all, and every holder disagrees on what happens when a name is missing.Changes to existing functionality
Testing
No tests added directly on this integration branch, each sub-issue's PR carries its own tests, see #426 for #373's
tests/common/test_array_holder_navigation.py, and #375's PR fortests/tuning_tools/test_tool_accessors.py.Verify that your checklist complies with the project