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

Fix exception raising in subjobXLMList #2373

Merged
merged 1 commit into from
Jul 8, 2024
Merged
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
6 changes: 3 additions & 3 deletions ganga/GangaCore/Core/GangaRepository/SubJobXMLList.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ def __init__(self, jobDirectory='', registry=None, dataFileName='data', load_bac
registry (Registry): the registry managing me,
dataFileName (str): incase it ever changes, normally 'data'
load_backup (bool): are we using the backpus only/first? This used to be set like this btw
paret (Job): parent of self after constuction
parent (Job): parent of self after constuction
"""
super(SubJobXMLList, self).__init__()

Expand Down Expand Up @@ -126,7 +126,7 @@ def appendJobs(self, job_dict, parent):
# First check the id is not already in the job cache
for k in job_dict.keys():
if k in self._cachedJobs.keys():
raise RepositoryError("Subjob key %s is already in the subjob XML cache!" % k)
raise RepositoryError(self._registry.repository, "Subjob key %s is already in the subjob XML cache!" % k)
# Now set the parent for the new subjobs
for k, v in job_dict.items():
v._setParent(parent)
Expand Down Expand Up @@ -414,7 +414,7 @@ def _getItem(self, index):
if isinstance(x, IOError) and x.errno == errno.ENOENT:
raise IOError("Subobject %s not found: %s" % (index, x))
else:
raise RepositoryError(self, "IOError on loading subobject %s: %s" % (index, x))
raise RepositoryError(self._registry.repository, "IOError on loading subobject %s: %s" % (index, x))

from GangaCore.Core.GangaRepository.VStreamer import from_file

Expand Down
Loading