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

ERROR histdb_rs > can not open log file #24

Open
tmpm697 opened this issue Sep 14, 2021 · 4 comments · May be fixed by #27
Open

ERROR histdb_rs > can not open log file #24

tmpm697 opened this issue Sep 14, 2021 · 4 comments · May be fixed by #27
Labels
bug Something isn't working errorhandling
Milestone

Comments

@tmpm697
Copy link
Contributor

tmpm697 commented Sep 14, 2021

steps:

1. create an vm image with user's histdb-rs.service enabled, and touched ~/.local/share/histdb-rs/test.csv
2. spawn an vm from above image, ssh to the user and then trigger histdb-rs command immediately
3. observe the error

so if there's no entry in csv file, histdb-rs will echo this error, I believe it should not :)

@AlexanderThaller
Copy link
Owner

Can you post the error?

@AlexanderThaller AlexanderThaller added bug Something isn't working errorhandling labels Oct 5, 2021
@AlexanderThaller AlexanderThaller added this to the 2.1.0 milestone Oct 5, 2021
@AlexanderThaller AlexanderThaller linked a pull request Oct 5, 2021 that will close this issue
@AlexanderThaller
Copy link
Owner

I tried to reproduce the error in #27 but that doesn't throw any error. Can you post the exact error message you get? @tmpm697

@tmpm697
Copy link
Contributor Author

tmpm697 commented Oct 7, 2021

the title is the error afair.
to have more clear, I built qcow2 image using packer and histdb-rs was put into ~/.config/systemd/user/histdb-rs.service and then issue command cd /home/USER/.config/systemd/user/default.target.wants; ln -s /home/USER/.config/systemd/user/histdb-rs.service histdb-rs.service

basically it will enable histdb-rs under user, the hostname is test so i touched ~/.local/share/histdb-rs/test.csv in packer image.

and I spin up image to an vm using libvirt / qemu tools, the first time I ssh to vm, and then try to use histdb-rs, the error echoed.

sorry but i don't remember exactly this case anymore as i'll need more time to re-test.

@AlexanderThaller
Copy link
Owner

AlexanderThaller commented Oct 18, 2021

You shoudn't have to touch the file hstdb will create the index folder/file automatically. Touching the file would also mean that the file doesn't contain any csv header as add_entry will check if the file exists and add a header if the file is new.

There should have been more information in the error message like "permission denied" or something.

@AlexanderThaller AlexanderThaller modified the milestones: 2.1.0, 3.0.0, 2.2.0 Jul 4, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working errorhandling
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants