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-openapi-runtime
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 1.6.0
Choose a base ref
...
head repository: apple/swift-openapi-runtime
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 1.7.0
Choose a head ref
  • 6 commits
  • 29 files changed
  • 5 contributors

Commits on Nov 14, 2024

  1. Configuration menu
    Copy the full SHA
    335cac0 View commit details
    Browse the repository at this point in the history

Commits on Nov 15, 2024

  1. remove unused Swift 6 language mode workflow (#130)

    remove unused Swift 6 language mode workflow
    rnro authored Nov 15, 2024
    Configuration menu
    Copy the full SHA
    2cb09fb View commit details
    Browse the repository at this point in the history

Commits on Nov 19, 2024

  1. [Runtime] Improve parameter handling of MIME types in content types (#…

    …113)
    
    ### Motivation
    
    In service of an upcoming generator PR - to better handle parameters in
    MIME types.
    
    This is needed for APIs such as Kubernetes, that has both
    `application/json` and `application/json; watch=true` in a single
    operation.
    
    ### Modifications
    
    Use the more modern `OpenAPIMIMEType` type for parsing and comparing
    content types, rather than the old naive logic that ignored parameter
    (mis)matches.
    
    ### Result
    
    More accurate handling of content types.
    
    ### Test Plan
    
    Adapted unit tests.
    czechboy0 authored Nov 19, 2024
    Configuration menu
    Copy the full SHA
    b820948 View commit details
    Browse the repository at this point in the history

Commits on Nov 20, 2024

  1. add .editorconfig file (#129)

    add .editorconfig file
    rnro authored Nov 20, 2024
    Configuration menu
    Copy the full SHA
    0155a70 View commit details
    Browse the repository at this point in the history
  2. Add error handling middleware (#126)

    ### Motivation
    
    Implementation of [Improved error handling
    proposal](https://forums.swift.org/t/proposal-soar-0011-improved-error-handling/74736)
    
    ### Modifications
    
    Added HTTPResponseConvertible protocol
    Added ErrorHandlingMiddleware that converts errors confirming to
    HTTPResponseConvertible to a HTTP response.
    
    ### Result
    
    The new middleware is an opt-in middleware. So there won't be any change
    to existing clients.
    Clients who wish to have OpenAPI error handling can include the new
    error middleware in their application.
    
    ### Test Plan
    
    Added E2E tests to test the new middleware.
    
    ---------
    
    Co-authored-by: Gayathri Sairamkrishnan <gsairamkrishnan@apple.com>
    Co-authored-by: Honza Dvorsky <honza@apple.com>
    3 people authored Nov 20, 2024
    Configuration menu
    Copy the full SHA
    3d5d957 View commit details
    Browse the repository at this point in the history

Commits on Nov 21, 2024

  1. Refactor URIDecoder/URIParser to improve handling of the deepObject s…

    …tyle (#127)
    
    ### Motivation
    
    As part of apple/swift-openapi-generator#259,
    adding deepObject parameter style support, the initial PR wasn't
    complete.
    
    And once we dug more into it, turns out the original implementation of
    the URIDecoder/URIParser didn't really lend themselves well for handling
    deepObject, and the recent additions of supporting arrays within
    dictionaries (#120)
    further confused the implementation.
    
    ### Modifications
    
    Refactored URIParser/URIDecoder with a clearer understanding of the
    current requirements. It's now much easier to follow and embraces the
    fact that each of the 7 variants of URI coding we support (form
    exploded, form unexploded, simple exploded, simple unexploded, form data
    exploded, form data unexploded, and now deepObject exploded) are
    similar, but still different in subtle ways.
    
    This new implementation doesn't try as hard to share code between the
    implementations, so might at first sight appear to duplicate code. The
    original implementation had many methods with many configuration
    parameters and utility methods with a high cyclomatic complexity, which
    made it very hard to reason about. We did away with that.
    
    While there, I also made some minor improvements to the serialization
    path, which allows cleaner round-tripping tests.
    
    ### Result
    
    A more maintainable and more correct URI decoder/parser implementation.
    
    ### Test Plan
    
    Added many more unit tests that test the full matrix of supported styles
    and inputs.
    
    ---------
    
    Co-authored-by: Si Beaumont <simonjbeaumont@gmail.com>
    czechboy0 and simonjbeaumont authored Nov 21, 2024
    Configuration menu
    Copy the full SHA
    5e119a3 View commit details
    Browse the repository at this point in the history
Loading