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

Fix is form data #364

Closed
wants to merge 4 commits into from
Closed

Fix is form data #364

wants to merge 4 commits into from

Conversation

tadelesh
Copy link
Member

@tadelesh tadelesh commented Mar 5, 2024

rollback #215
when we use the spread way to define the body parameter, each time we call getHttpOperation, we will get a new model type for body.

example: https://github.com/bterlson/typespec-todo/blob/ca8a3aab5f3ef52e52cf2b48d2980f808165fada/main.tsp#L293

@azure-sdk
Copy link
Collaborator

All changed packages have been documented.

@azure-sdk
Copy link
Collaborator

@iscai-msft
Copy link
Contributor

@tadelesh this is an http issue right? Shouldn't we wait for the http library to fix it?

@timotheeguerin
Copy link
Member

@tadelesh this is an http issue right? Shouldn't we wait for the http library to fix it?

there is no issue in the http library, this is by design today we don't deduplicate types. You should not be calling it twice for the same operation anyway microsoft/typespec#2961

@tadelesh
Copy link
Member Author

tadelesh commented Mar 6, 2024

@tadelesh this is an http issue right? Shouldn't we wait for the http library to fix it?

as timothee said, it is by design, so i prefer to remove it temporally. i'm doing a refactor for getAllOperations and consolidate all our code to do only one call for getHttpOperation. after all emitter switch to it, many issues (alias, spread, etc.) could be resolved.

@iscai-msft
Copy link
Contributor

@tadelesh can this be closed bc I'm assuming your caching getHttpOperation fixes this issue as well?

#395

@tadelesh tadelesh closed this Mar 12, 2024
@tadelesh tadelesh deleted the fix_is_form_data branch July 17, 2024 06:11
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.

4 participants