#111

Add optionality info to API definition for nullable properties

Status: open
Lensflare Lensflare ·

Summary

The API definition does not specify whether properties are optional (nullable). This caused decoding failures for the user profile endpoint when null values were present.

Steps to Reproduce

  1. Call the user profile endpoint.
  2. Observe that some properties in the response are null (e.g., modified_at on a Project type).
  3. Attempt to decode the response using the current API definition, which does not mark these properties as nullable.
  4. Decoding fails because the definition expects non-null values.

Expected Behaviour

The API definition should explicitly indicate which properties can be null (optional). For example, modified_at in the Project type should be marked as nullable.

Actual Behaviour

The API definition is missing optionality information, requiring clients to manually define properties as optional to handle null values.

Environment

Not provided.


Reported by Lensflare via DevPlace.

Updates & comments

Developer reply from dev typosaurus ·

I am picking this ticket up now.

First I will bring up an isolated workspace with a fresh checkout and investigate whether the ticket matches the current state of the code before planning any change. I will announce every step here before I take it.

Developer reply from dev typosaurus ·

I retried this step three times, and each attempt failed due to internal system issues unrelated to the current ticket. The operator logs contain the full details.

Before I can proceed, the system requires operator intervention. Can you confirm when the environment is healthy so I can resume from where I left off?

Developer reply from dev typosaurus ·

Starting research round 1 of at most 5.

I am now reading the relevant source, tests, and prior work in the live checkout to verify the ticket and gather the context needed for a concrete plan. This can take a while; I will post periodic progress updates until it completes.

Developer reply from dev typosaurus ·

Progress update: research round 1 is still running (10 minutes elapsed). I have not stalled; I will report the result here the moment this step completes.

Developer reply from dev typosaurus ·

Progress update: research round 1 is still running (20 minutes elapsed). I have not stalled; I will report the result here the moment this step completes.

Developer reply from dev typosaurus ·

Internal infrastructure issue during research

The LLM backend is not responding correctly: the run timed out. This is an infrastructure problem, not a problem with this ticket. I will retry automatically (up to 3 times) and report the result here.

Developer reply from dev typosaurus ·

Progress update: research round 1 is still running (10 minutes elapsed). I have not stalled; I will report the result here the moment this step completes.

Developer reply from dev typosaurus ·

Progress update: research round 1 is still running (20 minutes elapsed). I have not stalled; I will report the result here the moment this step completes.

Developer reply from dev typosaurus ·

Progress update: research round 1 is still running (10 minutes elapsed). I have not stalled; I will report the result here the moment this step completes.

Developer reply from dev typosaurus ·

Progress update: research round 1 is still running (20 minutes elapsed). I have not stalled; I will report the result here the moment this step completes.

Developer reply from dev typosaurus ·

Progress update: research round 1 is still running (10 minutes elapsed). I have not stalled; I will report the result here the moment this step completes.

Developer reply from dev typosaurus ·

I am picking this ticket up now.

First I will bring up an isolated workspace with a fresh checkout and investigate whether the ticket matches the current state of the code before planning any change. I will announce every step here before I take it.

Developer reply from dev typosaurus ·

I need input to continue.

What I tried: Retried this step 3 times.
What I found: Each attempt failed for internal reasons unrelated to this ticket. The details are in the operator's logs; this is not a judgment about the ticket.

The system needs operator attention before I can continue. Reply here once things are healthy and I will resume from where I left off.

Developer reply from dev typosaurus ·

I am picking this ticket up now.

First I will bring up an isolated workspace with a fresh checkout and investigate whether the ticket matches the current state of the code before planning any change. I will announce every step here before I take it.

Developer reply from dev typosaurus ·

Starting research round 1 of at most 5.

I am now reading the relevant source, tests, and prior work in the live checkout to verify the ticket and gather the context needed for a concrete plan. This can take a while; I will post periodic progress updates until it completes.

Developer reply from dev typosaurus ·

Investigated the ticket against the current source and tests. The custom /docs system does not convey nullability information for response fields, even though the underlying Pydantic schemas correctly define Optional fields and the OpenAPI output already handles this. The reporter's core requirement-adding nullable annotations to the API definition in /docs-is actionable; the minor field‑name discrepancy (modified_at vs updated_at) does not change the substance of the request.

Decision is to proceed. Next step is drafting a concrete implementation plan.

Developer reply from dev typosaurus ·

I am drafting the implementation plan now.

The research confirmed the ticket; I am turning the findings into a concrete, verifiable plan.

Developer reply from dev typosaurus ·

The investigation findings have been synthesized into a comprehensive implementation plan for adding nullable annotations to the custom /docs API definition. This plan addresses the modifications needed across the Python backend, the JavaScript frontend, and the test suite, with clear step-by-step instructions and a definition of done.

The plan is now ready for the execution agent to begin implementation. Once completed, the agent should verify all checklist items pass and confirm no regression in the e2e tests, as previously established.

Developer reply from dev typosaurus ·

The full, verbatim implementation plan is attached: plan-ticket-111.md

Developer reply from dev typosaurus ·

Starting implementation attempt 1 of at most 5.

I am executing the plan inside this ticket's isolated workspace. This can take a while; I will post periodic progress updates until it completes.

Developer reply from dev typosaurus ·

Progress update: implementation attempt 1 is still running (10 minutes elapsed). I have not stalled; I will report the result here the moment this step completes.

Developer reply from dev typosaurus ·

Implementation attempt 1 finished; I am verifying it now.

Running the project's own build, test, and lint commands against the change.

Developer reply from dev typosaurus ·

The change was implemented on the first attempt, with the project's own build, test, and lint commands all completing successfully. The next step is to commit the work, push the branch, and open a pull request for review.

Developer reply from dev typosaurus ·

I am delivering the change now.

Committing the verified change, pushing branch typosaurus/ticket-111, and opening a pull request.

Developer reply from dev typosaurus ·

The implementation for ticket-111 has been committed and pushed to branch typosaurus/ticket-111. A pull request has been opened at https://retoor.molodetz.nl/retoor/devplacepy/pulls/126.

This action was taken after the implementation passed the project's own checks.

I am now monitoring the pull request for review, merge, or further feedback.

Log in to comment.