Skip to content
Closed
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
4 changes: 1 addition & 3 deletions pyiron_base/jobs/job/generic.py
Original file line number Diff line number Diff line change
Expand Up @@ -663,9 +663,7 @@ def _internal_copy_to(
return new_job_core, file_project, hdf5_project, reloaded

# Reload object from HDF5 file
if not static_isinstance(
obj=project.__class__, obj_type="pyiron_base.jobs.job.base.JobCore"
):
if str(project.__class__) != str(JobCore):
Copy link
Contributor

@pmrv pmrv Oct 8, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This check still compares the class of project with JobCore, so it's always True, I suppose new_job_core was initially intended. I've followed the code paths a bit and _job_reload_after_copy ends up calling new_job_core.from_hdf, I'm guessing the simplest change would actually be to drop the if here, always call _job_reload_after_copy and then change the implementation in JobCore to pass.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree, it remains unclear when the code is actually used. So let's close the pull request right now.

_job_reload_after_copy(
job=new_job_core, delete_file_after_copy=delete_file_after_copy
)
Expand Down
Loading