Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Fix GZipMiddleware code block linking to TrustedHostMiddleware#1138

Merged
tiangolo merged 1 commit into
fastapi:masterfrom
arimbr:doc/fix-gzipmiddleware-code-block
Mar 27, 2020
Merged

Fix GZipMiddleware code block linking to TrustedHostMiddleware#1138
tiangolo merged 1 commit into
fastapi:masterfrom
arimbr:doc/fix-gzipmiddleware-code-block

Conversation

@arimbr

@arimbr arimbr commented Mar 19, 2020

Copy link
Copy Markdown
Contributor

@arimbr arimbr changed the title Fix GZipMiddleware code block linking to TrustedHostMiddleware [doc] Fix GZipMiddleware code block linking to TrustedHostMiddleware Mar 19, 2020
@codecov

codecov Bot commented Mar 19, 2020

Copy link
Copy Markdown

Codecov Report

Merging #1138 into master will not change coverage by %.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff            @@
##            master     #1138   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files          223       223           
  Lines         6642      6642           
=========================================
  Hits          6642      6642           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 670b643...f274f71. Read the comment docs.

@bilencekic

Copy link
Copy Markdown

is it possible still wrong ?
should be starlette.middleware.gzip rather than fastapi.middleware.gzip

@arimbr

arimbr commented Mar 26, 2020

Copy link
Copy Markdown
Contributor Author

@bilencekic based on the content in https://github.com/tiangolo/fastapi/blob/master/fastapi/middleware/gzip.py which imports from starlette.middleware.gzip it should work right?

@tiangolo Could you have a look at this. I've seen 4 other PR fixing the same issue ^^

@bilencekic

Copy link
Copy Markdown

@arimbr yes correct it is working i am using like that but documentation has changed to
from fastapi.middleware.trustedhost import TrustedHostMiddleware
i think GZIP is also embedded to this middleware now.

@arimbr

arimbr commented Mar 26, 2020

Copy link
Copy Markdown
Contributor Author

Right! Thanks, It is just syntactic sugar introduced in #1064 where this issue was also introduced.

@tiangolo tiangolo force-pushed the doc/fix-gzipmiddleware-code-block branch from f01fd73 to f274f71 Compare March 27, 2020 16:25
@tiangolo tiangolo merged commit 651ced6 into fastapi:master Mar 27, 2020
@tiangolo

Copy link
Copy Markdown
Member

Great, thank you @arimbr ! 🔍 🕵️‍♂️ 🍰 🚀

And thanks for the discussion here everyone 👏 🍰 ☕

@arimbr arimbr deleted the doc/fix-gzipmiddleware-code-block branch March 27, 2020 16:41
@tiangolo tiangolo changed the title [doc] Fix GZipMiddleware code block linking to TrustedHostMiddleware Fix GZipMiddleware code block linking to TrustedHostMiddleware Feb 24, 2023
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.

3 participants