Skip to content

✨ add generic platform credential operations#4

Merged
luoshuijs merged 7 commits intomainfrom
feature/platform-mihomo-binding-aware-credentials
Apr 19, 2026
Merged

✨ add generic platform credential operations#4
luoshuijs merged 7 commits intomainfrom
feature/platform-mihomo-binding-aware-credentials

Conversation

@luoshuijs
Copy link
Copy Markdown
Contributor

Summary

  • implement generic platform credential put, refresh, and delete RPCs on mihomo service
  • tighten binding-aware ticket validation, scope enforcement, and transactional rebind behavior
  • support account-center orchestration through the shared platform contract instead of service-local assumptions

Test Plan

  • go test ./...

Signed-off-by: luoshui <luoshuijs@outlook.com>
Signed-off-by: luoshui <luoshuijs@outlook.com>
Signed-off-by: luoshui <luoshuijs@outlook.com>
Serve binding-aware generic credential mutation RPCs and tighten ticket scope enforcement so execution-plane updates stay safe and reusable by account-center orchestration.

Signed-off-by: luoshui <luoshuijs@outlook.com>
Track the shared platform credential RPC contract from proto-contracts so CI can build the generic service implementation without local workspace wiring.

Signed-off-by: luoshui <luoshuijs@outlook.com>
Resolve merge conflicts by keeping the binding-aware credential implementation and rerun tests on the merged result.

Signed-off-by: luoshui <luoshuijs@outlook.com>
@codecov
Copy link
Copy Markdown

codecov Bot commented Apr 19, 2026

Codecov Report

❌ Patch coverage is 54.82456% with 103 lines in your changes missing coverage. Please review.
✅ Project coverage is 27.52%. Comparing base (6dede6f) to head (ec10438).
⚠️ Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
internal/service/platform_service_adapter.go 35.05% 47 Missing and 16 partials ⚠️
internal/usecase/management_usecase.go 64.28% 6 Missing and 4 partials ⚠️
internal/usecase/bind_usecase.go 83.92% 5 Missing and 4 partials ⚠️
internal/data/credential_repo.go 12.50% 6 Missing and 1 partial ⚠️
internal/data/profile_repo.go 16.66% 4 Missing and 1 partial ⚠️
internal/data/tx_context.go 33.33% 3 Missing and 1 partial ⚠️
internal/data/device_repo.go 0.00% 3 Missing ⚠️
cmd/platform-mihomo-service/main.go 0.00% 1 Missing ⚠️
internal/usecase/scope_guard.go 75.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main       #4      +/-   ##
==========================================
+ Coverage   25.52%   27.52%   +2.00%     
==========================================
  Files          24       25       +1     
  Lines        2547     2728     +181     
==========================================
+ Hits          650      751     +101     
- Misses       1798     1859      +61     
- Partials       99      118      +19     
Flag Coverage Δ
unit 27.52% <54.82%> (+2.00%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

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

@luoshuijs luoshuijs merged commit 8d853bb into main Apr 19, 2026
4 checks passed
@luoshuijs luoshuijs deleted the feature/platform-mihomo-binding-aware-credentials branch April 19, 2026 08:03
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.

1 participant