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

Allow python middleware to set the URI of a request #3002

Merged
merged 2 commits into from
Sep 28, 2023

Conversation

drganjoo
Copy link
Contributor

Motivation and Context

Python middleware were unable to change the URI which makes it impossible to change the route of an incoming request in Python.

Description

URI has a #[setter] that Python side can use to change it.

Testing

  • Test has been added that ensures URI can be changed from python.
  • If the URI is modified by a middleware in a local smithy-rs Python server, a different route will be invoked.

Checklist

  • I've updated the changelog.next.toml

@drganjoo drganjoo force-pushed the python_allow_set_url branch 2 times, most recently from 2cd2766 to 7893b53 Compare September 26, 2023 18:53
@github-actions
Copy link

A new generated diff is ready to view.

  • No codegen difference in the AWS SDK
  • No codegen difference in the Client Test
  • No codegen difference in the Server Test
  • No codegen difference in the Server Test Python
  • No codegen difference in the Server Test Typescript

A new doc preview is ready to view.

@drganjoo drganjoo linked an issue Sep 27, 2023 that may be closed by this pull request
@github-actions
Copy link

A new generated diff is ready to view.

  • No codegen difference in the AWS SDK
  • No codegen difference in the Client Test
  • No codegen difference in the Server Test
  • No codegen difference in the Server Test Python
  • No codegen difference in the Server Test Typescript

A new doc preview is ready to view.

@github-actions
Copy link

A new generated diff is ready to view.

  • No codegen difference in the AWS SDK
  • No codegen difference in the Client Test
  • No codegen difference in the Server Test
  • No codegen difference in the Server Test Python
  • No codegen difference in the Server Test Typescript

A new doc preview is ready to view.

@drganjoo drganjoo added this pull request to the merge queue Sep 28, 2023
Merged via the queue into main with commit 3229089 Sep 28, 2023
40 of 41 checks passed
@drganjoo drganjoo deleted the python_allow_set_url branch September 28, 2023 15:28
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.

Enable URI Modification in Python Server Middleware
4 participants