home / github / issue_comments

Menu
  • Search all tables
  • GraphQL API

issue_comments: 1229119999

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/471#issuecomment-1229119999 https://api.github.com/repos/simonw/sqlite-utils/issues/471 1229119999 IC_kwDOCGYnMM5JQuH_ 9599 2022-08-27T04:24:58Z 2022-08-27T04:24:58Z OWNER

I've encountered this problem before: https://sqlite-utils.datasette.io/en/stable/cli.html#cli-convert-complex

``` $ sqlite-utils convert content.db articles score ' import random random.seed(10)

def convert(value): global random return random.random() ' `` Note theglobal randomline here. Due to the way the tool compiles Python code, this is necessary to ensure therandommodule is available within theconvert()function. If you were to omit this you would see aNameError: name 'random' is not defined` error.

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