html_url,issue_url,id,node_id,user,created_at,updated_at,author_association,body,reactions,issue,performed_via_github_app
https://github.com/simonw/sqlite-utils/issues/66#issuecomment-553171414,https://api.github.com/repos/simonw/sqlite-utils/issues/66,553171414,MDEyOklzc3VlQ29tbWVudDU1MzE3MTQxNA==,9599,2019-11-12T23:52:35Z,2019-11-12T23:52:35Z,OWNER,"If I do implement the correct definition of `.upsert()` I think I'll use this pattern, since it works in versions of SQLite prior to 3.24:
```sql
INSERT OR IGNORE INTO book(id) VALUES(1001);
UPDATE book SET name = 'Programming' WHERE id = 1001;
```","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",521868864,
https://github.com/simonw/sqlite-utils/issues/66#issuecomment-553171011,https://api.github.com/repos/simonw/sqlite-utils/issues/66,553171011,MDEyOklzc3VlQ29tbWVudDU1MzE3MTAxMQ==,9599,2019-11-12T23:50:52Z,2019-11-12T23:50:52Z,OWNER,"Fixing this is going to be a real pain. There's lots of code out there that uses `sqlite-utils` with the expectation that `upsert()` behaves as it currently does.
Maybe I need to introduce new terms for both of these different patterns and deprecate the existing `.upsert()` and `.upsert_all()` since their behaviour can't be changed?
Or maybe I fix this and ship `sqlite-utils 2.0` with a breaking change?","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",521868864,
https://github.com/simonw/sqlite-utils/issues/66#issuecomment-553170650,https://api.github.com/repos/simonw/sqlite-utils/issues/66,553170650,MDEyOklzc3VlQ29tbWVudDU1MzE3MDY1MA==,9599,2019-11-12T23:49:29Z,2019-11-12T23:49:29Z,OWNER,This relates to this bug: https://github.com/dogsheep/github-to-sqlite/pull/8#issuecomment-549233778,"{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",521868864,
https://github.com/simonw/datasette/issues/622#issuecomment-552745890,https://api.github.com/repos/simonw/datasette/issues/622,552745890,MDEyOklzc3VlQ29tbWVudDU1Mjc0NTg5MA==,9599,2019-11-12T05:52:49Z,2019-11-12T05:52:49Z,OWNER,Released in [Datasette 0.31](https://datasette.readthedocs.io/en/latest/changelog.html#v0-31).,"{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",520715188,
https://github.com/simonw/datasette/issues/629#issuecomment-552739324,https://api.github.com/repos/simonw/datasette/issues/629,552739324,MDEyOklzc3VlQ29tbWVudDU1MjczOTMyNA==,9599,2019-11-12T05:23:22Z,2019-11-12T05:23:22Z,OWNER,"This change needs to wait until `datasette 0.31` has been published to PyPI, because the Docker containers produced by `datasette publish` run `pip install datasette` and they need to be able to retrieve a version from PyPI that works with 3.8.","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",521335335,
https://github.com/simonw/datasette/pull/404#issuecomment-552735296,https://api.github.com/repos/simonw/datasette/issues/404,552735296,MDEyOklzc3VlQ29tbWVudDU1MjczNTI5Ng==,9599,2019-11-12T05:02:13Z,2019-11-12T05:02:13Z,OWNER,Closing this because it was written against Sanic. #628 tracks future work on this topic.,"{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",403499298,
https://github.com/simonw/datasette/issues/594#issuecomment-552732500,https://api.github.com/repos/simonw/datasette/issues/594,552732500,MDEyOklzc3VlQ29tbWVudDU1MjczMjUwMA==,9599,2019-11-12T04:47:04Z,2019-11-12T04:47:04Z,OWNER,Closing this in favour of #627 which upgrades to uvicorn 0.10.4,"{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",506297048,
https://github.com/simonw/datasette/pull/595#issuecomment-552732445,https://api.github.com/repos/simonw/datasette/issues/595,552732445,MDEyOklzc3VlQ29tbWVudDU1MjczMjQ0NQ==,9599,2019-11-12T04:46:48Z,2019-11-12T04:46:48Z,OWNER,Closing this in favour of #627 which upgrades to uvicorn 0.10.4,"{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",506300941,
https://github.com/simonw/datasette/issues/622#issuecomment-552731544,https://api.github.com/repos/simonw/datasette/issues/622,552731544,MDEyOklzc3VlQ29tbWVudDU1MjczMTU0NA==,9599,2019-11-12T04:41:48Z,2019-11-12T04:41:48Z,OWNER,Here's where Python 3.5 started failing: https://travis-ci.org/simonw/datasette/builds/610682852,"{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",520715188,
https://github.com/simonw/datasette/issues/622#issuecomment-552730304,https://api.github.com/repos/simonw/datasette/issues/622,552730304,MDEyOklzc3VlQ29tbWVudDU1MjczMDMwNA==,9599,2019-11-12T04:34:55Z,2019-11-12T04:34:55Z,OWNER,Confirmed: upgrading to `uvicorn~=0.10.4` fixed it.,"{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",520715188,
https://github.com/simonw/datasette/issues/622#issuecomment-552729978,https://api.github.com/repos/simonw/datasette/issues/622,552729978,MDEyOklzc3VlQ29tbWVudDU1MjcyOTk3OA==,9599,2019-11-12T04:33:00Z,2019-11-12T04:33:00Z,OWNER,"Here's the error I'm getting with Python 3.8 at the moment:
```
~/Dropbox/Development/datasette $ venv-py3.8.0/bin/datasette --memory -p 8055
Serve! files=() (immutables=()) on port 8055
Traceback (most recent call last):
File ""venv-py3.8.0/bin/datasette"", line 11, in
load_entry_point('datasette', 'console_scripts', 'datasette')()
File ""/Users/simonw/Dropbox/Development/datasette/venv-py3.8.0/lib/python3.8/site-packages/click/core.py"", line 764, in __call__
return self.main(*args, **kwargs)
File ""/Users/simonw/Dropbox/Development/datasette/venv-py3.8.0/lib/python3.8/site-packages/click/core.py"", line 717, in main
rv = self.invoke(ctx)
File ""/Users/simonw/Dropbox/Development/datasette/venv-py3.8.0/lib/python3.8/site-packages/click/core.py"", line 1137, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File ""/Users/simonw/Dropbox/Development/datasette/venv-py3.8.0/lib/python3.8/site-packages/click/core.py"", line 956, in invoke
return ctx.invoke(self.callback, **ctx.params)
File ""/Users/simonw/Dropbox/Development/datasette/venv-py3.8.0/lib/python3.8/site-packages/click/core.py"", line 555, in invoke
return callback(*args, **kwargs)
File ""/Users/simonw/Dropbox/Development/datasette/datasette/cli.py"", line 365, in serve
uvicorn.run(ds.app(), host=host, port=port, log_level=""info"")
File ""/Users/simonw/Dropbox/Development/datasette/venv-py3.8.0/lib/python3.8/site-packages/uvicorn/main.py"", line 279, in run
server.run()
File ""/Users/simonw/Dropbox/Development/datasette/venv-py3.8.0/lib/python3.8/site-packages/uvicorn/main.py"", line 305, in run
self.config.setup_event_loop()
File ""/Users/simonw/Dropbox/Development/datasette/venv-py3.8.0/lib/python3.8/site-packages/uvicorn/config.py"", line 218, in setup_event_loop
loop_setup()
File ""/Users/simonw/Dropbox/Development/datasette/venv-py3.8.0/lib/python3.8/site-packages/uvicorn/loops/auto.py"", line 3, in auto_loop_setup
import uvloop
File ""/Users/simonw/Dropbox/Development/datasette/venv-py3.8.0/lib/python3.8/site-packages/uvloop/__init__.py"", line 7, in
from .loop import Loop as __BaseLoop # NOQA
File ""uvloop/includes/stdlib.pxi"", line 114, in init uvloop.loop
AttributeError: module 'sys' has no attribute 'set_coroutine_wrapper'
```
I'm pretty confident upgrading uvicorn (and uvloop with it) will fix this.","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",520715188,
https://github.com/simonw/datasette/issues/626#issuecomment-552729658,https://api.github.com/repos/simonw/datasette/issues/626,552729658,MDEyOklzc3VlQ29tbWVudDU1MjcyOTY1OA==,9599,2019-11-12T04:31:13Z,2019-11-12T04:31:13Z,OWNER,"I'm giving up on this. I spent a bunch of time trying to get it to work and couldn't.
My final attempt was inspired by https://github.com/encode/uvicorn/blob/e821fd1ff5653f989d500d41fa6ba070858f6843/tests/test_main.py#L10-L32
Here's the code that didn't work:
```
def test_asgi_app(app_client):
from uvicorn.config import Config
from uvicorn.main import Server
class CustomServer(Server):
def install_signal_handlers(self):
pass
def run_server():
asyncio.set_event_loop(asyncio.new_event_loop())
print(""ooh new loop"")
config = Config(app=app_client.asgi_app, limit_max_requests=1, port=8642)
config.load()
server = CustomServer(config=config)
server.run()
with concurrent.futures.ThreadPoolExecutor(max_workers=1) as executor:
future = executor.submit(run_server)
future.result()
while not server.started:
print(server.__dict__)
time.sleep(0.01)
assert 200 == urllib.request.urlopen(""http://localhost:8642/"").status
# This line will raise if there's an exception:
future.result()
```
I got `RuntimeError: There is no current event loop in thread 'ThreadPoolExecutor-1_0'`","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",521282013,