Skip to content

Conversation

@jim-bcom
Copy link

When using a compilation database, a message stating that the "File was missing" was printed, leading to think something was wrong whereas it's expected behavior.

Also:

  • perform option validation to keep --file and --database_dir mutually exclusive (if both options were set, only file was taken)
  • handle parsing error (used to be ignored for --database_dir path)

…g compilation database

When using a compilation database, a message stating that the "File was missing" was printed,
leading to think something was wrong whereas it's expected behavior.

Also:
- perform option validation to keep --file and --database_dir mutually exclusive
- handle parsing error (used to be ignored for --database_dir path)
Copy link
Collaborator

@AdrienSchadle AdrienSchadle left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok for me

@jim-bcom jim-bcom marked this pull request as draft February 26, 2024 08:44
Options --file and --database_dir are actually not mutually exclusive.
When parsing a file, the compilation database is used to resolve symbols
when passed to initOptions().

Change "File is missing" by a message that sounds less as an error.
@jim-bcom jim-bcom force-pushed the fix/grpcgen-cli-file-vs-db branch from f7995cc to bc064b5 Compare February 26, 2024 13:21
@jim-bcom jim-bcom marked this pull request as ready for review February 26, 2024 13:21
@jim-bcom
Copy link
Author

Reverted the check for mutual exclusion of --file and --database_dir. Turns out, they're not mutually exclusive.
There may be some refinements needed on how to manage --database_dir, --database_file and --file, but for now, this PR only aims at changing the message logged when --file is not set.

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

Successfully merging this pull request may close these issues.

2 participants