Skip to content

Adds hybrid_cloud_rpc skill to claude config#108548

Open
GabeVillalobos wants to merge 4 commits intomasterfrom
gv/promptless-slug-fix
Open

Adds hybrid_cloud_rpc skill to claude config#108548
GabeVillalobos wants to merge 4 commits intomasterfrom
gv/promptless-slug-fix

Conversation

@GabeVillalobos
Copy link
Member

@GabeVillalobos GabeVillalobos commented Feb 19, 2026

Adds skills to handle creation, modification, and deprecation of Hybrid Cloud RPC services. It includes background for:

  • Service definitions and registration
  • Silo designation and region resolution strategies
  • RPC data modeling and error propagation
  • Safe method modifications and deprecations
  • Testing methodology and guidance

As configured, the skills will guide a developer through most of these processes with granular prompts, and does a reasonable job implementing a coarse first pass. To see an example, check the stubs generated here: #108571

@GabeVillalobos GabeVillalobos changed the title gv/hc-rpc-skill Adds hybrid_cloud_rpc skill to claude config Feb 19, 2026
@GabeVillalobos GabeVillalobos requested review from a team February 19, 2026 21:02
Comment on lines +58 to +65
### When to use `repr=False`

| Field type | Examples | Why hide it |
| --------------------------- | -------------------------------------------------- | --------------------------------------------- |
| **Secrets & credentials** | tokens, hashed passwords, API keys, client secrets | Prevents leaking secrets into logs |
| **Opaque blobs** | `config`, `metadata`, `extra_data` dicts | Noisy in logs, may contain PII or credentials |
| **Session/auth material** | session nonces, OAuth tokens | Security-sensitive |
| **Request/response bodies** | headers, payloads | May contain auth headers or PII |
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was a manual addition. Adding this to sensitive fields should now be the norm.

Comment on lines +35 to +37
class Config:
orm_mode = True
use_enum_values = True
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think it should be standard practice to include a config in every RPCModel, so I do wonder if we actually need this portion. If we do, maybe we need another decision tree to guide a user through setting these whenever appropriate.

Comment on lines +218 to +219
### 7.1 Silo mode compatibility with `@all_silo_test`

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was an opinionated piece I added to cover comprehensive testing, at minimum at the service level. It's something we didn't historically do, but I've found it more helpful than not.

Comment on lines +393 to +395
Test that any calling code (both direct and indirect) is also appropriately
tested with the correct silo decorators.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was the second manually added chunk that finally got the code generation to respect error propagation.

Comment on lines 162 to 181
### Error propagation

All errors an RPC method propagates must be done via the return type. Errors are
rewrapped and returned as generic Invalid service request to external callers.

```python
class RpcTentativeResult(RpcModel):
success: bool
error_str: str | None
result: str | None

class DatabaseBackedMyuService(MyService):
def foobar(self, *, organization_id: int) -> RpcTentativeResult
try:
some_function_call()
except e:
return RpcTentativeResult(success=False, error_str = str(e))

return RpcTentativeResult(success=True, result="foobar")
```
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was all manual, and mostly an opinionated take on how error handling at the RPC level should be done.

@GabeVillalobos GabeVillalobos marked this pull request as ready for review February 19, 2026 21:21
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

Comments