Conversation
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
…alues Add test to ensure the functionality is as documented.
This allows using the latest changes when building the documentation.
As per the documentation of readthedocs/actions/preview@v1.
Contributor
There was a problem hiding this comment.
Pull request overview
Pre-release 3.7.0 update adding ecFlow-version-gated repeat attributes (including a new RepeatDateTimeList), improving exit-hook propagation behavior, expanding InLimit capabilities, and aligning repo QA/CI + docs build tooling.
Changes:
- Added
@supporteddecorator plus new repeat types (RepeatDateTimeList, enhancedRepeatDateTime) and related docs/lexer updates. - Refined exit-hook handling and improved host-script error trapping to propagate richer exit context.
- Added/updated QA tooling (pre-commit, CI tweaks) and expanded test coverage for the new behaviors.
Reviewed changes
Copilot reviewed 20 out of 20 changed files in this pull request and generated 7 comments.
Show a summary per file
| File | Description |
|---|---|
| tests/test_supported.py | New tests for @supported decorator and repeat attribute version gating. |
| tests/test_inlimits.py | Adds parametrized coverage for new InLimit options. |
| tests/test_host.py | Extends assertions for ERROR/trap contract variables and rc propagation. |
| tests/test_families.py | Updates/expands exit-hook propagation tests (strings, Script, duplicates). |
| tests/test_attributes.py | Adds RepeatDateTimeList tests and validation cases. |
| README.md | Documents CI-equivalent QA checks and local pre-commit usage. |
| pyproject.toml | Adds packaging dependency and new optional deps for QA/dev; updates setuptools_scm config. |
| pyflow/nodes.py | Introduces exit-hook normalization and changes propagation/deduplication behavior. |
| pyflow/importer.py | Adds @supported decorator for ecFlow-version-gated classes. |
| pyflow/host.py | Improves ERROR/trap handling to export exit context and preserve return codes. |
| pyflow/attributes.py | Adds RepeatDateTimeList, version-gates repeat types, and expands InLimit parameters. |
| pyflow/init.py | Exposes RepeatDateTimeList at top-level API. |
| docs/requirements.txt | Updates docs build requirements (adds pypandoc_binary, removes redundant entries). |
| docs/environment.yml | Removes redundant source install entry from docs conda environment. |
| docs/content/api-reference.rst | Adds autodoc entries for RepeatDateTime and RepeatDateTimeList. |
| docs/_ext/ecflow_lexers.py | Updates lexer regex to recognize new repeat keywords. |
| .readthedocs.yaml | Updates OS and installs checked-out source in RTD build env. |
| .pre-commit-config.yaml | Adds pinned isort/black/flake8 pre-commit hooks aligned with CI QA job. |
| .github/workflows/readthedocs-pr.yml | Switches to pull_request_target for RTD PR preview linkage. |
| .github/workflows/ci.yml | Pins docs job runner to Ubuntu 22.04. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
This pull request introduces improvements and new features to the codebase, focusing on enhanced support for ecFlow repeat types, improved version compatibility handling, expanded QA and CI tooling, and more robust handling of exit hooks and resource limits. The changes also include updates to documentation and environment configurations to reflect these improvements and ensure consistency.
New features and compatibility improvements:
RepeatDateTimeListsupport, allowing nodes to repeat over a list of datetime values, and improvedRepeatDateTimewith better string parsing and documentation. Both are version-gated to supported ecFlow versions using a new@supporteddecorator. (pyflow/attributes.py,pyflow/importer.py,pyflow/__init__.py,docs/content/api-reference.rst,docs/_ext/ecflow_lexers.py, [1] [2] [3] [4] [5] [6] [7] [8] [9]@supporteddecorator to restrict usage of features to specific ecFlow versions, raisingNotImplementedErrorif the version is not compatible. (pyflow/importer.py, [1] [2]Quality assurance and CI enhancements:
.pre-commit-config.yamlwithisort,black, andflake8hooks, and updated theREADME.mdto document QA checks and local usage. CI and ReadTheDocs workflows updated for consistency and to use Ubuntu 22.04. (.pre-commit-config.yaml,README.md,.github/workflows/ci.yml,.github/workflows/readthedocs-pr.yml,.readthedocs.yaml, [1] [2] [3] [4] [5] [6]Resource limits and hooks improvements:
InLimitto support additional parameters (path,tokens,limit_this_node_only,limit_submission) for more granular resource control. (pyflow/attributes.py, pyflow/attributes.pyR1035-R1091)pyflow/nodes.py, [1] [2] [3] [4]Documentation and environment updates:
docs/environment.yml,docs/requirements.txt, [1] [2]packagingas a required dependency. (pyproject.toml, pyproject.tomlR33)Changes to
ERRORfunction for task generated script:pyflow/host.py, [1] [2]Contributor Declaration
By opening this pull request, I affirm the following:
📚 Documentation preview 📚: https://pyflow-workflow-generator--104.org.readthedocs.build/en/104/