You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, looks like your :math:\\Din the docstring ofcomparison.pyis throwing my interpreter, I'm onPython 3.12.3` Arch Linux OS
❯ python plot_color_gradients.py
/usr/lib/python3.12/site-packages/colorspacious/comparison.py:11: SyntaxWarning: invalid escape sequence '\D'
"""Computes the :math:`\Delta E` distance between pairs of colors.
I put a second backslash behind every single backslash in the docstring, and I can use the library now. I am not familiar with the :math: escapes, so I am not sure what that does to your document formatting.
I found discussion concerning the issue I faced on stackoverflow.com
If double-escapes break formatting for sphinx, maybe put the docstring in a separate file (?)
The text was updated successfully, but these errors were encountered:
emollier
added a commit
to emollier/colorspacious
that referenced
this issue
Nov 29, 2024
The docstring describing the deltaE function contains several
mathematical symbols with LaTeX-style syntax, causing python3.12 and
newer to throw SyntaxWarning, like reported in issue njsmith#32, or like
[Debian bug #1085424]. Converting it to raw string prevents attempts
to interpret the backslash character as if it were an invalid escape
sequence in a C string.
[Debian bug #1085424]: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1085424
Signed-off-by: Étienne Mollier <[email protected]>
Hi, looks like your
:math:\
\Din the docstring of
comparison.pyis throwing my interpreter, I'm on
Python 3.12.3` Arch Linux OSI put a second backslash behind every single backslash in the docstring, and I can use the library now. I am not familiar with the
:math:
escapes, so I am not sure what that does to your document formatting.I found discussion concerning the issue I faced on stackoverflow.com
If double-escapes break formatting for sphinx, maybe put the docstring in a separate file (?)
The text was updated successfully, but these errors were encountered: