issue_comments: 1239759022
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/484#issuecomment-1239759022 | https://api.github.com/repos/simonw/sqlite-utils/issues/484 | 1239759022 | IC_kwDOCGYnMM5J5Tiu | 9599 | 2022-09-07T18:52:08Z | 2022-09-07T18:52:08Z | OWNER | It's not quite that simple. I tried applying this patch: ```diff diff --git a/sqlite_utils/cli.py b/sqlite_utils/cli.py index c51b101..33e4d90 100644 --- a/sqlite_utils/cli.py +++ b/sqlite_utils/cli.py @@ -30,6 +30,7 @@ from .utils import ( Format, TypeTracker, ) +from . import recipes CONTEXT_SETTINGS = dict(help_option_names=["-h", "--help"]) @@ -3029,7 +3030,7 @@ def _load_extensions(db, load_extension): def _register_functions(db, functions): # Register any Python functions as SQL functions: sqlite3.enable_callback_tracebacks(True) - globals = {} + globals = {"r": recipes, "recipes": recipes} try: exec(functions, globals) except SyntaxError as ex: ``` Then got this:
But the code that register SQL functions introspects that signature, so creates a SQL function that requires four arguments. |
{ "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
1363766973 |