-
-
Notifications
You must be signed in to change notification settings - Fork 423
Added specific CLI return error-code if inventory can not be created #2402
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
Conversation
Thanks for the PR!
Avoid startup fatal error if the data directory can not be created.
Why? Is the CLI (daemon) fully functional if the directories.data
is missing?
Why no fail with a specific exit code?
1b45064
to
38b5fd8
Compare
38b5fd8
to
2d40049
Compare
Why? Is the CLI (daemon) fully functional if the
directories.data
is missing?
Uhm... actually you can recover from this situation by changing the data_dir
using Settings API, but you're right, it's a very convoluted use case, in this case is better to exit with another exit code.
I've changed the PR accordingly.
daemon
if data dir can't be created (削除ここまで)
Codecov ReportAttention:
Additional details and impacted files@@ Coverage Diff @@ ## master #2402 +/- ## ========================================== - Coverage 64.60% 64.58% -0.02% ========================================== Files 207 207 Lines 19634 19634 ========================================== - Hits 12684 12681 -3 - Misses 5861 5863 +2 - Partials 1089 1090 +1
Flags with carried forward coverage won't be shown. Click here to find out more.
☔ View full report in Codecov by Sentry. |
Uh oh!
There was an error while loading. Please reload this page.
Please check if the PR fulfills these requirements
See how to contribute
before creating one)
our contributing guidelines
UPGRADING.md
has been updated with a migration guide (for breaking changes)configuration.schema.json
updated if new parameters are added.What kind of change does this PR introduce?
Add a specific exit code for the CLI to signal failure on initializing the "inventory" storage.
What is the current behavior?
In case of failure to initialize inventory, the CLI returned a generic error code
7
, i.e.ErrBadArgument
.What is the new behavior?
In case of failure to initialize inventory, the CLI return an error code
10
, i.e.ErrInitializingInventory
.Does this PR introduce a breaking change, and is titled accordingly?
Other information
Fix #2352