-
-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Ability to round-trip binary data #4
Comments
The {
"name": "line_bits",
"columns": [
"file_id",
"context_id",
"numbits"
],
"schema": "CREATE TABLE line_bits (\n -- If recording lines, a row per context per file executed.\n -- All of the line numbers for that file/context are in one numbits.\n file_id integer, -- foreign key to `file`.\n context_id integer, -- foreign key to `context`.\n numbits blob, -- see the numbits functions in coverage.numbits\n foreign key (file_id) references file (id),\n foreign key (context_id) references context (id),\n unique (file_id, context_id)\n)"
} I could use this to say "the third column is binary, so treat it as such" somehow. |
Maybe "columns": [
["file_id", "integer"],
["context_id", "integer"],
["numbits", "blob"]
] |
Here's how INSERT INTO line_bits VALUES(1,1,X'0e');
INSERT INTO line_bits VALUES(2,1,X'5a');
INSERT INTO line_bits VALUES(3,1,X'36218410420821841042');
INSERT INTO line_bits VALUES(4,1,X'fefffd7be0021000577d6fdb7bef7d6fefbdf792e80000ca09e0fbdf0779dbbef39773d7d8eb06d959164117e602022040081000bc48c12440f77d3f010420000000000425000400000000003c174800001220e9c80800000000000040000000d44db5180077d7ddddb66dbaa9e0a7f35a82fb4e0000000000000002000000000024600004'); |
I can accompany this with a parametrized test that covers all of the other SQLite types as well. |
Hello @simonw -- I love this project, thanks for making it happen. Is this issue essentially tracking the attempt to properly make a My main usage goal: enable more-efficient Additional questions:
Additional reference (for my sake): fyi. The following is my environment's data after installing
|
Checking in - any update(s) on this topic/issue/discussion? ( @simonw ) |
e.g. for the binary
numbits
column in the.coverage
SQLite database generated bycoveragepy
.Those currently end up represented like this:
Once I implement the load command (#3) these will be a problem, because they won't round-trip correctly.
I need some kind of special-case syntax for storing binary values such that they can be round-tripped properly.
The text was updated successfully, but these errors were encountered: