Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion doc/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -139,13 +139,20 @@
"printindex": r"\def\twocolumn[#1]{#1}\printindex",
}

# WORKAROUND: Python <3.12
# Reusing the f-string's own quote character inside its expression - and a backslash in it - both need PEP 701.
# The escaped project name is built first, so this file still parses on Python 3.11.
# Replace by inlining it again:
# f"The {pythonProject.replace("_", r"\_")} Documentation",
latexProject = pythonProject.replace("_", r"\_")

# Grouping the document tree into LaTeX files. List of tuples
# (source start file, target name, title,
# author, documentclass [howto, manual, or own class]).
latex_documents = [
( master_doc,
f"{pythonProject}.tex",
f"The {pythonProject.replace("_", r"\_")} Documentation",
f"The {latexProject} Documentation",
"Patrick Lehmann",
"manual"
),
Expand Down
8 changes: 7 additions & 1 deletion pyEDAA/OutputFilter/CLI/Configuration.py
Original file line number Diff line number Diff line change
Expand Up @@ -703,8 +703,14 @@ def _ParsePolicies(self, policies: CommentedMap) -> None:
if policies["hasLatches"] == "error":
self._hasLatches = Action.Error
else:
# WORKAROUND: Python <3.12
# Reusing the f-string's own quote character inside its expression needs PEP 701. On Python 3.11
# this is a 'SyntaxError' raised at import, which takes the whole module with it.
# Replace by:
# ConfigurationWarning(f"tools.vivado.policies.hasLatches: Unknown value '{policies["hasLatches"]}'."))
hasLatches = policies["hasLatches"]
WarningCollector.Raise(
ConfigurationWarning(f"tools.vivado.policies.hasLatches: Unknown value '{policies["hasLatches"]}'."))
ConfigurationWarning(f"tools.vivado.policies.hasLatches: Unknown value '{hasLatches}'."))

def _ParseRuleSetAction(self, actionConfig: Any) -> LineAction:
if not isinstance(actionConfig, str):
Expand Down
Loading