{"id": 274161964, "node_id": "MDU6SXNzdWUyNzQxNjE5NjQ=", "number": 101, "title": "TemplateAssertionError: no filter named 'tojson'", "user": {"value": 450244, "label": "eaubin"}, "state": "closed", "locked": 0, "assignee": null, "milestone": null, "comments": 1, "created_at": "2017-11-15T13:47:32Z", "updated_at": "2017-11-15T13:48:55Z", "closed_at": "2017-11-15T13:48:55Z", "author_association": "NONE", "pull_request": null, "body": "I get an exception clicking on the table link: \r\n\r\n```\r\n2017-11-15 08:40:10 - (sanic)[ERROR]: Traceback (most recent call last):\r\n File \"/Users/e/anaconda3-4.2.0/lib/python3.5/site-packages/sanic/app.py\", line 503, in handle_request\r\n response = await response\r\n File \"/Users/e/anaconda3-4.2.0/lib/python3.5/site-packages/datasette/app.py\", line 155, in get\r\n return await self.view_get(request, name, hash, **kwargs)\r\n File \"/Users/e/anaconda3-4.2.0/lib/python3.5/site-packages/datasette/app.py\", line 219, in view_get\r\n **context,\r\n File \"/Users/e/anaconda3-4.2.0/lib/python3.5/site-packages/sanic_jinja2/__init__.py\", line 84, in render\r\n return html(self.render_string(template, request, **context))\r\n File \"/Users/e/anaconda3-4.2.0/lib/python3.5/site-packages/sanic_jinja2/__init__.py\", line 81, in render_string\r\n return self.env.get_template(template).render(**context)\r\n File \"/Users/e/anaconda3-4.2.0/lib/python3.5/site-packages/jinja2/environment.py\", line 812, in get_template\r\n return self._load_template(name, self.make_globals(globals))\r\n File \"/Users/e/anaconda3-4.2.0/lib/python3.5/site-packages/jinja2/environment.py\", line 786, in _load_template\r\n template = self.loader.load(self, name, globals)\r\n File \"/Users/e/anaconda3-4.2.0/lib/python3.5/site-packages/jinja2/loaders.py\", line 125, in load\r\n code = environment.compile(source, name, filename)\r\n File \"/Users/e/anaconda3-4.2.0/lib/python3.5/site-packages/jinja2/environment.py\", line 565, in compile\r\n self.handle_exception(exc_info, source_hint=source_hint)\r\n File \"/Users/e/anaconda3-4.2.0/lib/python3.5/site-packages/jinja2/environment.py\", line 754, in handle_exception\r\n reraise(exc_type, exc_value, tb)\r\n File \"/Users/e/anaconda3-4.2.0/lib/python3.5/site-packages/jinja2/_compat.py\", line 37, in reraise\r\n raise value.with_traceback(tb)\r\n File \"/Users/e/anaconda3-4.2.0/lib/python3.5/site-packages/datasette/templates/table.html\", line 29, in template\r\n
params = {{ query.params|tojson(4) }}
\r\n File \"/Users/e/anaconda3-4.2.0/lib/python3.5/site-packages/jinja2/environment.py\", line 515, in _generate\r\n return generate(source, self, name, filename, defer_init=defer_init)\r\n File \"/Users/e/anaconda3-4.2.0/lib/python3.5/site-packages/jinja2/compiler.py\", line 62, in generate\r\n generator.visit(node)\r\n File \"/Users/e/anaconda3-4.2.0/lib/python3.5/site-packages/jinja2/visitor.py\", line 38, in visit\r\n return f(node, *args, **kwargs)\r\n File \"/Users/e/anaconda3-4.2.0/lib/python3.5/site-packages/jinja2/compiler.py\", line 849, in visit_Template\r\n self.blockvisit(block.body, block_frame)\r\n File \"/Users/e/anaconda3-4.2.0/lib/python3.5/site-packages/jinja2/compiler.py\", line 492, in blockvisit\r\n self.visit(node, frame)\r\n File \"/Users/e/anaconda3-4.2.0/lib/python3.5/site-packages/jinja2/visitor.py\", line 38, in visit\r\n return f(node, *args, **kwargs)\r\n File \"/Users/e/anaconda3-4.2.0/lib/python3.5/site-packages/jinja2/compiler.py\", line 1172, in visit_If\r\n self.blockvisit(node.body, if_frame)\r\n File \"/Users/e/anaconda3-4.2.0/lib/python3.5/site-packages/jinja2/compiler.py\", line 492, in blockvisit\r\n self.visit(node, frame)\r\n File \"/Users/e/anaconda3-4.2.0/lib/python3.5/site-packages/jinja2/visitor.py\", line 38, in visit\r\n return f(node, *args, **kwargs)\r\n File \"/Users/e/anaconda3-4.2.0/lib/python3.5/site-packages/jinja2/compiler.py\", line 1353, in visit_Output\r\n self.visit(argument, frame)\r\n File \"/Users/e/anaconda3-4.2.0/lib/python3.5/site-packages/jinja2/visitor.py\", line 38, in visit\r\n return f(node, *args, **kwargs)\r\n File \"/Users/e/anaconda3-4.2.0/lib/python3.5/site-packages/jinja2/compiler.py\", line 1565, in visit_Filter\r\n self.fail('no filter named %r' % node.name, node.lineno)\r\n File \"/Users/e/anaconda3-4.2.0/lib/python3.5/site-packages/jinja2/compiler.py\", line 427, in fail\r\n raise TemplateAssertionError(msg, lineno, self.name, self.filename)\r\njinja2.exceptions.TemplateAssertionError: no filter named 'tojson'\r\n```", "repo": {"value": 107914493, "label": "datasette"}, "type": "issue", "active_lock_reason": null, "performed_via_github_app": null, "reactions": "{\"url\": \"https://api.github.com/repos/simonw/datasette/issues/101/reactions\", \"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "draft": null, "state_reason": "completed"} {"id": 273660425, "node_id": "MDU6SXNzdWUyNzM2NjA0MjU=", "number": 84, "title": "datasette package --metadata does not work with a relative path", "user": {"value": 9599, "label": "simonw"}, "state": "closed", "locked": 0, "assignee": null, "milestone": null, "comments": 0, "created_at": "2017-11-14T04:00:50Z", "updated_at": "2017-11-15T05:18:35Z", "closed_at": "2017-11-15T05:18:35Z", "author_association": "OWNER", "pull_request": null, "body": " $ datasette package ~/parlgov-db/parlgov.db --metadata=~/parlgov-db/parlgov.json\r\n Usage: datasette package [OPTIONS] FILES...\r\n\r\n Error: Invalid value for \"-m\" / \"--metadata\": Could not open file: ~/parlgov-db/parlgov.json: No such file or directory\r\n \r\n simonw-07542:~ simonw$ cd ~/parlgov-db/\r\n simonw-07542:parlgov-db simonw$ datasette package ~/parlgov-db/parlgov.db --metadata=parlgov.json\r\n Sending build context to Docker daemon 4.46MB\r\n Step 1/7 : FROM python:3\r\n", "repo": {"value": 107914493, "label": "datasette"}, "type": "issue", "active_lock_reason": null, "performed_via_github_app": null, "reactions": "{\"url\": \"https://api.github.com/repos/simonw/datasette/issues/84/reactions\", \"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "draft": null, "state_reason": "completed"} {"id": 267857622, "node_id": "MDU6SXNzdWUyNjc4NTc2MjI=", "number": 25, "title": "Endpoint that returns SQL ready to be piped into DB", "user": {"value": 9599, "label": "simonw"}, "state": "closed", "locked": 0, "assignee": null, "milestone": null, "comments": 2, "created_at": "2017-10-24T00:19:26Z", "updated_at": "2017-11-15T05:11:12Z", "closed_at": "2017-11-15T05:11:11Z", "author_association": "OWNER", "pull_request": null, "body": "It would be cool if I could figure out a way to generate both the create table statements and the inserts for an individual table or the entire database and then stream them down to the client.", "repo": {"value": 107914493, "label": "datasette"}, "type": "issue", "active_lock_reason": null, "performed_via_github_app": null, "reactions": "{\"url\": \"https://api.github.com/repos/simonw/datasette/issues/25/reactions\", \"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "draft": null, "state_reason": "completed"} {"id": 274023417, "node_id": "MDU6SXNzdWUyNzQwMjM0MTc=", "number": 98, "title": "Default to 127.0.0.1 not 0.0.0.0", "user": {"value": 9599, "label": "simonw"}, "state": "closed", "locked": 0, "assignee": null, "milestone": null, "comments": 0, "created_at": "2017-11-15T03:31:55Z", "updated_at": "2017-11-15T05:08:54Z", "closed_at": "2017-11-15T05:08:54Z", "author_association": "OWNER", "pull_request": null, "body": "https://twitter.com/yschimke/status/930606210855854080", "repo": {"value": 107914493, "label": "datasette"}, "type": "issue", "active_lock_reason": null, "performed_via_github_app": null, "reactions": "{\"url\": \"https://api.github.com/repos/simonw/datasette/issues/98/reactions\", \"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "draft": null, "state_reason": "completed"} {"id": 273895344, "node_id": "MDU6SXNzdWUyNzM4OTUzNDQ=", "number": 92, "title": "Add --license --license_url --source --source_url --title arguments to datasette publish", "user": {"value": 9599, "label": "simonw"}, "state": "closed", "locked": 0, "assignee": null, "milestone": null, "comments": 0, "created_at": "2017-11-14T18:27:07Z", "updated_at": "2017-11-15T05:04:41Z", "closed_at": "2017-11-15T05:04:41Z", "author_association": "OWNER", "pull_request": null, "body": "I keep on using the `echo '{\"source\": \"...\"}' | datasette publish now --metadata=-` pattern, which suggests it makes sense for us to support these as optional arguments.\r\n\r\nhttps://gist.github.com/simonw/9f8bf23b37a42d7628c4dcc4bba10253", "repo": {"value": 107914493, "label": "datasette"}, "type": "issue", "active_lock_reason": null, "performed_via_github_app": null, "reactions": "{\"url\": \"https://api.github.com/repos/simonw/datasette/issues/92/reactions\", \"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "draft": null, "state_reason": "completed"} {"id": 273961179, "node_id": "MDExOlB1bGxSZXF1ZXN0MTUyNjMxNTcw", "number": 94, "title": "Initial add simple prod ready Dockerfile refs #57", "user": {"value": 247192, "label": "macropin"}, "state": "closed", "locked": 0, "assignee": null, "milestone": null, "comments": 1, "created_at": "2017-11-14T22:09:09Z", "updated_at": "2017-11-15T03:08:04Z", "closed_at": "2017-11-15T03:08:04Z", "author_association": "CONTRIBUTOR", "pull_request": "simonw/datasette/pulls/94", "body": "Multi-stage build based off official python:3.6-slim\r\n\r\nExample usage:\r\n```\r\ndocker run --rm -t -i -p 9000:8001 -v $(pwd)/db:/db datasette datasette serve /db/chinook.db\r\n```", "repo": {"value": 107914493, "label": "datasette"}, "type": "pull", "active_lock_reason": null, "performed_via_github_app": null, "reactions": "{\"url\": \"https://api.github.com/repos/simonw/datasette/issues/94/reactions\", \"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "draft": 0, "state_reason": null} {"id": 273998513, "node_id": "MDU6SXNzdWUyNzM5OTg1MTM=", "number": 95, "title": "Allow shorter time limits to be set using a ?_sql_time_limit_ms =20 query string limit", "user": {"value": 9599, "label": "simonw"}, "state": "closed", "locked": 0, "assignee": null, "milestone": null, "comments": 1, "created_at": "2017-11-15T01:02:16Z", "updated_at": "2017-11-15T02:56:13Z", "closed_at": "2017-11-15T02:56:13Z", "author_association": "OWNER", "pull_request": null, "body": "This cannot be greater than the configured time limit.", "repo": {"value": 107914493, "label": "datasette"}, "type": "issue", "active_lock_reason": null, "performed_via_github_app": null, "reactions": "{\"url\": \"https://api.github.com/repos/simonw/datasette/issues/95/reactions\", \"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "draft": null, "state_reason": "completed"} {"id": 267542338, "node_id": "MDU6SXNzdWUyNjc1NDIzMzg=", "number": 13, "title": "Add a syntax highlighting SQL editor", "user": {"value": 9599, "label": "simonw"}, "state": "closed", "locked": 0, "assignee": null, "milestone": null, "comments": 1, "created_at": "2017-10-23T05:03:33Z", "updated_at": "2017-11-15T02:04:51Z", "closed_at": "2017-11-15T02:04:51Z", "author_association": "OWNER", "pull_request": null, "body": "https://ace.c9.io/#nav=embedding looks like a good option", "repo": {"value": 107914493, "label": "datasette"}, "type": "issue", "active_lock_reason": null, "performed_via_github_app": null, "reactions": "{\"url\": \"https://api.github.com/repos/simonw/datasette/issues/13/reactions\", \"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "draft": null, "state_reason": "completed"} {"id": 273816720, "node_id": "MDExOlB1bGxSZXF1ZXN0MTUyNTIyNzYy", "number": 89, "title": "SQL syntax highlighting with CodeMirror", "user": {"value": 15543, "label": "tomdyson"}, "state": "closed", "locked": 0, "assignee": null, "milestone": null, "comments": 1, "created_at": "2017-11-14T14:43:33Z", "updated_at": "2017-11-15T02:03:01Z", "closed_at": "2017-11-15T02:03:01Z", "author_association": "CONTRIBUTOR", "pull_request": "simonw/datasette/pulls/89", "body": "Addresses #13 \r\n\r\nFuture enhancements could include autocompletion of table and column names, e.g. with\r\n\r\n```javascript\r\nextraKeys: {\"Ctrl-Space\": \"autocomplete\"},\r\nhintOptions: {tables: {\r\n users: [\"name\", \"score\", \"birthDate\"],\r\n countries: [\"name\", \"population\", \"size\"]\r\n }}\r\n```\r\n\r\n(see https://codemirror.net/doc/manual.html#addon_sql-hint and source at http://codemirror.net/mode/sql/)", "repo": {"value": 107914493, "label": "datasette"}, "type": "pull", "active_lock_reason": null, "performed_via_github_app": null, "reactions": "{\"url\": \"https://api.github.com/repos/simonw/datasette/issues/89/reactions\", \"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "draft": 0, "state_reason": null}