home / github / issue_comments

Menu
  • Search all tables
  • GraphQL API

issue_comments: 938124652

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/datasette/issues/1470#issuecomment-938124652 https://api.github.com/repos/simonw/datasette/issues/1470 938124652 IC_kwDOBm6k_c436qVs 9599 2021-10-07T20:17:53Z 2021-10-07T20:18:55Z OWNER

Here's the exception: -> params[f"p{len(params)}"] = components[0] (Pdb) list 603 604 # Figure out the SQL for next-based-on-primary-key first 605 next_by_pk_clauses = [] 606 if use_rowid: 607 next_by_pk_clauses.append(f"rowid > :p{len(params)}") 608 -> params[f"p{len(params)}"] = components[0] 609 else: 610 # Apply the tie-breaker based on primary keys 611 if len(components) == len(pks): 612 param_len = len(params) 613 next_by_pk_clauses.append( Debugger shows that components is an empty array, so components[0] cannot be resolved:

-> params[f"p{len(params)}"] = components[0] (Pdb) params {'search': 'hello'} (Pdb) components []

So the bug is in this code: https://github.com/simonw/datasette/blob/adb5b70de5cec3c3dd37184defe606a082c232cf/datasette/views/table.py#L604-L617

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