Skip to content

Align hidi params with kiota - #697

Merged
Darrel (darrelmiller) merged 14 commits into
vnextfrom
mk/align-hidi-params-with-kiota
Feb 1, 2022
Merged

Darrel (darrelmiller) merged 14 commits into
vnextfrom
mk/align-hidi-params-with-kiota

Conversation

@MaggieKimani1

@MaggieKimani1 Maggie Kimani (MaggieKimani1) commented Jan 24, 2022 •

Copy link
Copy Markdown
Contributor

As per Kiota's documentation, this PR seeks to align the common parameters between Hidi and Kiota in order to reduce any disparity in the tools.
As of now, these parameters are:

  • --openapi in Kiota vs --input in Hidi representing the path to the OpenAPI description/CSDL file used to generate the code files
  • --output in Kiota vs --output in Hidi representing the output directory path for the generated code files

This PR also seeks to add aliases to our existing parameters for simplicity
Fixes #662

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM

@baywet Vincent Biret (baywet) left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

hold before you merge please!
see this comment on other differences #662 (comment)

@MaggieKimani1

Copy link
Copy Markdown
Contributor Author

hold before you merge please! see this comment on other differences #662 (comment)

Vincent Biret (@baywet) Implemented!

@baywet Vincent Biret (baywet) left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

thanks for taking in the changes, a few comments.

transformCommand.Handler = CommandHandler.Create<string, FileInfo, OpenApiSpecVersion?, OpenApiFormat?, string, string, string, bool, bool>(

transformCommand.Handler = CommandHandler.Create<string, FileInfo, OpenApiSpecVersion?, OpenApiFormat?, LogLevel, string, string, string, bool, bool>(
OpenApiService.ProcessOpenApiDocument);

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Suggested change
OpenApiService.ProcessOpenApiDocument);
await OpenApiService.ProcessOpenApiDocument);

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

ah ignore my confused self, but please double check the system.commandline API recognizes it's now a tasks and blocks on it, I ran into that issue with kiota a while ago and this leads to very confusing behaviours

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Using the await keyword throws the error cannot await "method group"

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Yep sorry, as long as the command invoke blocks on the task we're good

@darrelmiller
Darrel (darrelmiller) merged commit ce24a81 into vnext Feb 1, 2022
@darrelmiller
Darrel (darrelmiller) deleted the mk/align-hidi-params-with-kiota branch February 1, 2022 21:37
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.

Align input parameter names of hidi with kiota commandline tool

4 participants