Skip to content

Commit f2bcdcb

Browse files
committed
Merge branch 'main' into update/docker-container
2 parents 9913e21 + 30adaa3 commit f2bcdcb

File tree

7 files changed

+16
-39
lines changed

7 files changed

+16
-39
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -52,33 +52,12 @@ jobs:
5252
docker exec --tty --user aiida $DOCKERID /bin/bash -l -c 'cd /home/aiida/aiida-cp2k/ && py.test --cov aiida_cp2k --cov-append .'
5353
5454
55-
pre-commit:
56-
runs-on: ubuntu-latest
57-
timeout-minutes: 10
58-
strategy:
59-
matrix:
60-
python-version: [3.8]
61-
steps:
62-
- uses: actions/checkout@v2
63-
- name: Set up Python ${{ matrix.python-version }}
64-
uses: actions/setup-python@v2
65-
with:
66-
python-version: ${{ matrix.python-version }}
67-
- name: Install python dependencies
68-
run: |
69-
pip install --upgrade pip
70-
pip install -e .[dev,docs]
71-
- name: Run pre-commit
72-
run: |
73-
pre-commit install
74-
pre-commit run --all-files || ( git status --short ; git diff ; exit 1 )
75-
7655
docs:
7756
runs-on: ubuntu-latest
7857
timeout-minutes: 10
7958
strategy:
8059
matrix:
81-
python-version: [3.8]
60+
python-version: [3.11]
8261
steps:
8362
- uses: actions/checkout@v2
8463
- name: Set up Python ${{ matrix.python-version }}

.pre-commit-config.yaml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ ci:
44

55
repos:
66
- repo: https://github.com/pre-commit/pre-commit-hooks
7-
rev: v4.4.0
7+
rev: v4.5.0
88
hooks:
99

1010
- id: check-json
@@ -19,7 +19,7 @@ repos:
1919
exclude: *exclude_pre_commit_hooks
2020

2121
- repo: https://github.com/psf/black
22-
rev: 23.9.1
22+
rev: 23.12.1
2323
hooks:
2424
- id: black
2525
language_version: python3 # Should be a command that runs python3.6+
@@ -32,19 +32,19 @@ repos:
3232
args: [--count, --show-source, --statistics]
3333

3434
- repo: https://github.com/pycqa/isort
35-
rev: 5.12.0
35+
rev: 5.13.2
3636
hooks:
3737
- id: isort
3838
args: [--profile, black, --filter-files]
3939

4040
- repo: https://github.com/asottile/pyupgrade
41-
rev: v3.14.0
41+
rev: v3.15.0
4242
hooks:
4343
- id: pyupgrade
4444
args: [--py37-plus]
4545

4646
- repo: https://github.com/pre-commit/mirrors-mypy
47-
rev: v1.5.1
47+
rev: v1.8.0
4848
hooks:
4949
- id: mypy
5050
additional_dependencies:

aiida_cp2k/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,6 @@
66
###############################################################################
77
"""The official AiiDA plugin for CP2K."""
88

9-
__version__ = "2.0.0"
9+
__version__ = "2.1.0b1"
1010

1111
# EOF

aiida_cp2k/parsers/__init__.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@
66
###############################################################################
77
"""AiiDA-CP2K output parser."""
88

9+
import re
10+
911
import ase
1012
import numpy as np
1113
from aiida import common, engine, orm, parsers, plugins
@@ -128,7 +130,7 @@ def _read_stdout(self):
128130
def _parse_trajectory(self, structure):
129131
"""CP2K trajectory parser."""
130132

131-
symbols = [str(site.kind_name) for site in structure.sites]
133+
symbols = [re.sub(r"\d+", "", str(site.kind_name)) for site in structure.sites]
132134

133135
# Handle the positions trajectory
134136
xyz_traj_fname = self.node.process_class._DEFAULT_TRAJECT_XYZ_FILE_NAME

aiida_cp2k/workchains/base.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ def results(self):
6565
trajectories = self._collect_all_trajetories()
6666
if trajectories:
6767
self.report("Work chain completed successfully, collecting all trajectories")
68-
if self.ctx.inputs.parameters.get("GLOBAL", {}).get("RUN_TYPE") == "GEO_OPT":
68+
if self.ctx.inputs.parameters.get_dict().get("GLOBAL", {}).get("RUN_TYPE") == "GEO_OPT":
6969
output_trajectory = utils.merge_trajectory_data_non_unique(*trajectories)
7070
else:
7171
output_trajectory = utils.merge_trajectory_data_unique(*trajectories)

docs/source/conf.py

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,13 +15,9 @@
1515
import time
1616
from typing import Dict
1717

18-
from aiida.manage.configuration import load_documentation_profile
18+
from aiida.manage.configuration import Profile, load_profile
1919

20-
# -- AiiDA-related setup --------------------------------------------------
21-
22-
# Load the dummy profile even if we are running locally, this way the documentation will succeed even if the current
23-
# default profile of the AiiDA installation does not use a Django backend.
24-
load_documentation_profile()
20+
load_profile(Profile("docs", {"process_control": {}, "storage": {}}))
2521

2622
# If we are not on READTHEDOCS load the Sphinx theme manually
2723
if not os.environ.get("READTHEDOCS", None):

pyproject.toml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ classifiers = [
1818
"Operating System :: MacOS :: MacOS X",
1919
"Programming Language :: Python :: 3",
2020
]
21-
requires-python = ">=3.8"
21+
requires-python = ">=3.9"
2222
dependencies = [
2323
"aiida-core>=2.0.0,<3.0.0",
2424
"aiida-gaussian-datatypes",
@@ -40,7 +40,7 @@ dev = [
4040
"pytest~=6.0",
4141
"pytest-cov~=2.11.1",
4242
"coverage",
43-
"pre-commit~=2.19",
43+
"pre-commit~=3.6",
4444
]
4545
docs = [
4646
"sphinx",
@@ -74,7 +74,7 @@ filterwarnings = [
7474
]
7575

7676
[tool.bumpver]
77-
current_version = "v2.0.0"
77+
current_version = "v2.1.0b1"
7878
version_pattern = "vMAJOR.MINOR.PATCH[PYTAGNUM]"
7979
commit_message = "Bump version {old_version} -> {new_version}."
8080
commit = true

0 commit comments

Comments
 (0)