Skip to content

Commit

Permalink
Don't use pathlib.PosixPath.
Browse files Browse the repository at this point in the history
Unfortunately and disappointingly Python doesn't have this API on Windows.
  • Loading branch information
whitequark authored Jun 5, 2024
1 parent 6c99ae1 commit ce46d0f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions sphinxcontrib/yowasp_wavedrom.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import re
import json
from pathlib import Path, PosixPath
from pathlib import Path
from docutils.parsers.rst import Directive
from docutils import nodes
import sphinx.application
Expand Down Expand Up @@ -79,7 +79,7 @@ def html_visit_wavedrom_diagram(self: sphinx.writers.html5.HTML5Translator, node
# subdirectory. The other option would be to use enough `../` to locate the top-level
# image directory; using leading `/` in the `<img>` tag isn't feasible since that would
# break on `file:///` URLs.
PosixPath(self.builder.current_docname).parent,
Path(self.builder.current_docname).parent,
self.builder.imagedir,
f'{basename}.svg'
)
Expand Down

0 comments on commit ce46d0f

Please sign in to comment.