Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: PyMySQL/PyMySQL
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 5613187
Choose a base ref
...
head repository: PyMySQL/PyMySQL
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 0f1c324
Choose a head ref
  • 14 commits
  • 17 files changed
  • 4 contributors

Commits on May 7, 2026

  1. Bump the all-dependencies group with 2 updates (#1232)

    Bumps the all-dependencies group with 2 updates:
    [actions/upload-artifact](https://github.com/actions/upload-artifact)
    and
    [actions/download-artifact](https://github.com/actions/download-artifact).
    
    Signed-off-by: dependabot[bot] <support@github.com>
    dependabot[bot] authored May 7, 2026
    Configuration menu
    Copy the full SHA
    97ddfaa View commit details
    Browse the repository at this point in the history

Commits on May 8, 2026

  1. Reorganize TLS options: implement PREFERRED/REQUIRED SSL mode behavior (

    #1234)
    
    1. `ssl_disabled=True` → prohibit SSL
    2. Any explicit SSL option set (`ssl`, `ssl_ca`, `ssl_cert`, `ssl_key`,
    `ssl_key_password`, `ssl_verify_cert`, `ssl_verify_identity`) →
    **REQUIRED**: raises `OperationalError(CR_SSL_CONNECTION_ERROR)` if the
    server doesn't advertise `CLIENT.SSL`
    3. No SSL options → **PREFERRED**: attempt SSL if the server supports
    it, fall back to plain connection otherwise
    
    Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
    Co-authored-by: Inada Naoki <songofacandy@gmail.com>
    Copilot and methane authored May 8, 2026
    Configuration menu
    Copy the full SHA
    8e3a79d View commit details
    Browse the repository at this point in the history

Commits on May 14, 2026

  1. Support MySQL 8 row/column alias syntax in executemany INSERT regex (

    …#1235)
    
    `Cursor.executemany()` fast-path parsing for `INSERT ... VALUES ... ON
    DUPLICATE KEY UPDATE` did not accept MySQL 8.0.19+ alias syntax (`VALUES
    (...) AS alias`), so these statements could miss bulk-insert
    optimization. This updates the parser to recognize the newer syntax
    while preserving existing behavior.
    
    - **Regex update in `pymysql/cursors.py`**
      - Extend `RE_INSERT_VALUES` suffix parsing to accept:
        - optional `AS <row_alias>`
        - optional `AS <row_alias>(<col_alias>, ...)`
        - followed by optional `ON DUPLICATE ...`
    - Keep existing `INSERT|REPLACE ... VALUES (...)` grouping semantics
    used by `executemany()`.
    
    - **Compatibility preserved**
    - Existing legacy upsert style using `VALUES(col)` in `ON DUPLICATE KEY
    UPDATE` remains supported.
    
    - **Focused coverage in `pymysql/tests/test_cursor.py`**
      - Add regex assertions for:
        - `VALUES (...) AS new ON DUPLICATE KEY UPDATE ...`
        - `VALUES (...) AS new(c1,c2,...) ON DUPLICATE KEY UPDATE ...`
        - legacy `ON DUPLICATE KEY UPDATE ... VALUES(...)`
    
    ```python
    m = pymysql.cursors.RE_INSERT_VALUES.match(
        "INSERT INTO t1 (a,b,c) VALUES (%s,%s,%s) AS new "
        "ON DUPLICATE KEY UPDATE c = new.a + new.b"
    )
    ```
    
    ---------
    
    Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
    Co-authored-by: methane <199592+methane@users.noreply.github.com>
    Co-authored-by: Inada Naoki <songofacandy@gmail.com>
    3 people authored May 14, 2026
    Configuration menu
    Copy the full SHA
    097fad6 View commit details
    Browse the repository at this point in the history

Commits on May 15, 2026

  1. Expose SQLSTATE on MySQL protocol exceptions without changing excepti…

    …on formatting (#1236)
    
    MySQL ERR packets can include a 5-byte SQLSTATE, but PyMySQL currently
    drops it when raising exceptions. This change preserves that protocol
    metadata on the exception object while keeping the existing exception
    args and string representation stable.
    Copilot authored May 15, 2026
    Configuration menu
    Copy the full SHA
    113e252 View commit details
    Browse the repository at this point in the history
  2. Reject non-finite decimal.Decimal query parameters (NaN, sNaN, …

    …`±Infinity`) (#1237)
    
    PyMySQL already rejects non-finite `float` parameters before sending
    SQL, but equivalent `decimal.Decimal` values were still serialized and
    sent. This change aligns Decimal behavior with existing float safeguards
    for unsupported non-finite numeric parameters.
    Copilot authored May 15, 2026
    Configuration menu
    Copy the full SHA
    c532b8d View commit details
    Browse the repository at this point in the history
  3. docs: update outdated requirements and reference links (#1239)

    - aligned docs Python requirement with package metadata (`CPython >=
    3.9`)
    - updated outdated DB-API/MySQL/Python links to current HTTPS URLs
    - updated Sphinx intersphinx mapping to `https://docs.python.org/3`
    Copilot authored May 15, 2026
    Configuration menu
    Copy the full SHA
    c7bf73f View commit details
    Browse the repository at this point in the history
  4. Prepare CHANGELOG for v1.2.0 release from v1.1.3 changes (#1238)

    - update `CHANGELOG.md` for `v1.2.0` release preparation
    - add `Release date: TBD`
    - add changelog entries for user-visible changes since `v1.1.3` (#1234,
    #1235, #1236, #1237)
    Copilot authored May 15, 2026
    Configuration menu
    Copy the full SHA
    af6b9b4 View commit details
    Browse the repository at this point in the history

Commits on May 18, 2026

  1. Deprecation and removals (#1240)

    - Deprecate `db` and `passwd` again
    - Remove deprecated error classes in Cursor class attributes.
    methane authored May 18, 2026
    Configuration menu
    Copy the full SHA
    c963edb View commit details
    Browse the repository at this point in the history
  2. update CHANGELOG

    methane committed May 18, 2026
    Configuration menu
    Copy the full SHA
    ad5c50c View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    7349a44 View commit details
    Browse the repository at this point in the history
  4. add AGENTS.md

    methane committed May 18, 2026
    Configuration menu
    Copy the full SHA
    23ca04a View commit details
    Browse the repository at this point in the history

Commits on May 19, 2026

  1. Deprecate Connection.set_charset() at runtime and document warning …

    …behavior (#1243)
    
    `Connection.set_charset(charset)` was marked for future removal but did
    not emit a deprecation signal at call time. This change adds runtime
    deprecation signaling and updates release notes accordingly.
    Copilot authored May 19, 2026
    Configuration menu
    Copy the full SHA
    637fe7e View commit details
    Browse the repository at this point in the history
  2. Release v1.2.0 (#1244)

    methane authored May 19, 2026
    Configuration menu
    Copy the full SHA
    53b16b2 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    0f1c324 View commit details
    Browse the repository at this point in the history
Loading