home / github / issue_comments

Menu
  • Search all tables
  • GraphQL API

issue_comments: 1646654818

This data as json

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/568#issuecomment-1646654818 https://api.github.com/repos/simonw/sqlite-utils/issues/568 1646654818 IC_kwDOCGYnMM5iJfVi 9599 2023-07-22T19:22:40Z 2023-07-22T19:22:40Z OWNER

I think this broke a test: ``` $ pytest tests/test_tracer.py
=============================================== test session starts ================================================ platform darwin -- Python 3.11.4, pytest-7.2.2, pluggy-1.0.0 rootdir: /Users/simon/Dropbox/Development/sqlite-utils plugins: icdiff-0.6, hypothesis-6.68.2 collected 2 items

tests/test_tracer.py F. [100%]

===================================================== FAILURES ===================================================== _________ test_tracer __________

def test_tracer():
    collected = []
    db = Database(
        memory=True, tracer=lambda sql, params: collected.append((sql, params))
    )
    db["dogs"].insert({"name": "Cleopaws"})
    db["dogs"].enable_fts(["name"])
    db["dogs"].search("Cleopaws")
  assert collected == [
        ("PRAGMA recursive_triggers=on;", None),
        ("select name from sqlite_master where type = 'view'", None),
        ("select name from sqlite_master where type = 'table'", None),
        ("select name from sqlite_master where type = 'view'", None),
        ("CREATE TABLE [dogs] (\n   [name] TEXT\n);\n        ", None),
        ("select name from sqlite_master where type = 'view'", None),
        ("INSERT INTO [dogs] ([name]) VALUES (?);", ["Cleopaws"]),
        ("select name from sqlite_master where type = 'view'", None),
        (
            "CREATE VIRTUAL TABLE [dogs_fts] USING FTS5 (\n    [name],\n    content=[dogs]\n)",
            None,
        ),
        (
            "INSERT INTO [dogs_fts] (rowid, [name])\n    SELECT rowid, [name] FROM [dogs];",
            None,
        ),
        ("select name from sqlite_master where type = 'view'", None),
    ]

E assert equals failed E [ [
E ('PRAGMA recursive_triggers=on;', None), ('PRAGMA recursive_triggers=on;', None),
E (
E "select name from sqlite_master where type =
E 'view'",
E None, ... E
E ...Full output truncated (13 lines hidden), use '-vv' to show

tests/test_tracer.py:12: AssertionError ============================================= short test summary info ============================================== FAILED tests/test_tracer.py::test_tracer - assert equals failed =========================================== 1 failed, 1 passed in 0.05s ============================================ ```

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
1816851056  
Powered by Datasette · Queries took 0.962ms · About: github-to-sqlite