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

FEATURE | SQLite3x.path, relative vs absolute #45

Open
v1a0 opened this issue Sep 18, 2021 · 2 comments
Open

FEATURE | SQLite3x.path, relative vs absolute #45

v1a0 opened this issue Sep 18, 2021 · 2 comments
Labels
feature New feature request

Comments

@v1a0
Copy link
Owner

v1a0 commented Sep 18, 2021

SQLite3x.path returns relative path, but I guess return absolute path it's more reasonable for this property.

Now

db.path # 'my_db.db'

Will be

db.path # '/usr/local/.../my_project/my_db.db'
@v1a0 v1a0 added the feature New feature request label Sep 18, 2021
@Phizilion
Copy link
Contributor

But does it make sense to return the path at all if this argument is not required when creating an object?

@v1a0
Copy link
Owner Author

v1a0 commented Sep 18, 2021

But does it make sense to return the path at all if this argument is not required when creating an object?

Yep, sure it is. It's one of the most important properties of SQLite database. There might be many cases when you need to know with witch database you interacting (especially in some universal scripts) and there is the way to check it.

And it is required, this is the first argument of class at all

db = SQLite3x(
    path='my_database.db',
)

wiki SQLite3x
wiki SQLite3x.path

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

No branches or pull requests

2 participants