Skip to content
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

[sqlite3] normalise SQL quoted literals in sqlite3 test suite #88274

Closed
erlend-aasland opened this issue May 11, 2021 · 3 comments
Closed

[sqlite3] normalise SQL quoted literals in sqlite3 test suite #88274

erlend-aasland opened this issue May 11, 2021 · 3 comments
Labels
3.11 only security fixes easy tests Tests in the Lib/test dir type-feature A feature request or enhancement

Comments

@erlend-aasland
Copy link
Contributor

BPO 44108
Nosy @berkerpeksag, @corona10, @miss-islington, @erlend-aasland
PRs
  • bpo-44108: normalise SQL quoted literals in sqlite3 test suite #26032
  • [3.10] bpo-44108: sqlite3 test suite now works with SQLITE_DQS=0 (GH-26032) #26125
  • [3.9] bpo-44108: sqlite3 test suite now works with SQLITE_DQS=0 (GH-26032) #26128
  • Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

    Show more details

    GitHub fields:

    assignee = None
    closed_at = <Date 2021-05-14.16:50:18.241>
    created_at = <Date 2021-05-11.10:16:38.016>
    labels = ['easy', 'type-feature', 'tests', '3.11']
    title = '[sqlite3] normalise SQL quoted literals in sqlite3 test suite'
    updated_at = <Date 2021-05-14.16:50:18.241>
    user = 'https://github.com/erlend-aasland'

    bugs.python.org fields:

    activity = <Date 2021-05-14.16:50:18.241>
    actor = 'corona10'
    assignee = 'none'
    closed = True
    closed_date = <Date 2021-05-14.16:50:18.241>
    closer = 'corona10'
    components = ['Tests']
    creation = <Date 2021-05-11.10:16:38.016>
    creator = 'erlendaasland'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 44108
    keywords = ['patch', 'easy']
    message_count = 3.0
    messages = ['393452', '393453', '393638']
    nosy_count = 4.0
    nosy_names = ['berker.peksag', 'corona10', 'miss-islington', 'erlendaasland']
    pr_nums = ['26032', '26125', '26128']
    priority = 'low'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'enhancement'
    url = 'https://bugs.python.org/issue44108'
    versions = ['Python 3.11']

    @erlend-aasland
    Copy link
    Contributor Author

    Most of the SQL statements in the sqlite3 test suite correctly uses single quote literals, except test_unicode_content in Lib/sqlite3/test/hooks.py, which uses double quote literals (not ANSI SQL compatible, IIRC). Adapting this test to also use single quote literals makes the sqlite3 test suite compatible with SQLite libraries compiled with SQLITE_DQS=0.

    See also:

    @erlend-aasland erlend-aasland added 3.11 only security fixes tests Tests in the Lib/test dir easy type-feature A feature request or enhancement labels May 11, 2021
    @erlend-aasland
    Copy link
    Contributor Author

    Digression: test_unicode_content should be named test_trace_unicode_content, in order to express the purpose of the test more clearly, should it fail.

    @corona10
    Copy link
    Member

    New changeset f28bac4 by Miss Islington (bot) in branch '3.10':
    bpo-44108: sqlite3 test suite now works with SQLITE_DQS=0 (GH-26032) (GH-26125)
    f28bac4

    @ezio-melotti ezio-melotti transferred this issue from another repository Apr 10, 2022
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Labels
    3.11 only security fixes easy tests Tests in the Lib/test dir type-feature A feature request or enhancement
    Projects
    None yet
    Development

    No branches or pull requests

    2 participants