-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
add_css_file return wrong URI when dealing with local files on windows platform #12399
Comments
You're getting the error when running pytest? That's what the path suggests:
There were some recent changes to the way Sphinx's pytests are organized but it's strange that a build fails with a pytest path.
FYI, that base path is where pytest stores temporary files by default on Windows. |
the complete workflow is why would pytest copy all these files to a temp environment ? Is it because I'm using the "sphinx.testing.fixtures" in my conftext to build minimal documentations ? |
Assuming you're running |
The fact that everything is performed in the CI/CD environment is making it difficult to debug but thanks for the headstart I'll try to write this to an artifact file and check exactly what is happening there. The fact that the sphinx/sphinx/builders/html/__init__.py Line 328 in 53c31f7
I'll continue investigating and close the issue if it's not related to Sphinx. |
Describe the bug
I'm copying some css and js files from my local lib. Everything works fine with my Linux build but it fails when trying to make it run on windows platform.
How to Reproduce
the failing test are part of the sphinx-contrib/icon repository. The latest build can be found here: https://github.com/sphinx-contrib/icon/actions/runs/9315532969/job/25641896049?pr=33
In short my lib is adding few css and js to the app like this:
And the error I get when the build runs on windows is the following:
My guess is that add_css_file is not catching windows based absolute path the
D:
should not be here.Environment Information
I don't own a windows machine myself so the report i'm sending is the one from a linux based codespace. I think it won't be relevant:
Sphinx extensions
The text was updated successfully, but these errors were encountered: