Getting started with contributions

I was inspired by the anniversary call last week to finally start contributing to Smoke Signal. I was hoping to contribute a couple simple UX improvements, and since I’ve been writing Rust since just before v1.0 so I imagine I should be able to dive in. However, I’m not able to get the project to build. I spent several hours on Friday trying to figure out Dev Containers (I’d heard of them, but never used them since I’m not a VSCode user) and finally got those working on Saturday using DevPods. Hilariously I started working on a merge request to update the README with everything I’d gotten to work so far, but @ngerakines had already updated it in the meantime.

The error I’m currently getting is with the JWK. The README suggests running cargo run --bin crypto -- jwk, but that command doesn’t appear to do anything nor is it present in the code in src/bin/crypto.rs. There is no error since that function is using an if statement without an else.

Even if I rename the keys.example.json, it still doesn’t compile. I’ve also noticed that the string in .vscode/launch.example.json file doesn’t match what the README suggests should be a path.

I’m more than happy to make an MR when I can get it running, but I could use some guidance. I have tried using VSCode and RustRover in addition to my normal Neovim setup, so I’m fairly certain it’s not me being an IDE Luddite. I also asked another colleague if it worked on their machine, and they didn’t get any further than I did.

The error I get is related to atproto-identity::key::identify_key() I believe:

2025-07-28T18:24:05.501440Z ERROR smokesignal::config: failed to identify key, err: DecodeError { error: UnknownBase('e')
}, private_key: "{{ truncated key }}"
    at src/config.rs:331

Error: error-smokesignal-config-4 Signing keys must contain at least one valid key

I wasn’t sure if this should be an issue or a thread on discourse. I’m happy to delete this and open it in the issue tracker if you think it would fit better over there.

3 Likes

Welcome @pinkhatbeard thanks for diving in!

Discourse forum is a pretty nice space for long form writing and ideally gets us comfy for a wider range of early adopters and contributors than just devs. We’ll see what Nick has to say!

Oof, this is embarrassing. The readme file is out of date. I’m going to update it right now. Stay tuned.

1 Like

I’ve updated the README.md file and example vscode launch config in 2291c3bb.

The tl;dr is that you can (should) use goat key generate -t p256 to generate secret key material.

Took me a minute to figure out which goat was being referred to. Maybe that’s something most AT Proto devs already have, but I did not. I also don’t do a lot of Go, so I wasn’t sure where the binary even installed.

Once I was able to generate keys, it still wasn’t clear where they go. My first attempt resulted in another error. This is what ended up working, but I’m not clear if that’ what was entended:

│❯ ~/go/bin/goat key generate -t p256                                                                                       │
│Key Type: P-256 / secp256r1 / ES256 private key                                                                            │
│Secret Key (Multibase Syntax): save this securely (eg, add to password manager)                                            │
│        <SOME_SECRET_KEY>                                                                  │
│Public Key (DID Key Syntax): share or publish this (eg, in DID document)                                                   │
│        did:key:<SOME_PUBLIC_DID>

I then used (using direnv)

export SIGNING_KEYS=did:key:<SOME_SECRET_KEY>
export SERVICE_KEY=did:key:<SOME_PUBLIC_DID>

Was that correct?

I’m now getting a new error which I believe is caused by Postgres not being available. I’m going to destroy and rebuild the DevContainer and see if that fixes that. That could easily be on me since I’ve been learning how those work at the same time.

Once we get my stuff working, I’m positive we can automate and document all of this so it doesn’t happen to anyone else.

2 Likes

Looks right!

In the future if you enable any of the XRPC functionality, that service_key should also be a private key.