Skip to content

3.1.25 broke local conda smithy rerender on windows #62

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

Closed
h-vetinari opened this issue Jan 8, 2022 · 3 comments
Closed

3.1.25 broke local conda smithy rerender on windows #62

h-vetinari opened this issue Jan 8, 2022 · 3 comments

Comments

@h-vetinari
Copy link
Member

h-vetinari commented Jan 8, 2022

Before rerendering locally, I usually update all my dependencies. Since #61 was merged, I've been running into errors where gitpython seems to lock itself out of touching git.

(builder) C:\Users\[...]\Dev\conda-forge\scipy-feedstock>conda smithy rerender
INFO:conda_smithy.configure_feedstock:Downloading conda-forge-pinning-2022.01.08.19.53.23
INFO:conda_smithy.configure_feedstock:Extracting conda-forge-pinning to C:\Users\[...]\AppData\Local\Temp\tmp8navqa9w
Traceback (most recent call last):
  File "C:\Users\[...]\.conda\envs\builder\Scripts\conda-smithy-script.py", line 9, in <module>
    sys.exit(main())
  File "C:\Users\[...]\.conda\envs\builder\lib\site-packages\conda_smithy\cli.py", line 681, in main
    args.subcommand_func(args)
  File "C:\Users\[...]\.conda\envs\builder\lib\site-packages\conda_smithy\cli.py", line 486, in __call__
    self._call(args, tmpdir)
  File "C:\Users\[...]\.conda\envs\builder\lib\site-packages\conda_smithy\cli.py", line 491, in _call
    configure_feedstock.main(
  File "C:\Users\[...]\.conda\envs\builder\lib\site-packages\conda_smithy\configure_feedstock.py", line 2164, in main
    config = _load_forge_config(forge_dir, exclusive_config_file, forge_yml)
  File "C:\Users\[...]\.conda\envs\builder\lib\site-packages\conda_smithy\configure_feedstock.py", line 1842, in _load_forge_config
    remove_file_or_dir(os.path.join(forge_dir, old_file))
  File "C:\Users\[...]\.conda\envs\builder\lib\site-packages\conda_smithy\feedstock_io.py", line 70, in remove_file_or_dir
    return remove_file(filename)
  File "C:\Users\[...]\.conda\envs\builder\lib\site-packages\conda_smithy\feedstock_io.py", line 79, in remove_file
    touch_file(filename)
  File "C:\Users\[...]\.conda\envs\builder\lib\site-packages\conda_smithy\feedstock_io.py", line 65, in touch_file
    fh.write("")
  File "C:\Users\[...]\.conda\envs\builder\lib\contextlib.py", line 126, in __exit__
    next(self.gen)
  File "C:\Users\[...]\.conda\envs\builder\lib\site-packages\conda_smithy\feedstock_io.py", line 60, in write_file
    repo.index.add([filename])
  File "C:\Users\[...]\.conda\envs\builder\lib\site-packages\git\index\base.py", line 823, in add
    self.write(ignore_extension_data=not write_extension_data)
  File "C:\Users\[...]\.conda\envs\builder\lib\site-packages\git\index\base.py", line 221, in write
    lfd.commit()
  File "C:\Users\[...]\.conda\envs\builder\lib\site-packages\gitdb\util.py", line 359, in commit
    self._end_writing(successful=True)
  File "C:\Users\[...]\.conda\envs\builder\lib\site-packages\gitdb\util.py", line 384, in _end_writing
    remove(self._filepath)
  File "C:\Users\[...]\.conda\envs\builder\lib\site-packages\gitdb\util.py", line 83, in remove
    return _retry(os.remove, *args, **kwargs)
  File "C:\Users\[...]\.conda\envs\builder\lib\site-packages\gitdb\util.py", line 77, in _retry
    return func(*args, **kwargs)
PermissionError: [WinError 32] The process cannot access the file because it is being used by another process: 'C:\\Users\\[...]\\Dev\\conda-forge\\scipy-feedstock\\.git\\index'

I've made sure no other processes were running (even restarted the machine), but the error persists. Reverting to 3.1.24 makes the rerender pass again.

CC @conda-forge/conda-smithy

Edit: CC @conda-forge/core (@conda-forge/conda-smithy shows 0 members; is that transitive maintainership working correctly)?

@xhochy
Copy link
Member

xhochy commented Jan 9, 2022

@skshetry
Copy link
Member

@h-vetinari, this is now fixed and released in 3.1.26. Can be closed when #63 gets merged.

@h-vetinari
Copy link
Member Author

Thanks a lot! :)

@xhochy xhochy closed this as completed Jan 11, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants