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

Set a minimal sqlite version #372

Merged
merged 1 commit into from
Mar 17, 2023
Merged

Conversation

ppisar
Copy link
Contributor

@ppisar ppisar commented Mar 17, 2023

Installing a package on a system with sqlite-3.34.1 failed with:

Running transaction
SQL statement compilation failed: "
INSERT INTO
    "pkg_name" (
	"name"
    )
VALUES
    (?)
ON CONFLICT DO NOTHING
RETURNING "id"
": (1) - SQL logic error

The cause is that libdnf5 uses "RETURNING" clause in sqlite queries. A support for this clause was added in sqlite-3.35.0. (Figured out experimentally and by reading sqlite sources. Sqlite news file only mentions "adds a number of new language features".)

This patch constrains the minial sqlite version to 3.35.0.

Installing a package on a system with sqlite-3.34.1 failed with:

    Running transaction
    SQL statement compilation failed: "
	INSERT INTO
	    "pkg_name" (
		"name"
	    )
	VALUES
	    (?)
	ON CONFLICT DO NOTHING
	RETURNING "id"
    ": (1) - SQL logic error

The cause is that libdnf5 uses "RETURNING" clause in sqlite queries.
A support for this clause was added in sqlite-3.35.0. (Figured out
experimentally and by reading sqlite sources. Sqlite news file only
mentions "adds a number of new language features".)

This patch constrains the minial sqlite version to 3.35.0.
@inknos inknos self-assigned this Mar 17, 2023
@inknos
Copy link
Collaborator

inknos commented Mar 17, 2023

LGTM

@inknos inknos merged commit bcc12c6 into rpm-software-management:main Mar 17, 2023
@ppisar
Copy link
Contributor Author

ppisar commented Mar 17, 2023

I'm sorry, there was a typo in an added Requires: line. It was caught by CI https://github.com/rpm-software-management/dnf5/actions/runs/4448244007/jobs/7811691829. I will supply a fix.

@ppisar
Copy link
Contributor Author

ppisar commented Mar 17, 2023

Fix supplied in #374.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants