Follow-up from "Fix bug that broke BAYESTAR localizations for PyCBC events"
The following discussion from !775 (merged) should be addressed:
-
@brandon.piotrzkowski started a discussion: (+1 comment)
Just to make sure, is there any way to write this with the
if
statement inside the canvas? Then this would be a one line change.
As I replied:
In general, yes, there is: we can use Python's ternary if expression,
a if b else c
, inside canvases. However, it's not straightforward to do that here given the existing structure of the function, because PyCBC needs to be triggered bynew
LVAlert messages and all the other pipelines need to be triggered bylog
LVAlert messages.It's a good idea to refactor this to eliminate the code duplication. Is it OK with you if I open an issue to remind myself to do that at a later date?
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information