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
Bug report
After adding "traceback" and "typing" modules to freeze_modules.py, "sorted" will raise TypeError when compiling.
def generate_frozenset(self, name: str, fs: FrozenSet[object]) -> str:
ret = self.generate_tuple(name, tuple(sorted(fs)))
self.write("// TODO: The above tuple should be a frozenset")
return ret
Frozen "traceback" raise:
TypeError: '<' not supported between instances of 'int' and 'NoneType'
Frozen "typing" raise:
TypeError: '<' not supported between instances of 'str' and 'NoneType'
I don't understand what the sorted does in the Frozen module here.
Finally, I used a temporary method to unsort these two FrozenSet in the exception handling, and successfully passed the compilation.
def generate_frozenset(self, name: str, fs: FrozenSet[object]) -> str:
try:
ret = self.generate_tuple(name, tuple(sorted(fs)))
except TypeError:
if name == 'traceback_toplevel_consts_46_consts_14_consts_9' or \
name == 'typing_toplevel_consts_112_consts_1':
ret = self.generate_tuple(name, tuple(fs))
else:
raise
self.write("// TODO: The above tuple should be a frozenset")
return ret
Environment
I checkout v3.11.0b4 after cloning, use Ubuntu 22.04 LTS, arch is x86_64.
The text was updated successfully, but these errors were encountered:
Bug report
After adding "traceback" and "typing" modules to freeze_modules.py, "sorted" will raise TypeError when compiling.
Frozen "traceback" raise:
Frozen "typing" raise:
After that I printed fs:
"traceback" and "typing" are output as follows
I don't understand what the sorted does in the Frozen module here.
Finally, I used a temporary method to unsort these two FrozenSet in the exception handling, and successfully passed the compilation.
Environment
I checkout v3.11.0b4 after cloning, use Ubuntu 22.04 LTS, arch is x86_64.
The text was updated successfully, but these errors were encountered: