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

aiosqlite is pinned to <=0.17.0 #290

Open
1 task done
NTFSvolume opened this issue Dec 13, 2024 · 1 comment
Open
1 task done

aiosqlite is pinned to <=0.17.0 #290

NTFSvolume opened this issue Dec 13, 2024 · 1 comment
Labels
Stale Issue or pull request has been inactive for 20 days

Comments

@NTFSvolume
Copy link

Describe the Bug

aiosqlite 0.17.0 is over 3 years old. This is causing dependency conflicts with other packages on a project I'm working on.

Checking the source code, aiosqlite is only used by SQLiteTokenManager inside https://github.com/praw-dev/asyncpraw/blob/master/asyncpraw/util/token_manager.py.

Only standard methods are used. The dependency can be updated without any code changes. The only major difference is that aiosqlite dropped support for python 3.7, but asyncpraw does not support it either

@asynccontextmanager
async def connection(self):
"""Asynchronously setup and provide the sqlite3 connection."""
if self._connection is None:
import aiosqlite
self._connection = await aiosqlite.connect(self._database)
if not self._setup_ran:
await self._connection.execute(
"CREATE TABLE IF NOT EXISTS tokens (id, refresh_token, updated_at)"
)
await self._connection.execute(
"CREATE UNIQUE INDEX IF NOT EXISTS ux_tokens_id on tokens(id)"
)
await self._connection.commit()
self._setup_ran = True
yield self._connection

Desired Result

Remove the pin version specifier and replace it with >=0.17.0,<1.0.0 to allow any new minor updates of aiosqlite

Furthermore, the token_manager module has a deprecation message at the top, which means the entire aiosqlite dependency may be removed in the future.

Code to reproduce the bug

N/A

My code does not include sensitive credentials

  • Yes, I have removed sensitive credentials from my code.

Relevant Logs

N/A

This code has previously worked as intended

Yes

Operating System/Environment

popOS 22.04

Python Version

3.11

Async PRAW Version

7.8.0

Links, references, and/or additional comments?

https://aiosqlite.omnilib.dev/en/stable/changelog.html

Copy link
Contributor

This issue is stale because it has been open for 30 days with no activity.

Remove the Stale label or comment or this will be closed in 30 days.

@github-actions github-actions bot added the Stale Issue or pull request has been inactive for 20 days label Jan 12, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Stale Issue or pull request has been inactive for 20 days
Projects
None yet
Development

No branches or pull requests

1 participant