-
Notifications
You must be signed in to change notification settings - Fork 94
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
linter: additional rules #4917
Comments
I'm adding some of these to my currently open PR on Cylc Lint, as the introduction of Arbitrary functions makes many much easier. The ones about checking python files require further thought, since at the moment cylc lint only looks at |
@oliver-sanders is there a list of the deprecated env-vars somewhere? |
Well volunteered! $ git grep SUITE -- cylc/flow/etc/job.sh
cylc/flow/etc/job.sh: export CYLC_SUITE_HOST="${CYLC_WORKFLOW_HOST}"
cylc/flow/etc/job.sh: export CYLC_SUITE_OWNER="${CYLC_WORKFLOW_OWNER}"
cylc/flow/etc/job.sh: export CYLC_SUITE_SHARE_DIR="${CYLC_WORKFLOW_SHARE_DIR}"
cylc/flow/etc/job.sh: export CYLC_SUITE_SHARE_PATH="${CYLC_WORKFLOW_SHARE_DIR}"
cylc/flow/etc/job.sh: export CYLC_SUITE_NAME="${CYLC_WORKFLOW_ID}"
cylc/flow/etc/job.sh: export CYLC_SUITE_LOG_DIR="${CYLC_WORKFLOW_LOG_DIR}"
cylc/flow/etc/job.sh: export CYLC_SUITE_INITIAL_CYCLE_POINT="${CYLC_WORKFLOW_INITIAL_CYCLE_POINT}"
cylc/flow/etc/job.sh: export CYLC_SUITE_INITIAL_CYCLE_TIME="${CYLC_WORKFLOW_INITIAL_CYCLE_POINT}"
cylc/flow/etc/job.sh: export CYLC_SUITE_FINAL_CYCLE_POINT="${CYLC_WORKFLOW_FINAL_CYCLE_POINT}"
cylc/flow/etc/job.sh: export CYLC_SUITE_FINAL_CYCLE_TIME="${CYLC_WORKFLOW_FINAL_CYCLE_POINT}"
cylc/flow/etc/job.sh: export CYLC_SUITE_WORK_DIR="${CYLC_WORKFLOW_WORK_DIR}"
cylc/flow/etc/job.sh: export CYLC_SUITE_UUID="${CYLC_WORKFLOW_UUID}"
cylc/flow/etc/job.sh: export CYLC_SUITE_RUN_DIR="${CYLC_WORKFLOW_RUN_DIR}"
cylc/flow/etc/job.sh: export CYLC_SUITE_DEF_PATH="${CYLC_WORKFLOW_RUN_DIR}" And also
|
I've tried searching on Git, Github, Google, old versions of Rose and Cylc Docs and shared disks locally and I cannot find a reference to:
|
It was https://cylc.github.io/cylc-doc/7.9.3/html/suite-config.html#task-job-script-variables (It's the same story for |
#4900 has gone beyond a basic
sed
file and is now the basis for a more generic linter 🎉.Some follow-on ideas:
Editor integration:
(See #5014)
7 to 8 migration rules
suite.rc
orflow.cylc
file and the first line of the file is not a matching shebang.rose suite-run
used to tolerate missing shebang lines)cylc
->cylc.flow
rose
->metomi.rose
isodatetime
->metomi.isodatetime
from _ import
andimport _
..cylc
&.rc
filesfrom "_" import
.cylc
,.rc
files.05
rather than5
, previously accepted, now a Jinja2 syntax error..cylc
files only).$(rose host-select)
.filter
interface yet).rose host-select
is definitely unnecessary.cylc.flow.scripts.cylc.DEAD_ENDS
).<x><y>
is valid but can be simplified<x, y>
<param1><param2>
in inherited family names #5537%(suite)
= Feat.lint obsolete vars #5879rose suite-hook
(command removed at Rose 2)CYLC_VERSION={{CYLC_VERSION}}
(same forROSE_
andFCM_
). lint: Warn users thatCYLC_VERSION={{CYLC_VERSION}}
is deprecated #5890cylc workflow-state
in a task-script, should use theworkflow_state
xtrigger instead:expired
output must be optional if used (also:expire
,:expire-all
and:expire-any
), see optional output extension proposal.Additional style rules and bug bears
Pull requests welcome!
The text was updated successfully, but these errors were encountered: