fix(python): spread body parameters with Mapping protocol names use correct wire name#10248
Draft
fix(python): spread body parameters with Mapping protocol names use correct wire name#10248
Conversation
4 tasks
…prehensive tests + changelog Agent-Logs-Url: https://github.com/microsoft/typespec/sessions/f0bedfac-f8d6-42e4-8f6b-6f2b81a2c740 Co-authored-by: johanste <15110018+johanste@users.noreply.github.com>
… to avoid duplicated pattern Agent-Logs-Url: https://github.com/microsoft/typespec/sessions/f0bedfac-f8d6-42e4-8f6b-6f2b81a2c740 Co-authored-by: johanste <15110018+johanste@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Fix Python emitter using mangled name in requests
fix(python): spread body parameters with Mapping protocol names use correct wire name
Apr 2, 2026
commit: |
…naming is not broken by fix Agent-Logs-Url: https://github.com/microsoft/typespec/sessions/4b51c8d8-16ef-4fb8-803e-2b8f52912f2c Co-authored-by: johanste <15110018+johanste@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
preprocess/__init__.py: stop padding wire-name keys inpropertyToParameterName(only pad the Python parameter name values)test_name_converter.py:mangled_property_name()helper to avoid duplicated mangled-name constructionpropertyToParameterNamepropertyToParameterNameARE padded when matching reserved parameter wordsitemswire name bugspreadDictMethodsscenario tohttp-specs/specs/special-words/main.tsphttp-specs/specs/special-words/mockapi.tstest_as_attribute_dict_with_mapping_protocol_property_namestotest_model_base_serialization.py:azure.core.serialization.as_attribute_dict()still returns Python attribute names (items_property, etc.)model.as_dict()still returns wire names (items, etc.)