Quick workaround for BLOB as TEXT problem (#2247) #2248
No reviewers
Labels
No Label
bug
build
dependencies
developers
documentation
duplicate
enhancement
formatting
invalid
legal
mobile
obsolete
packaging
performance
protocol
question
refactoring
regression
security
test
translation
usability
wontfix
No Milestone
No project
No Assignees
1 Participants
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: Bitmessage/PyBitmessage-2024-12-23#2248
Loading…
Reference in New Issue
Block a user
No description provided.
Delete Branch "kashikoibumi/strict-blob"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Quick workaround for BLOB as TEXT problem (#2247).
This patch fixes each SQL query to be both workable with BLOB-keys and TEXT-keys.
In each query, it tries first BLOB-key by using sqlite3.Binary() function.
When it failed, then it tries next TEXT-key by using CAST(? AS TEXT) syntax.
The modifications are all around the code base where SQL queries exist, but the logic is simple.
I have added a script to revert the BLOB-keys into TEXT-keys.
By applying this script, old version of PyBitmessage before this patch can be run again.