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

azblob house-keeping #16786

Closed
jhendrixMSFT opened this issue Jan 10, 2022 · 3 comments
Closed

azblob house-keeping #16786

jhendrixMSFT opened this issue Jan 10, 2022 · 3 comments
Assignees
Labels
Client This issue points to a problem in the data-plane of the library. Storage Storage Service (Queues, Blobs, Files)

Comments

@jhendrixMSFT
Copy link
Member

azblob is missing an autorest.md file for easy rebuilds. There is swagger/README.md however it's incomplete.

  • referenced branch is missing
  • swagger reference must be a commit hash, not HEAD

In addition, this is using an old version of the code generator.

@jhendrixMSFT jhendrixMSFT added the Storage Storage Service (Queues, Blobs, Files) label Jan 10, 2022
@RickWinter RickWinter added the Client This issue points to a problem in the data-plane of the library. label Jan 14, 2022
@mohsha-msft mohsha-msft self-assigned this Feb 24, 2022
@mohsha-msft mohsha-msft linked a pull request Mar 2, 2022 that will close this issue
5 tasks
@mohsha-msft
Copy link
Contributor

Hey @jhendrixMSFT ,

Nice idea!.

I've refactored our code generation file and I'd love to have your review on it. I've linked the PR with this issue.

The problem with new generator is that it converts enums like these into Enum0, Enum1, ... and so on.

Once suggested way to fix the enum issue is that

  1. Either they should be labeled as x-ms-enum directly in the swagger
  2. Or We can do it in a transform
    There are lots of such constants (~30) and writing transforms for every one of them will be problematic.
    Can we fix that?

@jhendrixMSFT
Copy link
Member Author

The change in behavior is by design and comes from the autorest modeler itself (i.e. not the Go code generator) so we can't really fix it. Ideally the swagger is fixed as the change affects all languages.

That said, there is a switch for M4 to enable the old, broken, behavior. In the autorest.md file, I think you'd add it like this.

modelerfour:
  seal-single-value-enum-by-default: true

Please note that per the docs, the switch is temporary and will be removed in future versions. It would be best to fix the swagger.

@mohsha-msft
Copy link
Contributor

Hey @jhendrixMSFT ,

azblob v0.4.0 is now publically available. I have made necessary changes here.

Thanks a lot for your feedbacks!

@github-actions github-actions bot locked and limited conversation to collaborators Apr 11, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Client This issue points to a problem in the data-plane of the library. Storage Storage Service (Queues, Blobs, Files)
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants