Skip to content
Permalink
Tree: f5c107cacd
Commits on Jul 8, 2019
  1. BytesGenerator requires BinaryIO (#3106)

    cole authored and JelleZijlstra committed Jul 8, 2019
Commits on Jul 4, 2019
  1. Add types to FileStorage (#3067)

    srittau authored and JelleZijlstra committed Jul 4, 2019
  2. Improving Flask stubs (#3003)

    s-kovacevic authored and JelleZijlstra committed Jul 4, 2019
    * Fix flask render_template and render_template_string stubs
    
    * Add types for flask view function
    
    * Import TracebackType from the right location
    
    * Switch to bound typevar in route decorator stub
    
    * Change render_template and render_template_string parameters to Text
Commits on Jul 3, 2019
  1. Fix HTTPConnection.putrequest parameter names (#3101)

    SamChou19815 authored and srittau committed Jul 3, 2019
  2. Add in multiprocessing.managers.ValueProxy types (#3100)

    ikelos authored and srittau committed Jul 3, 2019
    Fixes #1778
Commits on Jul 2, 2019
  1. PurePath methods accept os.PathLike[str] from 3.6 (#3099)

    fcolas authored and srittau committed Jul 2, 2019
    Closes #3095
  2. Fix contextlib GeneratorContextManager name for py>=3.2 (#3083)

    RafiB authored and ilevkivskyi committed Jul 2, 2019
Commits on Jul 1, 2019
  1. QueueHandler / QueueListener accept SimpleQueue too (#3098)

    mjpieters authored and JelleZijlstra committed Jul 1, 2019
    The implementation of `logging.adapters.QueueHandler` and `logging.adapters.QueueListener` works great with `queue.SimpleQueue` too, so update the stub to reflect this.
    
    The new queue.SimpleQueue class (introduced in 3.7) is faster but is not a Queue subclass as it doesn't implement task handling (`handle_task()` / `join()`) or queue bounds (raising `queue.Full` / `full()`). The logging handler / listener implementations do not make use of those features however.
    
    Related Python bug, asking for an explicit documentation mention: https://bugs.python.org/issue37469
  2. xml.etree.ElementTree: fix missing None in get(), findtext() return t…

    bluetech authored and srittau committed Jul 1, 2019
    …ype (#3093)
  3. Add Generic Typing to Queue.PriorityQueue and Queue.LifoQueue in pyth…

    JasonGilholme authored and srittau committed Jul 1, 2019
    …on 2 (#3036)
  4. Add TLSVersion & related attributes to SSLContext (#3097)

    hynek authored and srittau committed Jul 1, 2019
Commits on Jun 29, 2019
  1. Make dataclasses.Field.metadata non-optional (#3094)

    bgw authored and JelleZijlstra committed Jun 29, 2019
    If `metadata` is `None` the Field constructor replaces it with an empty
    mapping object, so this value can never be None.
    
    https://github.com/python/cpython/blob/v3.7.3/Lib/dataclasses.py#L243
Commits on Jun 27, 2019
  1. Add undocumented methods codecs.utf_16_be_{decode,encode}. (#3091)

    rchen152 committed Jun 27, 2019
    I found the signatures here:
    https://github.com/python/cpython/blob/6a16b18224fa98f6d192aa5014affeccc0376eb3/Modules/_codecsmodule.c#L729
    
    google/pytype#348 was opened against
    pytype about utf_16_be_encode being missing.
Commits on Jun 26, 2019
  1. Restore default value to click.echo_via_pager (#3090)

    chronitis authored and JelleZijlstra committed Jun 26, 2019
Commits on Jun 24, 2019
  1. Install Black and isort autoformatters (#3069)

    Eric-Arellano authored and srittau committed Jun 24, 2019
    * Install Black and isort
    
    * Add config via pyproject.toml
    
    Notably we keep the convention of 130 line length.
    
    * Add target python version
Commits on Jun 22, 2019
  1. itsdangerous: update JSONWebSignatureSerializer.dumps return type (#3082

    redshiftzero authored and JelleZijlstra committed Jun 22, 2019
    )
    
    On Python 2, a str is returned, however on Python 3 the return type
    is bytes.
  2. "key" argument of builtin function sorted should be optional in pytho…

    chadrik authored and JelleZijlstra committed Jun 22, 2019
    …n 2.7 (#3086)
  3. Fix annotation of re.Match 'lastindex' and 'lastgroup' in Python 3 (#…

    mthuurne authored and JelleZijlstra committed Jun 22, 2019
    …3085)
    
    Both are None if there were no groups matched. Also 'lastgroup'
    will be None if the matched group was nameless.
    
    The Python 2 versions of these annotations already used Optional.
Commits on Jun 21, 2019
  1. fix type of loop.sock_connect (#3073)

    JelleZijlstra authored and srittau committed Jun 21, 2019
  2. Revert "Define functools.partial as overloaded function instead of it…

    JelleZijlstra committed Jun 21, 2019
    …s own class (#2878)" (#3077)
    
    This reverts commit e45f443.
Commits on Jun 20, 2019
  1. Add mp_context parameter to concurrent.futures.ProcessPoolExecutor (#…

    crusaderky authored and srittau committed Jun 20, 2019
    …3078)
    
    Closes #3076
  2. fix ssl.Purpose type in py3 (#3054)

    Hanaasagi authored and srittau committed Jun 20, 2019
Commits on Jun 19, 2019
  1. Add types and functions in types.py that are new in 3.7 (#3066)

    CraftSpider authored and JelleZijlstra committed Jun 19, 2019
    * Add types and functions in types.py that are new in 3.7
    
    * Update `resolve_bases` to accept any iterable of objects, and the same
    for `new_class` if the version is at least 3.7
    
    * Add comparison overrides implemented by MethodWrapperType
    
    * Fix mypy error due to over-constrained `__eq__`
  2. Refactor tests/pytype_test.py (#3065)

    Eric-Arellano authored and JelleZijlstra committed Jun 19, 2019
  3. change http.cookies.Morsel to Dict[str, Any] (#3060)

    FlorianLudwig authored and JelleZijlstra committed Jun 19, 2019
    Morsel does cast any value to string and therfor any is the correct
    typehint. For some keys other types then strings are more
    appropiate anyway, max-age can take an integer (unix time) and http-only
    a boolean.
    
    Closes #3059
  4. Represent the use of IntEnums in functions in socket.py. (#3009)

    MatthewWilkes authored and JelleZijlstra committed Jun 19, 2019
    The Pull Request #1121 added the `AddressFamily` type to `socket.pyi`
    for Python 3.4+, so constants such as `AF_INET` are correctly
    represented as being an enum member rather than an int. The same is
    true of the `SocketKind` enums in the `SOCK_*` family.
    
    Various functions in the socket module can accept either an int
    or an `AF_*` enum member as arguments, which is allowed by the
    int argument type. However the `getaddrinfo` function returns an
    `AddressFamily` member rather than an int in the first position
    of its list members, so code that access enum specific members
    such as the `name` attribute causes a typing error to be found.
    
    This change corrects the return type of `getaddrinfo` but leaves
    the family parameters as int, given that `AddressFamily` members
    are `IntEnum` and only ever treated as `int`s internally.
  5. HTMLParser.get_starttag_text() can return None (#3072)

    narusemotoki authored and srittau committed Jun 19, 2019
Commits on Jun 18, 2019
  1. redis: Add some type hints (#3055)

    bochecha authored and srittau committed Jun 18, 2019
  2. Sync recent typing and typing_extensions updates (#3070)

    ilevkivskyi committed Jun 18, 2019
    This includes two things to sync up with recent runtime updates:
    * Move `Final`, `@Final`, `Literal`, and `TypedDict` to `typing` (`typing_extensions` still defines or re-exports them)
    * Rename `@typing.runtime` to `@typing.runtime_checkable`, while keeping `@runtime` as a backwards-compatible alias in `typing_extensions`.
Commits on Jun 17, 2019
  1. Overload ast.parse to recognize that mode=exec means Module return. (#…

    carljm authored and srittau committed Jun 17, 2019
  2. str and unicode format functions take objects (#3068)

    Jadiker authored and srittau committed Jun 17, 2019
Commits on Jun 16, 2019
  1. ssl.pyi: fix types of cadata argument (#3063)

    alexf91 authored and JelleZijlstra committed Jun 16, 2019
  2. Marshal dumps/loads uses bytes (#3061)

    flacjacket authored and srittau committed Jun 16, 2019
    The marshal.dumps and marshal.loads functions should return and accept
    bytes, respectively, rather than a string.
Commits on Jun 15, 2019
  1. Update select and selectors to use _HasFileno protocol (#3057)

    Eric-Arellano authored and JelleZijlstra committed Jun 15, 2019
Commits on Jun 13, 2019
  1. Adding stubs for pyre_extensions (#3056)

    mrkmndz authored and srittau committed Jun 13, 2019
Older
You can’t perform that action at this time.