Build: #19 failed
Job: Test Tools MPI Many Linux 2.28 Rocky 8.10 Py3.10 failed
exceptions: Test case result
The below summarizes the result of the test " exceptions" in build 19 of CASA - CMake MPI - Test Tools MPI Many Linux 2.28 Rocky 8.10 Py3.10.
- Description
- exceptions
- Test class
- tests.tools.image.test_tool_image_pbcor.ia_pbcor_test
- Method
- test_exceptions
- Duration
- < 1 sec
- Status
- Failed (Existing Failure)
Error Log
FileExistsError: [Errno 17] File exists: 'pbtest1_co2.im'
self = <test_tool_image_pbcor.ia_pbcor_test testMethod=test_exceptions>
def setUp(self):
self.im1 = "pbtest1_im.fits"
self.pb1 = "pbtest1_pb.fits"
self.co1_1 = "pbtest1_co1.fits"
self.co1_2 = "pbtest1_co2.im"
self.im2 = "pb2_im.fits"
self.pb2 = "pb2_pb.fits"
self.co2 = "pb2_co.im"
self.pb4 = "CAS_5096template.im"
self.outfile = ''
self.mymask = ''
self.imagename = ''
self.pbimage = ''
self.newpb = ''
data = [self.im1, self.pb1, self.co1_1, self.co1_2, self.im2, self.pb2, self.co2, self.pb4]
for f in data:
resolved = os.path.join(datapath, f)
if os.path.isdir(resolved):
> shutil.copytree(resolved, f)
../../../casatools/tests/tools/image/test_tool_image_pbcor.py:68:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/usr/local/lib/python3.10/shutil.py:556: in copytree
return _copytree(entries=entries, src=src, dst=dst, symlinks=symlinks,
/usr/local/lib/python3.10/shutil.py:457: in _copytree
os.makedirs(dst, exist_ok=dirs_exist_ok)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
name = 'pbtest1_co2.im', mode = 511, exist_ok = False
def makedirs(name, mode=0o777, exist_ok=False):
"""makedirs(name [, mode=0o777][, exist_ok=False])
Super-mkdir; create a leaf directory and all intermediate ones. Works like
mkdir, except that any intermediate path segment (not just the rightmost)
will be created if it does not exist. If the target directory already
exists, raise an OSError if exist_ok is False. Otherwise no exception is
raised. This is recursive.
"""
head, tail = path.split(name)
if not tail:
head, tail = path.split(head)
if head and tail and not path.exists(head):
try:
makedirs(head, exist_ok=exist_ok)
except FileExistsError:
# Defeats race condition when another thread created the path
pass
cdir = curdir
if isinstance(tail, bytes):
cdir = bytes(curdir, 'ASCII')
if tail == cdir: # xxx/newdir/. exists if xxx/newdir exists
return
try:
> mkdir(name, mode)
E FileExistsError: [Errno 17] File exists: 'pbtest1_co2.im'
/usr/local/lib/python3.10/os.py:225: FileExistsError