You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@beam.apache.org by "Brian Hulette (Jira)" <ji...@apache.org> on 2021/04/15 21:59:00 UTC

[jira] [Created] (BEAM-12178) ReadCacheTest flakes on Windows

Brian Hulette created BEAM-12178:
------------------------------------

             Summary: ReadCacheTest flakes on Windows
                 Key: BEAM-12178
                 URL: https://issues.apache.org/jira/browse/BEAM-12178
             Project: Beam
          Issue Type: Improvement
          Components: sdk-py-core, test-failures
            Reporter: Brian Hulette


Example failure: https://github.com/apache/beam/pull/14382/checks?check_run_id=2325304757

{code}
________________________ ReadCacheTest.test_read_cache ________________________
[gw4] win32 -- Python 3.6.8 d:\a\beam\beam\sdks\python\target\.tox\py36-win\scripts\python.exe

self = <apache_beam.runners.interactive.caching.read_cache_test.ReadCacheTest testMethod=test_read_cache>

    def setUp(self):
>     ie.new_env()

apache_beam\runners\interactive\caching\read_cache_test.py:37: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
apache_beam\runners\interactive\interactive_environment.py:119: in new_env
    _interactive_beam_env.cleanup()
apache_beam\runners\interactive\interactive_environment.py:269: in cleanup
    self.evict_recording_manager(pipeline)
apache_beam\runners\interactive\interactive_environment.py:396: in evict_recording_manager
    rm.clear()
apache_beam\runners\interactive\recording_manager.py:339: in clear
    cache_manager.cleanup()
apache_beam\runners\interactive\caching\streaming_cache.py:385: in cleanup
    shutil.rmtree(self._cache_dir)
c:\hostedtoolcache\windows\python\3.6.8\x64\lib\shutil.py:500: in rmtree
    return _rmtree_unsafe(path, onerror)
c:\hostedtoolcache\windows\python\3.6.8\x64\lib\shutil.py:390: in _rmtree_unsafe
    _rmtree_unsafe(fullname, onerror)
c:\hostedtoolcache\windows\python\3.6.8\x64\lib\shutil.py:395: in _rmtree_unsafe
    onerror(os.unlink, fullname, sys.exc_info())
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

path = 'D:\\a\\beam\\beam\\sdks\\python\\target\\.tox\\py36-win\\tmp\\it-3ggiapgo2494199486000\\full'
onerror = <function rmtree.<locals>.onerror at 0x00000244BA770A60>

    def _rmtree_unsafe(path, onerror):
        try:
            if os.path.islink(path):
                # symlinks to directories are forbidden, see bug #1669
                raise OSError("Cannot call rmtree on a symbolic link")
        except OSError:
            onerror(os.path.islink, path, sys.exc_info())
            # can't continue even if onerror hook returns
            return
        names = []
        try:
            names = os.listdir(path)
        except OSError:
            onerror(os.listdir, path, sys.exc_info())
        for name in names:
            fullname = os.path.join(path, name)
            try:
                mode = os.lstat(fullname).st_mode
            except OSError:
                mode = 0
            if stat.S_ISDIR(mode):
                _rmtree_unsafe(fullname, onerror)
            else:
                try:
>                   os.unlink(fullname)
E                   PermissionError: [WinError 32] The process cannot access the file because it is being used by another process: 'D:\\a\\beam\\beam\\sdks\\python\\target\\.tox\\py36-win\\tmp\\it-3ggiapgo2494199486000\\full\\dacc5c76b6-2494199456376-2494201991240-2494199486000'
{code}|



--
This message was sent by Atlassian Jira
(v8.3.4#803005)