python-dependency-injector icon indicating copy to clipboard operation
python-dependency-injector copied to clipboard

ContextVar scope?

Open sonthonaxrk opened this issue 4 years ago • 9 comments

Hey there,

I see you have a threadlocal scope provider. However do you have a co-routine local scope provider that would use ContextVars rather than thread locals?

Would that be trivial to implement (happy to do it myself if you think it's a good idea).

sonthonaxrk avatar Mar 29 '21 13:03 sonthonaxrk

Hey @sonthonaxrk. Yep, that's a good idea. I see your PR, thanks for the input.

rmk135 avatar Mar 30 '21 20:03 rmk135

Thanks @rmk135. I'm running my PR in a little PoC project right now and seeing if there are any kinks that I need to work out. I'll probably find some time on the weekend to tidy it up, make it backwards compatible in a few days and put it in a releasable state :)

sonthonaxrk avatar Mar 31 '21 09:03 sonthonaxrk

Sounds good. I’m on vacation this and following week. Will join you after that.

Best, Roman

On Mar 31, 2021, at 3:01 AM, RK @.***> wrote:

 Thanks @rmk135. I'm running my PR in a little PoC project right now and seeing if there are any kinks that I need to work out. I'll probably find some time on the weekend to tidy it up and make it backwards compatible in a few days, and put it in a releasable state :)

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or unsubscribe.

rmk135 avatar Mar 31 '21 13:03 rmk135

@rmk135 hey Roman,

I've updated the PR. Things should be working now.

sonthonaxrk avatar Apr 07 '21 10:04 sonthonaxrk

Published on PyPI in version 4.32.0. Many thanks to @sonthonaxrk for giving a life to this provider.

rmk135 avatar Apr 19 '21 02:04 rmk135

Thanks man. I’ll update the documentation soon.

sonthonaxrk avatar Apr 19 '21 08:04 sonthonaxrk

It seems this can be closed. Am I missing something?

chbndrhnns avatar Oct 05 '21 05:10 chbndrhnns

@chbndrhnns This provider still misses the documentation. I'm working on a new release and will include it there. Thanks for the reminder

rmk135 avatar Oct 05 '21 12:10 rmk135

It seems to me that piece of documentation is still missing.

chbndrhnns avatar Mar 30 '22 08:03 chbndrhnns