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

Unexpected error message when missing the workdir folder #94

Closed
1 task done
mpizenberg opened this issue Dec 21, 2022 · 2 comments
Closed
1 task done

Unexpected error message when missing the workdir folder #94

mpizenberg opened this issue Dec 21, 2022 · 2 comments
Assignees
Milestone

Comments

@mpizenberg
Copy link

What Git revision are you using?

I'm using the v2.2.1 release for linux

What operating system are you using, and which version?

  • Linux / archlinux

Describe what the problem is?

I got an unexpected error message when starting kupo:

❯ kupo \
        --node-socket ~/programs/cardano-node-1.35.4-linux/mainnet/db/node.socket \
        --node-config ~/programs/cardano-node-1.35.4-linux/configuration/cardano/mainnet-config.json \
        --since origin \
        --defer-db-indexes \
        --match "*/stake_vkh14hkp0sncfkt76spuqydtww4r900hfmsseezztzlh9sjkkjx6d7q" \
        --workdir ./db
kupo: SQLite3 returned ErrorCan'tOpen while attempting to perform open "file:./db/kupo.sqlite3?mode=rwc": unable to open database file

What should be the expected behavior?

I figured that I simply needed to create the db workdir I'm passing as argument. I would have expected kupo to check for the existence of the workdir and either tell me it does not exist or create it itself. I wasn't expected to reach a crash with the a default sqlite error message.

@mpizenberg mpizenberg changed the title Unexpected error message when missing the db folder Unexpected error message when missing the workdir folder Dec 21, 2022
@KtorZ
Copy link
Member

KtorZ commented Dec 21, 2022

Good point.

@KtorZ
Copy link
Member

KtorZ commented Dec 21, 2022

Alternatively: we could try to create the folder path recursively if it's not there.

@KtorZ KtorZ added this to the v2.2.0 milestone Dec 31, 2022
@KtorZ KtorZ self-assigned this Dec 31, 2022
@KtorZ KtorZ closed this as completed in 2f2dbb7 Dec 31, 2022
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

No branches or pull requests

2 participants