Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin' into use_with_open
Browse files Browse the repository at this point in the history
  • Loading branch information
samwaseda committed Jul 31, 2024
2 parents 123d7b3 + 24597d4 commit 1f508ce
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 0 deletions.
1 change: 1 addition & 0 deletions .ci_support/environment-mini.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,4 @@ dependencies:
- sqlalchemy =2.0.31
- tqdm =4.66.4
- traitlets =5.14.3
- setuptools
4 changes: 4 additions & 0 deletions pyiron_base/jobs/job/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -972,6 +972,10 @@ def __del__(self):
del self._master_id
del self._status

@deprecate(
"Use job.output for results, job.files to access files; job.content to access HDF storage and "
"job.child_project to access children of master jobs."
)
def __getitem__(self, item):
"""
Get/read data from the HDF5 file, child jobs or access log files.
Expand Down
6 changes: 6 additions & 0 deletions pyiron_base/jobs/master/generic.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@
from functools import wraps
from typing import Union

from pyiron_snippets.deprecate import deprecate

from pyiron_base.interfaces.object import HasStorage
from pyiron_base.jobs.job.core import _doc_str_job_core_args
from pyiron_base.jobs.job.extension.jobstatus import job_status_finished_lst
Expand Down Expand Up @@ -311,6 +313,10 @@ def __len__(self):
"""
return len(self._job_name_lst)

@deprecate(
"Use job.output for results, job.files to access files; job.content to access HDF storage and "
"job.child_project to access children of master jobs."
)
def __getitem__(self, item):
"""
Get/ read data from the GenericMaster
Expand Down

0 comments on commit 1f508ce

Please sign in to comment.