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: apple/swift-container-plugin
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 1.2.0
Choose a base ref
...
head repository: apple/swift-container-plugin
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 1.3.0
Choose a head ref
  • 2 commits
  • 3 files changed
  • 2 contributors

Commits on Feb 2, 2026

  1. Allow providing custom --env variables to be used in the container (#…

    …171)
    
    This is needed for swift-backtrace #154 . Following PR should be able to
    address that once we figure out
    https://forums.swift.org/t/where-to-source-swift-backtrace-binaries/84499
    
    Motivation
    ----------
    
    #154 ability to see backtraces for swift binaries. But generally it's
    also useful to set environment variables in containers for certain use
    cases.
    
    Modifications
    -------------
    
    Allow passing in `--env`, so you can direct `SWIFT_BACKTRACE`.
    
    Result
    ------
    
    Swift backtrace is possible on the end-user side. Example:
    wendylabsinc/wendy-agent#290
    
    Test Plan
    ---------
    
    I did manual testing already in wendy-agent. You can trivially test this
    by passing `--env` and reading it out in a swift app with the following
    code:
    
    ```swift
    import Foundation
    
    print(ProcessInfo.processInfo.environment)
    ```
    Joannis authored Feb 2, 2026
    Configuration menu
    Copy the full SHA
    2af8579 View commit details
    Browse the repository at this point in the history
  2. Handle non-JSON error payloads gracefully (#172)

    ## Summary
    
    Fixes #136
    
    When a registry returns an error response with a non-JSON body (e.g.,
    plain text like "page not found" from `registry:2`), `ContainerRegistry`
    now handles this gracefully instead of propagating a confusing
    `JSONDecoder` error.
    
    ## Changes
    
    1. Added new error case
    `RegistryClientError.unexpectedRegistryResponse(status:body:)`
    2. Modified both `executeRequestThrowing` methods to catch
    `DecodingError` when parsing error responses
    3. When JSON decoding fails, throws the new error with the HTTP status
    code and raw response body
    
    ## Before
    
    ```
    Error: dataCorrupted at coding path [] (The given data was not valid JSON.)
    ```
    
    ## After
    
    ```
    Registry returned HTTP 404: page not found
    ```
    
    ## Testing
    
    The fix handles the case mentioned in #136 where opening an upload
    session with an invalid repository name causes `registry:2` to respond
    with a 404 and plain text body "page not found".
    william-laverty authored Feb 2, 2026
    Configuration menu
    Copy the full SHA
    d9a516a View commit details
    Browse the repository at this point in the history
Loading