Commits · python/cpython

Commits on Aug 8, 2021

  1. bpo-44859: Improve error handling in sqlite3 and and raise more accur…

    …ate exceptions. (GH-27654)
    
    * MemoryError is now raised instead of sqlite3.Warning when
      memory is not enough for encoding a statement to UTF-8
      in Connection.__call__() and Cursor.execute().
    * UnicodEncodeError is now raised instead of sqlite3.Warning when
      the statement contains surrogate characters
      in Connection.__call__() and Cursor.execute().
    * TypeError is now raised instead of ValueError for non-string
      script argument in Cursor.executescript().
    * ValueError is now raised for script containing the null
      character instead of truncating it in Cursor.executescript().
    * Correctly handle exceptions raised when getting boolean value
      of the result of the progress handler.
    * Add many tests covering different corner cases.
    
    Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no>

Commits on Aug 7, 2021

Commits on Aug 6, 2021

  1. bpo-40928: notify users running test_decimal on macOS of malloc warni…

    …ngs (GH-26783)
    
    * When trying to allocate very large regions on macOS, malloc does not   fail silently. It sends a noisy error out to STDERR
    * This provides a helper function to warn the user, and provides the warning for test_decimal, which consistently generates these warnings on macOS.
    
    Co-authored-by: Łukasz Langa <lukasz@langa.pl>

Commits on Aug 5, 2021

Commits on Aug 4, 2021

Commits on Aug 3, 2021