Skip to content
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

Devops: Address various deprecation warnings from aiida-core #979

Merged
merged 1 commit into from
Dec 22, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -197,6 +197,7 @@ testpaths = [
'tests',
]
filterwarnings = [
'ignore:Object of type .* not in session, .* operation along .* will not proceed:sqlalchemy.exc.SAWarning',
'ignore:Creating AiiDA configuration folder.*:UserWarning',
'ignore::DeprecationWarning:frozendict:',
'ignore::DeprecationWarning:pkg_resources:',
Expand Down
2 changes: 1 addition & 1 deletion src/aiida_quantumespresso/workflows/xps.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
PwCalculation = CalculationFactory('quantumespresso.pw')
PwBaseWorkChain = WorkflowFactory('quantumespresso.pw.base')
PwRelaxWorkChain = WorkflowFactory('quantumespresso.pw.relax')
XyData = DataFactory('array.xy')
XyData = DataFactory('core.array.xy')


def validate_inputs(inputs, _):
Expand Down
2 changes: 1 addition & 1 deletion src/aiida_quantumespresso/workflows/xspectra/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ def define(cls, spec):
)
spec.input(
'upf2plotcore_code',
valid_type=orm.Code,
valid_type=orm.AbstractCode,
required=False,
help='The code node required for upf2plotcore.sh configured for ``aiida-shell``. '
'Must be provided if `core_wfc_data` is not provided.'
Expand Down
4 changes: 2 additions & 2 deletions src/aiida_quantumespresso/workflows/xspectra/crystal.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
PwRelaxWorkChain = WorkflowFactory('quantumespresso.pw.relax')
XspectraBaseWorkChain = WorkflowFactory('quantumespresso.xspectra.base')
XspectraCoreWorkChain = WorkflowFactory('quantumespresso.xspectra.core')
XyData = DataFactory('array.xy')
XyData = DataFactory('core.array.xy')


class XspectraCrystalWorkChain(ProtocolMixin, WorkChain):
Expand Down Expand Up @@ -128,7 +128,7 @@ def define(cls, spec):
)
spec.input(
'upf2plotcore_code',
valid_type=orm.Code,
valid_type=orm.AbstractCode,
required=False,
help=(
'Code node for the upf2plotcore.sh ShellJob code.'
Expand Down
4 changes: 2 additions & 2 deletions tests/parsers/test_neb.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ def test_neb_default(fixture_localhost, generate_calc_job_node, generate_parser,

assert calcfunction.is_finished, calcfunction.exception
assert calcfunction.is_finished_ok, calcfunction.exit_message
assert not [log for log in orm.Log.objects.get_logs_for(node) if log.levelname == 'ERROR']
assert not [log for log in orm.Log.collection.get_logs_for(node) if log.levelname == 'ERROR']
assert 'output_parameters' in results
assert 'output_mep' in results
assert 'output_trajectory' in results
Expand Down Expand Up @@ -89,7 +89,7 @@ def test_neb_all_iterations(

assert calcfunction.is_finished, calcfunction.exception
assert calcfunction.is_finished_ok, calcfunction.exit_message
assert not [log for log in orm.Log.objects.get_logs_for(node) if log.levelname == 'ERROR']
assert not [log for log in orm.Log.collection.get_logs_for(node) if log.levelname == 'ERROR']
assert 'output_parameters' in results
assert 'output_mep' in results
assert 'output_trajectory' in results
Expand Down
4 changes: 2 additions & 2 deletions tests/parsers/test_open_grid.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@ def test_open_grid_default(fixture_localhost, generate_calc_job_node, generate_p

data_regression.check({
'output_parameters': results['output_parameters'].get_dict(),
'kpoints_mesh': results['kpoints_mesh'].attributes,
'kpoints': results['kpoints'].attributes,
'kpoints_mesh': results['kpoints_mesh'].base.attributes.all,
'kpoints': results['kpoints'].base.attributes.all,
})

num_regression.check({
Expand Down
2 changes: 1 addition & 1 deletion tests/parsers/test_ph.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ def test_ph_default(test_name, fixture_localhost, generate_calc_job_node, genera

assert calcfunction.is_finished, calcfunction.exception
assert calcfunction.is_finished_ok, calcfunction.exit_message
assert not [log for log in orm.Log.objects.get_logs_for(node) if log.levelname == 'ERROR']
assert not [log for log in orm.Log.collection.get_logs_for(node) if log.levelname == 'ERROR']
assert 'output_parameters' in results
data_regression.check(results['output_parameters'].get_dict())

Expand Down
Loading