Visitar URL original
GitHub - gawen/contextvars: Contexted variables framework for Python · GitHub
Skip to content

About

Contexted variables framework for Python

Resources

Stars

10 stars

Watchers

1 watching

Forks

Latest commit

 

History

8 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 

Repository files navigation

contextvars

contextvars is a Python module to manage contexted variables.

Examples

from contextvars import *

c = ContextStack()

c.foo = "foo"
with c:
    assert c.foo == "foo"

    c.foo = "bar"

    assert c.foo == "bar"

assert c.foo == "foo"

About

Contexted variables framework for Python

Resources

Stars

10 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages