[Python-Dev] PEP 550 v3 naming

Eric Snow ericsnowcurrently at gmail.com
Thu Aug 24 18:47:20 EDT 2017


On Thu, Aug 24, 2017 at 5:37 AM, Nick Coghlan <ncoghlan at gmail.com> wrote:
> Migrating a (variant of a) naming subthread from python-ideas over to
> here, does the following sound plausible to anyone else?:
>
>     ContextLocal - read/write access API (via get()/set() methods)
>     ContextLocalNamespace - active mapping that CL.get()/set() manipulates
>     ExecutionContext - current stack of context local namespaces

Overall it makes sense.  The following derivative might be more clear:

    ContextLocal
    ContextLocals
    ChainedContextLocals (or some variation explicitly calling out the chaining)

Alternatively, similar to other suggestions:

    ContextVar
    ContextVars
    ChainedContextVars

I also think "state" helps disambiguate "context":

    ContextVar
    ContextState
    ChainedContextState

or:

    ContextVar
    ContextVars
    ContextState (perhaps a little too ambiguous without the explicit "chained")

-eric


More information about the Python-Dev mailing list