snok / asgi-correlation-id

Request ID propagation for ASGI apps
MIT License
369 stars 29 forks source link

bug in the docs #75

Closed vamos777q closed 10 months ago

vamos777q commented 10 months ago

Hey,

It looks like there was a bug which was recently introduced if you follow the setup as described in the documentation.

This import does not exist any more: from asgi_correlation_id import correlation_id_filter so this line: cid_filter = correlation_id_filter(uuid_length=32) should change to this: cid_filter = CorrelationIdFilter(uuid_length=32)

JonasKs commented 10 months ago

Good catch 😊 Would you like to submit a PR to fix it? 😊 If you have questions on how to do so, let us know and we’ll provide detailed steps.

vamos777q commented 10 months ago

thanks. I've never done that before, but I am willing to try if you send me instructions.

sondrelg commented 10 months ago

If you edit the README in the Github UI directly, you can commit to a new branch and open a PR 😊 Think that's the simplest way

vamos777q commented 10 months ago

Sorry, it looks like the README is ok, and only the blogpost which it points too (on medium) should be fixed. https://medium.com/@sondrelg_12432/setting-up-request-id-logging-for-your-fastapi-application-4dc190aac0ea

I put not there when I came across it initially, but since it's on Medium only you can fix it. My first PR will need to wait :)

Thanks