Skip to content

Harden API retries, fix placement-default persistence, add CI (v0.3.1) - #1

Merged
QROST merged 2 commits into
mainfrom
claude/modest-fermat-jtqzbl
Jun 22, 2026
Merged

QROST merged 2 commits into
mainfrom
claude/modest-fermat-jtqzbl

Conversation

@QROST

@QROST QROST commented Jun 22, 2026

Copy link
Copy Markdown
Owner

Summary

A correctness and robustness pass over the plugin. No behavioural changes to the happy path; the focus is on making failures recoverable, fixing a settings bug, and adding a build safety net.

Changes

Bug fixes

  • Default placement was silently discarded. MeshySettings.DefaultPlacement was read on launch (ApplyDefaults) but the Settings window never wrote it back — every Save reset it to "mesh". It is now a first-class setting with its own Placement (OBJ mode) dropdown, loaded and persisted alongside the other defaults.
  • Empty texture_prompt was sent on refine. An empty box now omits the field (NullValueHandling.Ignore + empty→null) instead of POSTing "".

Robustness

  • Transient-only retries. Introduced MeshyApiException carrying the HTTP status code. WithRetryAsync now retries only transient failures — network errors, request timeouts (TaskCanceledException, which the previous HttpRequestException-only filter never caught), and 429/5xx. Permanent 4xx errors (invalid key, bad request, insufficient credits) now fail fast instead of burning the retry budget on a request that can't succeed.
  • Resilient polling. PollUntilCompleteAsync tolerates transient status-GET failures (up to the configured retry count) so a momentary blip mid-generation no longer kills a job that may be nearly complete. User cancellation and server-side FAILED/CANCELED still abort immediately.

Tooling / housekeeping

  • CI workflow (.github/workflows/ci.yml) builds Debug + Release on every push and PR — previously the project only built on a release tag.
  • Version bump to 0.3.1; changelog and settings docs updated.

Notes

  • This project targets net7.0-windows (WPF + RhinoCommon), so it only compiles on Windows; CI added here will exercise the build on windows-latest. It could not be compiled in the authoring environment — changes were made conservatively and reviewed by reading.

🤖 Generated with Claude Code

https://claude.ai/code/session_013GAR8kCUgxbPYWNtyqyCE8


Generated by Claude Code

claude added 2 commits June 22, 2026 04:37
Robustness and correctness pass:

- Retry only transient failures. Introduce MeshyApiException carrying the
  HTTP status code; WithRetryAsync now retries network errors, request
  timeouts (TaskCanceledException), and 429/5xx responses, while permanent
  4xx errors (invalid key, bad request, insufficient credits) fail fast
  instead of wasting the retry budget.
- Resilient polling. PollUntilCompleteAsync tolerates transient status-GET
  failures (retrying up to the configured count) so a momentary network
  blip no longer aborts an in-progress generation.
- Fix orphaned default placement. The settings window dropped
  DefaultPlacement on every save; it is now a first-class setting with its
  own dropdown, loaded and persisted alongside the other defaults.
- Omit empty texture_prompt from the refine request instead of sending an
  empty string.
- Add a CI workflow that builds Debug and Release on every push and PR.
- Bump version to 0.3.1 and update the changelog.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013GAR8kCUgxbPYWNtyqyCE8
Defensive fixes from a codebase audit:

- Validate task-creation responses: throw a clear error if the API body
  is missing the task ID instead of risking a NullReferenceException.
- Guard against a null task status while polling.
- Route OBJ/byte downloads through EnsureSuccessAsync so CDN failures are
  classified like API calls -- an expired (4xx) presigned URL now fails
  fast, while 5xx/timeouts remain retryable.
- Log thumbnail load failures to the Rhino command line instead of
  swallowing them silently.
- release.yml: verify MeshyRhino.dll and Newtonsoft.Json.dll are present
  in the build output before packaging, so a missing runtime dependency
  fails the release rather than shipping a broken plugin.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013GAR8kCUgxbPYWNtyqyCE8
@QROST
QROST marked this pull request as ready for review June 22, 2026 05:31
@QROST
QROST merged commit 1bd46f7 into main Jun 22, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants