cylc-flow icon indicating copy to clipboard operation
cylc-flow copied to clipboard

graph parser: absolute dependency offset on the RHS

Open oliver-sanders opened this issue 2 years ago • 1 comments

At Cylc 7, absolute cycle points on the RHS of an expression resulted in a GraphParseError, e.g:

crunch_numbers => collate_results[2003]

Would result in:

GraphParseError: ERROR, illegal cycle point offset on the right: crunch_numbers  =>  collate_results[2003]

Whereas at Cylc 8 the error is not raised and the => collate_results[2003] dependency is ignored.

oliver-sanders avatar Nov 23 '23 14:11 oliver-sanders

At Cylc 7 ALL cycle points on the RHS of an expression were illegal, not just absolute ones.

The original check was removed at: https://github.com/cylc/cylc-flow/pull/4343/files#diff-71ac7d6076a521f20d45c1d1e06c9bfc8069d38f2b90ece99ef2d0f9434236feR104

Cryptic commentL:

(Note we can't ban this; all nodes get process as left and right.)

More usefully, further up is the comment:

Trigger qualifiers, but not cycle offsets, are ignored on the right to allow chaining.

On consideration we don't want to throw out

foo => bar[0649] => baz

With the bathwater.

To carry out only the check you want we would have to identify whether the RHS of the pair being checked has no RHS dependencies anywhere in the graph. I.e

# Throw out
foo => bar => baz[42]
# but not
qux => quiz[42] => quick
# nor
food => barley[42]
barley[42] => basilisaurus

Actually, might be possible.

wxtim avatar Jan 16 '24 10:01 wxtim

The original check was removed at: https://github.com/cylc/cylc-flow/pull/4343/files#diff-71ac7d6076a521f20d45c1d1e06c9bfc8069d38f2b90ece99ef2d0f9434236feR104

@wxtim, I don't think that link is correct.

oliver-sanders avatar Mar 26 '24 15:03 oliver-sanders

The original check was removed at: https://github.com/cylc/cylc-flow/pull/4343/files#diff-71ac7d6076a521f20d45c1d1e06c9bfc8069d38f2b90ece99ef2d0f9434236feR104

@wxtim, I don't think that link is correct.

I think it is, but it's hidden behind a "large diffs are not displayed": Line 374 in cylc/flow/graph_parser.py before

wxtim avatar Mar 26 '24 15:03 wxtim

That link is for some timer code.

These lines:

https://github.com/cylc/cylc-flow/pull/4343/files#diff-be87b3fcb20fc3228166ad53af61efb79f0d0c84ee01fcd0c9e3092c788e0b93L374-L377

?

oliver-sanders avatar Mar 26 '24 15:03 oliver-sanders

That link is for some timer code.

These lines:

https://github.com/cylc/cylc-flow/pull/4343/files#diff-be87b3fcb20fc3228166ad53af61efb79f0d0c84ee01fcd0c9e3092c788e0b93L374-L377

?

Yes.

wxtim avatar Mar 27 '24 11:03 wxtim