This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Title: Error copying directory to _static in Sphinx
Type: crash Stage:
Components: Documentation tools (Sphinx) Versions:
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: georg.brandl Nosy List: georg.brandl, tcdelaney
Priority: normal Keywords:

Created on 2008-10-08 22:28 by tcdelaney, last changed 2022-04-11 14:56 by admin. This issue is now closed.

File name Uploaded Description Edit
sphinx_static_exc.txt tcdelaney, 2008-10-08 22:28 Stack trace
Messages (5)
msg74551 - (view) Author: Tim Delaney (tcdelaney) Date: 2008-10-08 22:28
If there is a directory to be copied to _static, Sphinx first attempts 
to delete any directory by the same name in the _static directory. See 
attached sphinx_static_exc.txt for the exception.

The simplest fix is to change the call (line 595, Sphinx 0.4.2) to::



    shutil.rmtree(targetname, ignore_errors=True)

It would also be preferable if instead of blindly doing rmtree/copytree, 
only updated files be copied to _static.
msg74552 - (view) Author: Tim Delaney (tcdelaney) Date: 2008-10-08 22:31
Oops - didn't complete my thought. The issue is that if the directory 
does not already exist, the attached exception is raised.
msg74956 - (view) Author: Georg Brandl (georg.brandl) * (Python committer) Date: 2008-10-18 18:15
But there is a "path.exists()" condition around the rmtree, isn't there?
msg74957 - (view) Author: Tim Delaney (tcdelaney) Date: 2008-10-18 19:56
Confirmed fixed in 0.43 - this issue can be closed.
msg74959 - (view) Author: Georg Brandl (georg.brandl) * (Python committer) Date: 2008-10-18 20:55
Great! Thanks for the patience.
Date User Action Args
2022-04-11 14:56:40adminsetgithub: 48331
2008-10-18 20:55:26georg.brandlsetstatus: open -> closed
resolution: fixed
messages: + msg74959
2008-10-18 19:56:30tcdelaneysetmessages: + msg74957
2008-10-18 18:15:19georg.brandlsetmessages: + msg74956
2008-10-08 22:31:58tcdelaneysetmessages: + msg74552
2008-10-08 22:28:35tcdelaneycreate