Skip to content

refactor: remove Managed field from interface and route APIs#359

Merged
retr0h merged 1 commit intomainfrom
refactor/remove-managed-field
Apr 8, 2026
Merged

refactor: remove Managed field from interface and route APIs#359
retr0h merged 1 commit intomainfrom
refactor/remove-managed-field

Conversation

@retr0h
Copy link
Copy Markdown
Collaborator

@retr0h retr0h commented Apr 8, 2026

Summary

  • Remove the Managed boolean field from interface and route list/get responses across all layers (provider, OpenAPI spec, handler, SDK, CLI, docs)
  • Remove scanManagedInterfaces() and loadManagedRoutes() functions that populated the field
  • Remove UID >= 1000 filter from user ListUsers so all accounts are returned
  • Update CLI output examples and SDK docs to reflect the removal

Operations are idempotent and work on any resource regardless of whether osapi created it. The osapi- file prefix already guards mutations — the Managed field added noise without value.

Test plan

  • All unit tests pass (just go::unit)
  • Lint clean (just go::vet)
  • Build clean (go build ./...)
  • OpenAPI specs regenerated (just generate)
  • SDK client regenerated (go generate ./pkg/sdk/client/gen/...)
  • Verify CLI output no longer shows MANAGED column
  • Verify JSON responses no longer include managed field

🤖 Generated with Claude Code

Operations are idempotent and work on any resource regardless of
whether osapi created it. The Managed boolean added noise without
value — the osapi- file prefix already guards mutations.

Also removes the UID >= 1000 filter from user ListUsers so all
system accounts are returned.

🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
@codecov
Copy link
Copy Markdown

codecov bot commented Apr 8, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #359      +/-   ##
==========================================
- Coverage   99.92%   99.91%   -0.01%     
==========================================
  Files         469      469              
  Lines       23814    23728      -86     
==========================================
- Hits        23795    23708      -87     
- Misses         11       12       +1     
  Partials        8        8              
Files with missing lines Coverage Δ
...ernal/controller/api/node/network/interface_get.go 100.00% <ø> (ø)
.../controller/api/node/network/interface_list_get.go 100.00% <ø> (ø)
...rnal/controller/api/node/network/route_list_get.go 100.00% <ø> (ø)
...ternal/provider/network/netplan/iface/interface.go 99.43% <100.00%> (-0.57%) ⬇️
internal/provider/network/netplan/route/route.go 100.00% <ø> (ø)
internal/provider/node/user/debian_user.go 100.00% <ø> (ø)
pkg/sdk/client/interface_types.go 100.00% <ø> (ø)
pkg/sdk/client/route_types.go 100.00% <ø> (ø)

Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 01c140e...550b4c9. Read the comment docs.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@retr0h retr0h merged commit 68a1632 into main Apr 8, 2026
11 checks passed
@retr0h retr0h deleted the refactor/remove-managed-field branch April 8, 2026 00:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant