Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TypeError: '<' not supported between instances of 'dict' and 'dict' when using a custom wheel from a URL #220

Closed
agriyakhetarpal opened this issue Mar 3, 2025 · 3 comments

Comments

@agriyakhetarpal
Copy link
Member

xref duckdb/duckdb-pyodide#6. This is reproducible when using PyScript and Pyoddie. I've filed this issue here as a reminder for us to investigate, as it concerns our behaviour with custom wheels and isn't an issue with PyScript.

Stack trace:

Uncaught (in promise) PythonError: Traceback (most recent call last):
  File "/lib/python3.12/site-packages/micropip/package_manager.py", line 175, in freeze
    return freeze_lockfile(self.repodata_packages, self.repodata_info)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/lib/python3.12/site-packages/micropip/freeze.py", line 16, in freeze_lockfile
    return json.dumps(freeze_data(lockfile_packages, lockfile_info))
                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/lib/python3.12/site-packages/micropip/freeze.py", line 27, in freeze_data
    packages = dict(sorted(package_items))
                    ^^^^^^^^^^^^^^^^^^^^^
TypeError: '<' not supported between instances of 'dict' and 'dict'
@agriyakhetarpal
Copy link
Member Author

Testing this a bit: I can't reproduce it on the stable Pyodide console (the latest one won't work as we've broken the ABI now), but I can do so with the linked reproducer in the issue.

We should be able to point to a local Pyodide (and micropip) installation using https://docs.pyscript.net/2025.2.4/user-guide/running-offline/#install-pyodide-locally.

@ryanking13
Copy link
Member

Isn't it already reported and fixed by #171?

@agriyakhetarpal
Copy link
Member Author

Ah, thanks, Gyeongjae. I didn't see that one!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants