We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3a352ca commit 56e6fcbCopy full SHA for 56e6fcb
pytensor/utils.py
@@ -191,9 +191,8 @@ def hash_from_code(msg: str | bytes) -> str:
191
# but Python 3 (unicode) strings don't.
192
if isinstance(msg, str):
193
msg = msg.encode()
194
- # Python 3 does not like module names that start with
195
- # a digit.
196
- return "m" + hashlib.sha256(msg).hexdigest()
+ # Python 3 does not like module names that start with a digit.
+ return f"m{hashlib.sha256(msg).hexdigest()}"
197
198
199
def uniq(seq: Sequence) -> list:
0 commit comments