{"html_url": "https://github.com/simonw/datasette/issues/1609#issuecomment-1020456608", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1609", "id": 1020456608, "node_id": "IC_kwDOBm6k_c480u6g", "user": {"value": 9599, "label": "simonw"}, "created_at": "2022-01-24T19:20:09Z", "updated_at": "2022-01-24T19:20:09Z", "author_association": "OWNER", "body": "Uvicorn have a release out now that would have fixed this issue if I hadn't shipped my own fix: https://github.com/encode/uvicorn/releases/tag/0.17.0.post1", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 1109884720, "label": "Ensure \"pip install datasette\" still works with Python 3.6"}, "performed_via_github_app": null} {"html_url": "https://github.com/simonw/datasette/issues/1609#issuecomment-1018104868", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1609", "id": 1018104868, "node_id": "IC_kwDOBm6k_c48rwwk", "user": {"value": 9599, "label": "simonw"}, "created_at": "2022-01-21T02:24:13Z", "updated_at": "2022-01-21T02:24:13Z", "author_association": "OWNER", "body": "Just shipped 0.60.1 with the fix - and tested that `pip install datasette` does indeed work correctly on Python 3.6.", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 1109884720, "label": "Ensure \"pip install datasette\" still works with Python 3.6"}, "performed_via_github_app": null} {"html_url": "https://github.com/simonw/datasette/issues/1609#issuecomment-1018094767", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1609", "id": 1018094767, "node_id": "IC_kwDOBm6k_c48ruSv", "user": {"value": 9599, "label": "simonw"}, "created_at": "2022-01-21T02:04:14Z", "updated_at": "2022-01-21T02:04:14Z", "author_association": "OWNER", "body": "So I don't need to release 0.60.1 AND 0.60.2 after all - I can just release 0.60.1 with a bug fix that it no longer breaks installation for Python 3.6.", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 1109884720, "label": "Ensure \"pip install datasette\" still works with Python 3.6"}, "performed_via_github_app": null} {"html_url": "https://github.com/simonw/datasette/issues/1609#issuecomment-1018092984", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1609", "id": 1018092984, "node_id": "IC_kwDOBm6k_c48rt24", "user": {"value": 9599, "label": "simonw"}, "created_at": "2022-01-21T02:00:38Z", "updated_at": "2022-01-21T02:00:38Z", "author_association": "OWNER", "body": "Out of curiosity, I installed this latest `setup.py` file using both Python 3.6 and Python 3.10, ran `pip freeze` on both of them and created a Gist to compare the difference. The result is here: https://gist.github.com/simonw/2e7d5b1beba675ef9a5bcd310cadc372/revisions\r\n\r\nFrom that, it looks like the Python packages in my dependencies which have released new versions that don't work with Python 3.6 are:\r\n\r\n- https://pypi.org/project/janus/#history\r\n- https://pypi.org/project/Pint/#history\r\n- https://pypi.org/project/platformdirs/#history\r\n- https://pypi.org/project/uvicorn/#history (already discussed)\r\n\r\nSure enough, for the first three of those browsing through their recent versions on PyPI confirms that they switched from e.g. \"Requires: Python >=3.6\" on https://pypi.org/project/janus/0.7.0/ to \"Requires: Python >=3.7\" on https://pypi.org/project/janus/1.0.0/", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 1109884720, "label": "Ensure \"pip install datasette\" still works with Python 3.6"}, "performed_via_github_app": null} {"html_url": "https://github.com/simonw/datasette/issues/1609#issuecomment-1018091322", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1609", "id": 1018091322, "node_id": "IC_kwDOBm6k_c48rtc6", "user": {"value": 9599, "label": "simonw"}, "created_at": "2022-01-21T01:56:42Z", "updated_at": "2022-01-21T01:56:42Z", "author_association": "OWNER", "body": "OK, the environment markers approach seems to work!", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 1109884720, "label": "Ensure \"pip install datasette\" still works with Python 3.6"}, "performed_via_github_app": null} {"html_url": "https://github.com/simonw/datasette/issues/1609#issuecomment-1018086697", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1609", "id": 1018086697, "node_id": "IC_kwDOBm6k_c48rsUp", "user": {"value": 9599, "label": "simonw"}, "created_at": "2022-01-21T01:46:43Z", "updated_at": "2022-01-21T01:46:43Z", "author_association": "OWNER", "body": "https://github.com/simonw/datasette/runs/4890775227?check_suite_focus=true - the tests passed on Python 3.6 for this commit with the pinned dependencies: https://github.com/simonw/datasette/commit/41060e7e7cb838328c879de6a98ae794dc1886d0", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 1109884720, "label": "Ensure \"pip install datasette\" still works with Python 3.6"}, "performed_via_github_app": null} {"html_url": "https://github.com/simonw/datasette/issues/1609#issuecomment-1018086273", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1609", "id": 1018086273, "node_id": "IC_kwDOBm6k_c48rsOB", "user": {"value": 9599, "label": "simonw"}, "created_at": "2022-01-21T01:45:46Z", "updated_at": "2022-01-21T01:45:46Z", "author_association": "OWNER", "body": "This whole thing reminds me of my ongoing internal debate about version pinning: should the Datasette package released to PyPI pin to the exact versions of the dependencies that are known to work, or should it allow a range of dependencies so users can pick other versions of the dependencies to use in their environment?\r\n\r\nAs I understand it, the general rule is to use exact pinning for applications but use ranges for libraries.\r\n\r\nDatasette is almost entirely an application... but it can also be used as a library - and in fact I'm hoping to encourage that usage more in the future, see:\r\n- #1398\r\n\r\nI'd also like to release a packaged version of Datasette that doesn't require Uvicorn, for running on AWS Lambda and other function-as-a-service platforms. Those platforms have their own HTTP layer and hence don't need the Uvicorn dependency.\r\n\r\nMaybe the answer is to have a `datasette-core` package which provides the core of Datasette with unpinned dependencies and no Uvicorn, and then have the existing `datasette` package provide the Datasette CLI tool with Uvicorn and pinned dependencies?", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 1109884720, "label": "Ensure \"pip install datasette\" still works with Python 3.6"}, "performed_via_github_app": null} {"html_url": "https://github.com/simonw/datasette/issues/1609#issuecomment-1018082792", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1609", "id": 1018082792, "node_id": "IC_kwDOBm6k_c48rrXo", "user": {"value": 9599, "label": "simonw"}, "created_at": "2022-01-21T01:37:11Z", "updated_at": "2022-01-21T01:37:11Z", "author_association": "OWNER", "body": "Another option from https://twitter.com/samuel_hames/status/1484327636860293121 - environment markers, described in https://www.python.org/dev/peps/pep-0508/#environment-markers\r\n\r\nFound some examples of those in use using GitHub code search: https://cs.github.com/?scopeName=All+repos&scope=&q=%22%3Bpython_version%22+path%3Asetup.py - in particular https://github.com/xmendez/wfuzz/blob/1b695ee9a87d66a7d7bf6cae70d60a33fae51541/setup.py#L31-L38\r\n\r\n```python\r\ninstall_requires = [\r\n 'pycurl',\r\n 'pyparsing<2.4.2;python_version<=\"3.4\"',\r\n 'pyparsing>=2.4*;python_version>=\"3.5\"',\r\n 'six',\r\n 'configparser;python_version<\"3.5\"',\r\n 'chardet',\r\n]\r\n```\r\nSo maybe I can ship 0.60.1 with loose dependencies _except_ for the `uvicorn` one on Python 3.6, using an environment marker.\r\n\r\nHere's my `setup.py` at the moment: https://github.com/simonw/datasette/blob/ffca55dfd7cc9b53522c2e5a2fa1ff67c9beadf2/setup.py#L44-L61\r\n\r\nOne other problem: there might be packages in that list right now which don't specify their 3.6 Python version but which will, at some point in the future, release a new version that doesn't work with 3.6 (like Uvicorn did) - in which case Python 3.6 installs would break in the future.\r\n\r\nI think what I'll do then is ship the `0.60.1` Python 3.6 version with strict upper limits on each version which are the current, tested-with-Datasette-on-Python3.6 versions.", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 1109884720, "label": "Ensure \"pip install datasette\" still works with Python 3.6"}, "performed_via_github_app": null} {"html_url": "https://github.com/simonw/datasette/issues/1609#issuecomment-1018077009", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1609", "id": 1018077009, "node_id": "IC_kwDOBm6k_c48rp9R", "user": {"value": 9599, "label": "simonw"}, "created_at": "2022-01-21T01:24:15Z", "updated_at": "2022-01-21T01:24:43Z", "author_association": "OWNER", "body": "Problem: if I ship this, it will be the most recent release of Datasette - but unlike other previous releases it has exactly pinned versions of all of the dependencies. Which is bad for people who run `pip install datasette` but want to not be stuck to those exact library versions.\r\n\r\nSo maybe I ship this as 0.60.1, then ship a 0.60.2 release directly afterwards which unpins the dependencies again and requires Python 3.7?", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 1109884720, "label": "Ensure \"pip install datasette\" still works with Python 3.6"}, "performed_via_github_app": null} {"html_url": "https://github.com/simonw/datasette/issues/1609#issuecomment-1018075357", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1609", "id": 1018075357, "node_id": "IC_kwDOBm6k_c48rpjd", "user": {"value": 9599, "label": "simonw"}, "created_at": "2022-01-21T01:20:56Z", "updated_at": "2022-01-21T01:20:56Z", "author_association": "OWNER", "body": "I used the combo of `pyenv` and `pipenv` to run tests and figure out what the most recent versions of each dependency were that worked on Python 3.6. I also clicked around in the latest releases on pages such as https://pypi.org/project/aiofiles\r\n\r\n```\r\ncd /tmp\r\ngit clone git@github.com:simonw/datasette\r\ncd /tmp/datasette\r\npipenv shell --python 3.6.10\r\npip install -e '.[test]'\r\npytest\r\n```\r\nI also used `pip freeze | grep black` to see which version was installed, since packages with `python_requires=` in them would automatically install the highest compatible version.", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 1109884720, "label": "Ensure \"pip install datasette\" still works with Python 3.6"}, "performed_via_github_app": null} {"html_url": "https://github.com/simonw/datasette/issues/1609#issuecomment-1018064620", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1609", "id": 1018064620, "node_id": "IC_kwDOBm6k_c48rm7s", "user": {"value": 9599, "label": "simonw"}, "created_at": "2022-01-21T01:00:12Z", "updated_at": "2022-01-21T01:00:12Z", "author_association": "OWNER", "body": "I think there are two possible solutions then:\r\n\r\n1. Convince Uvicorn to publish one last `0.16.1` version which includes that `python_requires=` line, such that there's a version of Uvicorn on PyPI that Python 3.6 can still install.\r\n2. Release a `0.60.1` version of Datasette which pins that Uvicorn version, and hence can be installed.\r\n\r\nI've made the request for 1) in Uvicorn Gitter here: https://gitter.im/encode/community?at=61ea044a6d9ba23328d0fa28\r\n\r\nI'm going to investigate option 2) myself now.", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 1109884720, "label": "Ensure \"pip install datasette\" still works with Python 3.6"}, "performed_via_github_app": null} {"html_url": "https://github.com/simonw/datasette/issues/1609#issuecomment-1018063681", "issue_url": "https://api.github.com/repos/simonw/datasette/issues/1609", "id": 1018063681, "node_id": "IC_kwDOBm6k_c48rmtB", "user": {"value": 9599, "label": "simonw"}, "created_at": "2022-01-21T00:58:25Z", "updated_at": "2022-01-21T00:58:32Z", "author_association": "OWNER", "body": "On Twitter: https://twitter.com/simonw/status/1484317711672877065\r\n\r\nHere's the problem: Uvicorn only added `python_requires` to their `setup.py` a few days ago, which means the releases they have out on PyPI at the moment don't specify the Python version they need, which is why this mechanism doesn't work as expected:\r\n- https://github.com/encode/uvicorn/pull/1328", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 1109884720, "label": "Ensure \"pip install datasette\" still works with Python 3.6"}, "performed_via_github_app": null}