Skip to content

Commit

Permalink
Merge pull request #10868 from amaltaro/fix-10867
Browse files Browse the repository at this point in the history
Remove leading ../../ from logArchive tarballs
  • Loading branch information
amaltaro authored Oct 13, 2021
2 parents 47b1573 + 2cb1032 commit 3ff3441
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/python/WMCore/WMSpec/Steps/Executors/LogArchive.py
Original file line number Diff line number Diff line change
Expand Up @@ -181,9 +181,9 @@ def execute(self, emulator=None):
tarName = 'logArchive.tar.gz'
tarBallLocation = os.path.join(self.stepSpace.location, tarName)
with tarfile.open(tarBallLocation, 'w:gz') as tarBall:
for f in logFilesToArchive:
tarBall.add(name=f,
arcname=f.replace(self.stepSpace.taskSpace.location, '', 1).lstrip('/'))
for fName in logFilesToArchive:
altName = fName.replace(pilotScratchDir, '', 1)
tarBall.add(name=fName, arcname=altName)

fileInfo = {'LFN': self.getLFN(tarName),
'PFN': tarBallLocation,
Expand Down

0 comments on commit 3ff3441

Please sign in to comment.