Skip to content

Commit

Permalink
Pin version to be consistent with aiida-core (#24)
Browse files Browse the repository at this point in the history
* Pin python to version >=3.12

To be consistent with aiida-icon.

* Pin aiida-core to >=2.5

To be consistent with aiida-icon.
  • Loading branch information
agoscinski authored Oct 18, 2024
1 parent 403087c commit 08f02a7
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 17 deletions.
10 changes: 5 additions & 5 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
timeout-minutes: 30
strategy:
matrix:
python-version: ['3.11']
python-version: ['3.12']
aiida-version: ['stable']

steps:
Expand Down Expand Up @@ -43,10 +43,10 @@ jobs:
timeout-minutes: 15
steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
- name: Set up Python 3.12
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
python-version: 3.12
- name: Install hatch
run: |
pip install --upgrade pip
Expand All @@ -63,10 +63,10 @@ jobs:
timeout-minutes: 15
steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
- name: Set up Python 3.12
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
python-version: 3.12
- name: Install hatch
run: |
pip install --upgrade pip
Expand Down
11 changes: 3 additions & 8 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,20 +18,17 @@ classifiers = [
'Intended Audience :: Science/Research',
'Operating System :: POSIX :: Linux',
'Programming Language :: Python',
'Programming Language :: Python :: 3.9',
'Programming Language :: Python :: 3.10',
'Programming Language :: Python :: 3.11',
'Programming Language :: Python :: 3.12',
'Topic :: Scientific/Engineering',
'Topic :: Scientific/Engineering :: Atmospheric Science',
]
keywords = ["wc", "workflow"," icon", "aiida", "aiida-workgraph"]
requires-python = '>=3.9'
requires-python = '>=3.12'
dependencies = [
"isoduration",
"pydantic",
"pydantic-yaml",
"aiida-core"
"aiida-core>=2.5"
]

[tool.pytest.ini_options]
Expand All @@ -51,8 +48,6 @@ target-version = "py39"
ignore = [
"TID252", # prefer relative import over absolute
"TRY003", # write custom error messages for formatting
"UP006", # python <3.10 support
"UP007", # python <3.10 support
]

## Hatch configurations
Expand All @@ -66,7 +61,7 @@ extra-dependencies = [
]

[[tool.hatch.envs.hatch-test.matrix]]
python = ["3.9", "3.10", "3.11", "3.12"]
python = ["3.12"]

[tool.hatch.envs.docs]
description = "Build the documentation"
Expand Down
8 changes: 4 additions & 4 deletions src/wcflow/parsing/_yaml_data_models.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
from datetime import datetime
from os.path import expandvars
from pathlib import Path
from typing import Any, Optional
from typing import Any

from isoduration import parse_duration
from isoduration.types import Duration # pydantic needs type # noqa: TCH002
Expand Down Expand Up @@ -169,9 +169,9 @@ class ConfigCycleTask(_NamedBaseModel):
To create an instance of a task in a cycle defined in a workflow file.
"""

inputs: Optional[list[ConfigCycleTaskInput | str]] = Field(default_factory=list)
outputs: Optional[list[ConfigCycleTaskOutput | str]] = Field(default_factory=list)
depends: Optional[list[ConfigCycleTaskDepend | str]] = Field(default_factory=list)
inputs: list[ConfigCycleTaskInput | str] | None = Field(default_factory=list)
outputs: list[ConfigCycleTaskOutput | str] | None = Field(default_factory=list)
depends: list[ConfigCycleTaskDepend | str] | None = Field(default_factory=list)

@field_validator("inputs", mode="before")
@classmethod
Expand Down

0 comments on commit 08f02a7

Please sign in to comment.