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: coder/coder-jetbrains-toolbox
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 0ad31dd
Choose a base ref
...
head repository: coder/coder-jetbrains-toolbox
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 2decf9b
Choose a head ref
  • 8 commits
  • 10 files changed
  • 1 contributor

Commits on Jul 28, 2025

  1. impl: relax json syntax rules for deserialization

    For some clients, workspace polling fails due to the following error:
    
    ```
    com.squareup.moshi.JsonEncodingException: Use JsonReader.setLenient(true) to accept malformed JSON at path $
    ```
    
    I haven’t been able to reproduce this issue, even using the same version deployed at the
    client (2.20.2). This change is an attempt to relax the JSON parsing rules by enabling
    lenient mode, in the hope that it will resolve the issue on the client side.
    fioan89 committed Jul 28, 2025
    Configuration menu
    Copy the full SHA
    4f1c279 View commit details
    Browse the repository at this point in the history

Commits on Jul 31, 2025

  1. Configuration menu
    Copy the full SHA
    50da220 View commit details
    Browse the repository at this point in the history
  2. impl: add error logging for malformed JSON responses in Coder REST AP…

    …I calls
    
    Wraps Moshi converter to log raw response body when JSON parsing fails. It helps debug
    malformed JSON during workspace polling by logging full response content, content type, and
    error details when a exception during marshalling occurs.
    
    A couple of approaches were tried, unfortunately by the time the exception is raised the
    response body has already been consumed by Moshi's converter, so you can't read it again.
    The interceptors are also not really a viable option, they are called before the converters which means:
    
    - we don't know if the response body is in the correct form or not. This is problematic
    because it means for every rest call we have to read the body twice (interceptor and by
    moshi converter)
    - we also have to save the intercepted body and store it until we have an exception from
    moshi, in which case it will have to be logged.
    
    This approach only logs on conversion failures, and the only performance impact on successful
    responses is the fact that we convert the response body byte stream to a string representation
    that can later be printed, and then again back to a byte stream by the moshi converter.
    fioan89 committed Jul 31, 2025
    Configuration menu
    Copy the full SHA
    7d4a8ad View commit details
    Browse the repository at this point in the history

Commits on Aug 5, 2025

  1. Configuration menu
    Copy the full SHA
    8fca449 View commit details
    Browse the repository at this point in the history
  2. impl: configure the rest api client log level from the Settings page

    This commit adds support for allowing the user to configure the rest api client log level in the Settings page.
    fioan89 committed Aug 5, 2025
    Configuration menu
    Copy the full SHA
    f8606a0 View commit details
    Browse the repository at this point in the history
  3. impl: log the rest api client request and response

    A new interceptor is now available in the rest client that is able to
    log different level of details regarding the request/response:
    - if None is configured by user we skip logging
    - Basic level prints the method + url + response code
    - Headers prints in addition the request and response headers sanitized first
    - Body also prints the request/response body
    fioan89 committed Aug 5, 2025
    Configuration menu
    Copy the full SHA
    4cab216 View commit details
    Browse the repository at this point in the history
  4. chore: remove support for lenient moshi marshaller

    It is dangerous because it can allow dangerous operations in the plugin due to insufficient data that can be
    interpreted as default state.
    fioan89 committed Aug 5, 2025
    Configuration menu
    Copy the full SHA
    8a3a698 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    2decf9b View commit details
    Browse the repository at this point in the history
Loading