Skip to content

Conversation

oliver-sanders
Copy link
Member

Pre-release testing for 8.5.0 flagged several test issues.

  • Some tests haven't been run for a while (PBS testing was very difficult for us on the old system, recently retired).
  • Some tests needed modification to run on the new system.

Check List

  • I have read CONTRIBUTING.md and added my name as a Code Contributor.
  • Contains logically grouped changes (else tidy your branch by rebase).
  • Does not contain off-topic changes (use other PRs for other changes).
  • Applied any dependency changes to both setup.cfg (and conda-environment.yml if present).
  • Tests are included (or explain why tests are not needed).
  • Changelog entry included if this is a change that can affect users
  • Cylc-Doc pull request opened if required at cylc/cylc-doc/pull/XXXX.
  • If this is a bug fix, PR should be raised against the relevant ?.?.x branch.

@oliver-sanders oliver-sanders added this to the 8.5.x milestone Jul 25, 2025
@oliver-sanders oliver-sanders self-assigned this Jul 25, 2025
Comment on lines +108 to +109
if cylc.flow.flags.verbosity > 1:
print(f'$ ln -s "{target}" "{path}"')
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Make symlink dir issues easier to debug.

Comment on lines 28 to 36
[[_retrieve]]
$(cylc config -i "[platforms][$CYLC_TEST_PLATFORM]")
[[_retrieve]]
retrieve job logs = True
install target = $CYLC_TEST_PLATFORM
[[_no_retrieve]]
$(cylc config -i "[platforms][$CYLC_TEST_PLATFORM]")
[[_no_retrieve]]
retrieve job logs = False
install target = $CYLC_TEST_PLATFORM
"
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • Allow default [directives] to be specified in the test config.
  • install target should already be set correctly.

Comment on lines +52 to +53
sed -i -E 's/--max-size=[^ ]* //' 'my-rsync.log.edited' # strip "retrieve job logs max size" arg
sort -u 'my-rsync.log.edited' # stip out duplicates (can result from PBS log file spooling)
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • Strip --max-size options which may or may not be added based on config.
  • Tolerate job log retrieval retries (needed when PBS output spooling is in play).

Comment on lines 39 to -38
[[goodhostplatform]]
hosts = ${CYLC_TEST_HOST}
install target = ${CYLC_TEST_INSTALL_TARGET}
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can't define platforms like this because they don't inherit any config from $CYLC_TEST_PLATFORM.

Comment on lines -68 to -70
named_grep_ok "job kill retries & succeeds" \
"\[jobs-kill out\] \[TASK JOB SUMMARY\].*1/mixedhosttask/01" \
"${LOGFILE}"
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This test turned out to be fragile. Replaced with more targetted checks.

Comment on lines +27 to +33
[[goodhosttask]]
script = sleep 60
platform = goodhostplatform

[[mixedhosttask]]
script = sleep 60
platform = mixedhostplatform
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ensure both tasks are running when the kill command is sent.

@@ -37,14 +40,16 @@ create_test_global_config "" "
share/cycle = \$TMPDIR/\$USER/cylctb_tmp_share_dir
work = \$TMPDIR/\$USER
[[[$CYLC_TEST_INSTALL_TARGET]]]
run = \$TMPDIR/\$USER/test_cylc_symlink/ctb_tmp_run_dir
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

$TMPDIR/$USER does not exist on our new machine and $TMPDIR path changes from node to node :/

Switched to a permanent directory $HOME/cylctb-symlinks with one subdir for each test.


create_test_global_config "" "
[install]
[[symlink dirs]]
[[[${CYLC_TEST_INSTALL_TARGET}]]]
run = \$TMPDIR/\$USER/sym-run
run = \$HOME/cylctb-symlinks/$TEST_NAME/
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ditto

@oliver-sanders oliver-sanders marked this pull request as draft July 25, 2025 12:08
Comment on lines +27 to +34
cylc message -- 'echo done'

# wait up to PT1M for the cat-log task to succeed
# (the workflow will shut down if cat-log fails)
sleep 60

# fail if the task was not orphaned by this point
false
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This test was supposed to be testing cat-log against running tasks:

Test "cylc cat-log" of currently-running local and remote jobs.

However, there was nothing to keep the task running, so it was actually testing succeeded jobs.

I've changed the approach, the tasks now sleep for 60s, then fail.

If the cat-log works, it will cylc set the task, orphaning the sleep and triggering fin which is used to diagnose test success.

@MetRonnie MetRonnie changed the base branch from master to 8.5.x July 29, 2025 11:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant