simonw / datasette
Showing 1 of 2 files from the diff.
Other files ignored by Codecov

@@ -1080,11 +1080,12 @@
Loading
1080 1080
1081 1081
_re_named_parameter = re.compile(":([a-zA-Z0-9_]+)")
1082 1082
1083 +
1083 1084
async def derive_named_parameters(db, sql):
1084 -
    explain = 'explain {}'.format(sql.strip().rstrip(";"))
1085 +
    explain = "explain {}".format(sql.strip().rstrip(";"))
1085 1086
    possible_params = _re_named_parameter.findall(sql)
1086 1087
    try:
1087 1088
        results = await db.execute(explain, {p: None for p in possible_params})
1088 1089
        return [row["p4"].lstrip(":") for row in results if row["opcode"] == "Variable"]
1089 1090
    except sqlite3.DatabaseError:
1090 -
        return []
1091 +
        return possible_params
Files Coverage
datasette 91.71%
Project Totals (34 files) 91.71%
1
coverage:
2
  status:
3
    project:
4
      default:
5
        informational: true
6
    patch:
7
      default:
8
        informational: true
Sunburst
The inner-most circle is the entire project, moving away from the center are folders then, finally, a single file. The size and color of each slice is representing the number of statements and the coverage, respectively.
Icicle
The top section represents the entire project. Proceeding with folders and finally individual files. The size and color of each slice is representing the number of statements and the coverage, respectively.
Grid
Each block represents a single file in the project. The size and color of each block is represented by the number of statements and the coverage, respectively.
Loading