{
    "content": [
        {
            "type": "text",
            "text": "# blinker (pydoc)\n\n**Summary:** blinker\n\n## Section Outline\n\n- **NAME** (2 lines)\n- **PACKAGE CONTENTS** (4 lines)\n- **CLASSES** (8 lines) — 4 subsections\n  - class NamedSignal (169 lines)\n  - class Namespace (147 lines)\n  - class Signal (158 lines)\n  - class WeakNamespace (162 lines)\n- **FUNCTIONS** (1 lines) — 1 subsections\n  - signal (4 lines)\n- **DATA** (19 lines)\n- **VERSION** (2 lines)\n- **FILE** (3 lines)\n\n## Full Content\n\n### NAME\n\nblinker\n\n### PACKAGE CONTENTS\n\nsaferef\nutilities\nbase\n\n### CLASSES\n\nbuiltins.dict(builtins.object)\nblinker.base.Namespace\nbuiltins.object\nblinker.base.Signal\nblinker.base.NamedSignal\nweakref.WeakValueDictionary(collections.abc.MutableMapping)\nblinker.base.WeakNamespace\n\n#### class NamedSignal\n\n|  NamedSignal(name, doc=None)\n|\n|  A named generic notification emitter.\n|\n|  Method resolution order:\n|      NamedSignal\n|      Signal\n|      builtins.object\n|\n|  Methods defined here:\n|\n|  init(self, name, doc=None)\n|      :param doc: optional.  If provided, will be assigned to the signal's\n|        doc attribute.\n|\n|  repr(self)\n|      Return repr(self).\n|\n|  ----------------------------------------------------------------------\n|  Methods inherited from Signal:\n|\n|  connect(self, receiver, sender=ANY, weak=True)\n|      Connect *receiver* to signal events sent by *sender*.\n|\n|      :param receiver: A callable.  Will be invoked by :meth:`send` with\n|        `sender=` as a single positional argument and any \\*\\*kwargs that\n|        were provided to a call to :meth:`send`.\n|\n|      :param sender: Any object or :obj:`ANY`, defaults to ``ANY``.\n|        Restricts notifications delivered to *receiver* to only those\n|        :meth:`send` emissions sent by *sender*.  If ``ANY``, the receiver\n|        will always be notified.  A *receiver* may be connected to\n|        multiple *sender* values on the same Signal through multiple calls\n|        to :meth:`connect`.\n|\n|      :param weak: If true, the Signal will hold a weakref to *receiver*\n|        and automatically disconnect when *receiver* goes out of scope or\n|        is garbage collected.  Defaults to True.\n|\n|  connectvia(self, sender, weak=False)\n|      Connect the decorated function as a receiver for *sender*.\n|\n|      :param sender: Any object or :obj:`ANY`.  The decorated function\n|        will only receive :meth:`send` emissions sent by *sender*.  If\n|        ``ANY``, the receiver will always be notified.  A function may be\n|        decorated multiple times with differing *sender* values.\n|\n|      :param weak: If true, the Signal will hold a weakref to the\n|        decorated function and automatically disconnect when *receiver*\n|        goes out of scope or is garbage collected.  Unlike\n|        :meth:`connect`, this defaults to False.\n|\n|      The decorated function will be invoked by :meth:`send` with\n|        `sender=` as a single positional argument and any \\*\\*kwargs that\n|        were provided to the call to :meth:`send`.\n|\n|\n|      .. versionadded:: 1.1\n|\n|  connectedto(self, receiver, sender=ANY)\n|      Execute a block with the signal temporarily connected to *receiver*.\n|\n|      :param receiver: a receiver callable\n|      :param sender: optional, a sender to filter on\n|\n|      This is a context manager for use in the ``with`` statement.  It can\n|      be useful in unit tests.  *receiver* is connected to the signal for\n|      the duration of the ``with`` block, and will be disconnected\n|      automatically when exiting the block:\n|\n|      .. testsetup::\n|\n|        from future import withstatement\n|        from blinker import Signal\n|        onready = Signal()\n|        receiver = lambda sender: None\n|\n|      .. testcode::\n|\n|        with onready.connectedto(receiver):\n|           # do stuff\n|           onready.send(123)\n|\n|      .. versionadded:: 1.1\n|\n|  disconnect(self, receiver, sender=ANY)\n|      Disconnect *receiver* from this signal's events.\n|\n|      :param receiver: a previously :meth:`connected<connect>` callable\n|\n|      :param sender: a specific sender to disconnect from, or :obj:`ANY`\n|        to disconnect from all senders.  Defaults to ``ANY``.\n|\n|  hasreceiversfor(self, sender)\n|      True if there is probably a receiver for *sender*.\n|\n|      Performs an optimistic check only.  Does not guarantee that all\n|      weakly referenced receivers are still alive.  See\n|      :meth:`receiversfor` for a stronger search.\n|\n|  receiverconnected = <blinker.utilities.lazyproperty object>\n|      Emitted after each :meth:`connect`.\n|\n|      The signal sender is the signal instance, and the :meth:`connect`\n|      arguments are passed through: *receiver*, *sender*, and *weak*.\n|\n|      .. versionadded:: 1.2\n|\n|  receiverdisconnected = <blinker.utilities.lazyproperty object>\n|      Emitted after :meth:`disconnect`.\n|\n|      The sender is the signal instance, and the :meth:`disconnect` arguments\n|      are passed through: *receiver* and *sender*.\n|\n|      Note, this signal is emitted only when :meth:`disconnect` is\n|      called explicitly.\n|\n|      The disconnect signal can not be emitted by an automatic disconnect\n|      (due to a weakly referenced receiver or sender going out of scope),\n|      as the receiver and/or sender instances are no longer available for\n|      use at the time this signal would be emitted.\n|\n|      An alternative approach is available by subscribing to\n|      :attr:`receiverconnected` and setting up a custom weakref cleanup\n|      callback on weak receivers and senders.\n|\n|      .. versionadded:: 1.2\n|\n|  receiversfor(self, sender)\n|      Iterate all live receivers listening for *sender*.\n|\n|  send(self, *sender, kwargs)\n|      Emit this signal on behalf of *sender*, passing on \\*\\*kwargs.\n|\n|      Returns a list of 2-tuples, pairing receivers with their return\n|      value. The ordering of receiver notification is undefined.\n|\n|      :param \\*sender: Any object or ``None``.  If omitted, synonymous\n|        with ``None``.  Only accepts one positional argument.\n|\n|      :param \\*\\*kwargs: Data to be sent to receivers.\n|\n|  temporarilyconnectedto(self, receiver, sender=ANY)\n|      An alias for :meth:`connectedto`.\n|\n|      :param receiver: a receiver callable\n|      :param sender: optional, a sender to filter on\n|\n|      .. versionadded:: 0.9\n|\n|      .. versionchanged:: 1.1\n|        Renamed to :meth:`connectedto`.  ``temporarilyconnectedto`` was\n|        deprecated in 1.2 and will be removed in a subsequent version.\n|\n|  ----------------------------------------------------------------------\n|  Data descriptors inherited from Signal:\n|\n|  dict\n|      dictionary for instance variables (if defined)\n|\n|  weakref\n|      list of weak references to the object (if defined)\n|\n|  ----------------------------------------------------------------------\n|  Data and other attributes inherited from Signal:\n|\n|  ANY = ANY\n|      Token for \"any sender\".\n\n#### class Namespace\n\n|  A mapping of signal names to signals.\n|\n|  Method resolution order:\n|      Namespace\n|      builtins.dict\n|      builtins.object\n|\n|  Methods defined here:\n|\n|  signal(self, name, doc=None)\n|      Return the :class:`NamedSignal` *name*, creating it if required.\n|\n|      Repeated calls to this function will return the same signal object.\n|\n|  ----------------------------------------------------------------------\n|  Data descriptors defined here:\n|\n|  dict\n|      dictionary for instance variables (if defined)\n|\n|  weakref\n|      list of weak references to the object (if defined)\n|\n|  ----------------------------------------------------------------------\n|  Methods inherited from builtins.dict:\n|\n|  contains(self, key, /)\n|      True if the dictionary has the specified key, else False.\n|\n|  delitem(self, key, /)\n|      Delete self[key].\n|\n|  eq(self, value, /)\n|      Return self==value.\n|\n|  ge(self, value, /)\n|      Return self>=value.\n|\n|  getattribute(self, name, /)\n|      Return getattr(self, name).\n|\n|  getitem(...)\n|      x.getitem(y) <==> x[y]\n|\n|  gt(self, value, /)\n|      Return self>value.\n|\n|  init(self, /, *args, kwargs)\n|      Initialize self.  See help(type(self)) for accurate signature.\n|\n|  ior(self, value, /)\n|      Return self|=value.\n|\n|  iter(self, /)\n|      Implement iter(self).\n|\n|  le(self, value, /)\n|      Return self<=value.\n|\n|  len(self, /)\n|      Return len(self).\n|\n|  lt(self, value, /)\n|      Return self<value.\n|\n|  ne(self, value, /)\n|      Return self!=value.\n|\n|  or(self, value, /)\n|      Return self|value.\n|\n|  repr(self, /)\n|      Return repr(self).\n|\n|  reversed(self, /)\n|      Return a reverse iterator over the dict keys.\n|\n|  ror(self, value, /)\n|      Return value|self.\n|\n|  setitem(self, key, value, /)\n|      Set self[key] to value.\n|\n|  sizeof(...)\n|      D.sizeof() -> size of D in memory, in bytes\n|\n|  clear(...)\n|      D.clear() -> None.  Remove all items from D.\n|\n|  copy(...)\n|      D.copy() -> a shallow copy of D\n|\n|  get(self, key, default=None, /)\n|      Return the value for key if key is in the dictionary, else default.\n|\n|  items(...)\n|      D.items() -> a set-like object providing a view on D's items\n|\n|  keys(...)\n|      D.keys() -> a set-like object providing a view on D's keys\n|\n|  pop(...)\n|      D.pop(k[,d]) -> v, remove specified key and return the corresponding value.\n|\n|      If the key is not found, return the default if given; otherwise,\n|      raise a KeyError.\n|\n|  popitem(self, /)\n|      Remove and return a (key, value) pair as a 2-tuple.\n|\n|      Pairs are returned in LIFO (last-in, first-out) order.\n|      Raises KeyError if the dict is empty.\n|\n|  setdefault(self, key, default=None, /)\n|      Insert key with a value of default if key is not in the dictionary.\n|\n|      Return the value for key if key is in the dictionary, else default.\n|\n|  update(...)\n|      D.update([E, ]F) -> None.  Update D from dict/iterable E and F.\n|      If E is present and has a .keys() method, then does:  for k in E: D[k] = E[k]\n|      If E is present and lacks a .keys() method, then does:  for k, v in E: D[k] = v\n|      In either case, this is followed by: for k in F:  D[k] = F[k]\n|\n|  values(...)\n|      D.values() -> an object providing a view on D's values\n|\n|  ----------------------------------------------------------------------\n|  Class methods inherited from builtins.dict:\n|\n|  classgetitem(...) from builtins.type\n|      See PEP 585\n|\n|  fromkeys(iterable, value=None, /) from builtins.type\n|      Create a new dictionary with keys from iterable and values set to value.\n|\n|  ----------------------------------------------------------------------\n|  Static methods inherited from builtins.dict:\n|\n|  new(*args, kwargs) from builtins.type\n|      Create and return a new object.  See help(type) for accurate signature.\n|\n|  ----------------------------------------------------------------------\n|  Data and other attributes inherited from builtins.dict:\n|\n|  hash = None\n\n#### class Signal\n\n|  Signal(doc=None)\n|\n|  A notification emitter.\n|\n|  Methods defined here:\n|\n|  init(self, doc=None)\n|      :param doc: optional.  If provided, will be assigned to the signal's\n|        doc attribute.\n|\n|  connect(self, receiver, sender=ANY, weak=True)\n|      Connect *receiver* to signal events sent by *sender*.\n|\n|      :param receiver: A callable.  Will be invoked by :meth:`send` with\n|        `sender=` as a single positional argument and any \\*\\*kwargs that\n|        were provided to a call to :meth:`send`.\n|\n|      :param sender: Any object or :obj:`ANY`, defaults to ``ANY``.\n|        Restricts notifications delivered to *receiver* to only those\n|        :meth:`send` emissions sent by *sender*.  If ``ANY``, the receiver\n|        will always be notified.  A *receiver* may be connected to\n|        multiple *sender* values on the same Signal through multiple calls\n|        to :meth:`connect`.\n|\n|      :param weak: If true, the Signal will hold a weakref to *receiver*\n|        and automatically disconnect when *receiver* goes out of scope or\n|        is garbage collected.  Defaults to True.\n|\n|  connectvia(self, sender, weak=False)\n|      Connect the decorated function as a receiver for *sender*.\n|\n|      :param sender: Any object or :obj:`ANY`.  The decorated function\n|        will only receive :meth:`send` emissions sent by *sender*.  If\n|        ``ANY``, the receiver will always be notified.  A function may be\n|        decorated multiple times with differing *sender* values.\n|\n|      :param weak: If true, the Signal will hold a weakref to the\n|        decorated function and automatically disconnect when *receiver*\n|        goes out of scope or is garbage collected.  Unlike\n|        :meth:`connect`, this defaults to False.\n|\n|      The decorated function will be invoked by :meth:`send` with\n|        `sender=` as a single positional argument and any \\*\\*kwargs that\n|        were provided to the call to :meth:`send`.\n|\n|\n|      .. versionadded:: 1.1\n|\n|  connectedto(self, receiver, sender=ANY)\n|      Execute a block with the signal temporarily connected to *receiver*.\n|\n|      :param receiver: a receiver callable\n|      :param sender: optional, a sender to filter on\n|\n|      This is a context manager for use in the ``with`` statement.  It can\n|      be useful in unit tests.  *receiver* is connected to the signal for\n|      the duration of the ``with`` block, and will be disconnected\n|      automatically when exiting the block:\n|\n|      .. testsetup::\n|\n|        from future import withstatement\n|        from blinker import Signal\n|        onready = Signal()\n|        receiver = lambda sender: None\n|\n|      .. testcode::\n|\n|        with onready.connectedto(receiver):\n|           # do stuff\n|           onready.send(123)\n|\n|      .. versionadded:: 1.1\n|\n|  disconnect(self, receiver, sender=ANY)\n|      Disconnect *receiver* from this signal's events.\n|\n|      :param receiver: a previously :meth:`connected<connect>` callable\n|\n|      :param sender: a specific sender to disconnect from, or :obj:`ANY`\n|        to disconnect from all senders.  Defaults to ``ANY``.\n|\n|  hasreceiversfor(self, sender)\n|      True if there is probably a receiver for *sender*.\n|\n|      Performs an optimistic check only.  Does not guarantee that all\n|      weakly referenced receivers are still alive.  See\n|      :meth:`receiversfor` for a stronger search.\n|\n|  receiverconnected = <blinker.utilities.lazyproperty object>\n|      Emitted after each :meth:`connect`.\n|\n|      The signal sender is the signal instance, and the :meth:`connect`\n|      arguments are passed through: *receiver*, *sender*, and *weak*.\n|\n|      .. versionadded:: 1.2\n|\n|  receiverdisconnected = <blinker.utilities.lazyproperty object>\n|      Emitted after :meth:`disconnect`.\n|\n|      The sender is the signal instance, and the :meth:`disconnect` arguments\n|      are passed through: *receiver* and *sender*.\n|\n|      Note, this signal is emitted only when :meth:`disconnect` is\n|      called explicitly.\n|\n|      The disconnect signal can not be emitted by an automatic disconnect\n|      (due to a weakly referenced receiver or sender going out of scope),\n|      as the receiver and/or sender instances are no longer available for\n|      use at the time this signal would be emitted.\n|\n|      An alternative approach is available by subscribing to\n|      :attr:`receiverconnected` and setting up a custom weakref cleanup\n|      callback on weak receivers and senders.\n|\n|      .. versionadded:: 1.2\n|\n|  receiversfor(self, sender)\n|      Iterate all live receivers listening for *sender*.\n|\n|  send(self, *sender, kwargs)\n|      Emit this signal on behalf of *sender*, passing on \\*\\*kwargs.\n|\n|      Returns a list of 2-tuples, pairing receivers with their return\n|      value. The ordering of receiver notification is undefined.\n|\n|      :param \\*sender: Any object or ``None``.  If omitted, synonymous\n|        with ``None``.  Only accepts one positional argument.\n|\n|      :param \\*\\*kwargs: Data to be sent to receivers.\n|\n|  temporarilyconnectedto(self, receiver, sender=ANY)\n|      An alias for :meth:`connectedto`.\n|\n|      :param receiver: a receiver callable\n|      :param sender: optional, a sender to filter on\n|\n|      .. versionadded:: 0.9\n|\n|      .. versionchanged:: 1.1\n|        Renamed to :meth:`connectedto`.  ``temporarilyconnectedto`` was\n|        deprecated in 1.2 and will be removed in a subsequent version.\n|\n|  ----------------------------------------------------------------------\n|  Data descriptors defined here:\n|\n|  dict\n|      dictionary for instance variables (if defined)\n|\n|  weakref\n|      list of weak references to the object (if defined)\n|\n|  ----------------------------------------------------------------------\n|  Data and other attributes defined here:\n|\n|  ANY = ANY\n|      Token for \"any sender\".\n\n#### class WeakNamespace\n\n|  WeakNamespace(other=(), /, kw)\n|\n|  A weak mapping of signal names to signals.\n|\n|  Automatically cleans up unused Signals when the last reference goes out\n|  of scope.  This namespace implementation exists for a measure of legacy\n|  compatibility with Blinker <= 1.2, and may be dropped in the future.\n|\n|  .. versionadded:: 1.3\n|\n|  Method resolution order:\n|      WeakNamespace\n|      weakref.WeakValueDictionary\n|      collections.abc.MutableMapping\n|      collections.abc.Mapping\n|      collections.abc.Collection\n|      collections.abc.Sized\n|      collections.abc.Iterable\n|      collections.abc.Container\n|      builtins.object\n|\n|  Methods defined here:\n|\n|  signal(self, name, doc=None)\n|      Return the :class:`NamedSignal` *name*, creating it if required.\n|\n|      Repeated calls to this function will return the same signal object.\n|\n|  ----------------------------------------------------------------------\n|  Data and other attributes defined here:\n|\n|  abstractmethods = frozenset()\n|\n|  ----------------------------------------------------------------------\n|  Methods inherited from weakref.WeakValueDictionary:\n|\n|  contains(self, key)\n|\n|  copy = copy(self)\n|\n|  deepcopy(self, memo)\n|\n|  delitem(self, key)\n|\n|  getitem(self, key)\n|\n|  init(self, other=(), /, kw)\n|      Initialize self.  See help(type(self)) for accurate signature.\n|\n|  ior(self, other)\n|\n|  iter = keys(self)\n|\n|  len(self)\n|\n|  or(self, other)\n|      Return self|value.\n|\n|  repr(self)\n|      Return repr(self).\n|\n|  ror(self, other)\n|      Return value|self.\n|\n|  setitem(self, key, value)\n|\n|  copy(self)\n|\n|  get(self, key, default=None)\n|      D.get(k[,d]) -> D[k] if k in D, else d.  d defaults to None.\n|\n|  items(self)\n|      D.items() -> a set-like object providing a view on D's items\n|\n|  itervaluerefs(self)\n|      Return an iterator that yields the weak references to the values.\n|\n|      The references are not guaranteed to be 'live' at the time\n|      they are used, so the result of calling the references needs\n|      to be checked before being used.  This can be used to avoid\n|      creating references that will cause the garbage collector to\n|      keep the values around longer than needed.\n|\n|  keys(self)\n|      D.keys() -> a set-like object providing a view on D's keys\n|\n|  pop(self, key, *args)\n|      D.pop(k[,d]) -> v, remove specified key and return the corresponding value.\n|      If key is not found, d is returned if given, otherwise KeyError is raised.\n|\n|  popitem(self)\n|      D.popitem() -> (k, v), remove and return some (key, value) pair\n|      as a 2-tuple; but raise KeyError if D is empty.\n|\n|  setdefault(self, key, default=None)\n|      D.setdefault(k[,d]) -> D.get(k,d), also set D[k]=d if k not in D\n|\n|  update(self, other=None, /, kwargs)\n|      D.update([E, ]F) -> None.  Update D from mapping/iterable E and F.\n|      If E present and has a .keys() method, does:     for k in E: D[k] = E[k]\n|      If E present and lacks .keys() method, does:     for (k, v) in E: D[k] = v\n|      In either case, this is followed by: for k, v in F.items(): D[k] = v\n|\n|  valuerefs(self)\n|      Return a list of weak references to the values.\n|\n|      The references are not guaranteed to be 'live' at the time\n|      they are used, so the result of calling the references needs\n|      to be checked before being used.  This can be used to avoid\n|      creating references that will cause the garbage collector to\n|      keep the values around longer than needed.\n|\n|  values(self)\n|      D.values() -> an object providing a view on D's values\n|\n|  ----------------------------------------------------------------------\n|  Data descriptors inherited from weakref.WeakValueDictionary:\n|\n|  dict\n|      dictionary for instance variables (if defined)\n|\n|  weakref\n|      list of weak references to the object (if defined)\n|\n|  ----------------------------------------------------------------------\n|  Methods inherited from collections.abc.MutableMapping:\n|\n|  clear(self)\n|      D.clear() -> None.  Remove all items from D.\n|\n|  ----------------------------------------------------------------------\n|  Methods inherited from collections.abc.Mapping:\n|\n|  eq(self, other)\n|      Return self==value.\n|\n|  ----------------------------------------------------------------------\n|  Data and other attributes inherited from collections.abc.Mapping:\n|\n|  hash = None\n|\n|  reversed = None\n|\n|  ----------------------------------------------------------------------\n|  Class methods inherited from collections.abc.Collection:\n|\n|  subclasshook(C) from abc.ABCMeta\n|      Abstract classes can override this to customize issubclass().\n|\n|      This is invoked early on by abc.ABCMeta.subclasscheck().\n|      It should return True, False or NotImplemented.  If it returns\n|      NotImplemented, the normal algorithm is used.  Otherwise, it\n|      overrides the normal algorithm (and the outcome is cached).\n|\n|  ----------------------------------------------------------------------\n|  Class methods inherited from collections.abc.Iterable:\n|\n|  classgetitem = GenericAlias(...) from abc.ABCMeta\n|      Represent a PEP 585 generic type\n|\n|      E.g. for t = list[int], t.origin is list and t.args is (int,).\n\n### FUNCTIONS\n\n#### signal\n\nReturn the :class:`NamedSignal` *name*, creating it if required.\n\nRepeated calls to this function will return the same signal object.\n\n### DATA\n\nANY = ANY\nToken for \"any sender\".\n\nall = ['ANY', 'NamedSignal', 'Namespace', 'Signal', 'WeakNamespace...\nreceiverconnected = <blinker.base.Signal object>\nSent by a :class:`Signal` after a receiver connects.\n\n:argument: the Signal that was connected to\n:keyword receiverarg: the connected receiver\n:keyword senderarg: the sender to connect to\n:keyword weakarg: true if the connection to receiverarg is a weak reference\n\n.. deprecated:: 1.2\n\nAs of 1.2, individual signals have their own private\n:attr:`~Signal.receiverconnected` and\n:attr:`~Signal.receiverdisconnected` signals with a slightly simplified\ncall signature.  This global signal is planned to be removed in 1.6.\n\n### VERSION\n\n1.4\n\n### FILE\n\n/usr/lib/python3/dist-packages/blinker/init.py\n\n"
        }
    ],
    "structuredContent": {
        "command": "blinker",
        "section": "",
        "mode": "pydoc",
        "summary": "blinker",
        "synopsis": null,
        "tldr_summary": null,
        "tldr_examples": [],
        "tldr_source": null,
        "flags": [],
        "examples": [],
        "see_also": [],
        "section_outline": [
            {
                "name": "NAME",
                "lines": 2,
                "subsections": []
            },
            {
                "name": "PACKAGE CONTENTS",
                "lines": 4,
                "subsections": []
            },
            {
                "name": "CLASSES",
                "lines": 8,
                "subsections": [
                    {
                        "name": "class NamedSignal",
                        "lines": 169
                    },
                    {
                        "name": "class Namespace",
                        "lines": 147
                    },
                    {
                        "name": "class Signal",
                        "lines": 158
                    },
                    {
                        "name": "class WeakNamespace",
                        "lines": 162
                    }
                ]
            },
            {
                "name": "FUNCTIONS",
                "lines": 1,
                "subsections": [
                    {
                        "name": "signal",
                        "lines": 4
                    }
                ]
            },
            {
                "name": "DATA",
                "lines": 19,
                "subsections": []
            },
            {
                "name": "VERSION",
                "lines": 2,
                "subsections": []
            },
            {
                "name": "FILE",
                "lines": 3,
                "subsections": []
            }
        ]
    }
}