Skip to the content.

Feedback module — setup & operations

The Feedback module lets users rate a module, report a bug or ask for a feature from inside the app. There is no backend of our own: submissions go straight into a Firebase Firestore collection, which is free (Spark plan, no card) and needs nothing running.

This page is for the maintainer. Users need none of it.

The module is gated on a logged-in character

With an empty character roster the module is inactive: the sidebar and the ⌘K palette leave it out, its page says “Module inactive — registered account required”, and feedback_submit refuses. Feedback is tied to a character so a report can be answered by EVE mail, and so the corpus isn’t open to anyone who merely downloaded the binary.

Gating is declared in the registry (requiresCharacter: true on the module entry) and applied by useAvailableModules(), which both nav surfaces build from. The route still exists either way — that is what a direct link or a restored “last visited” lands on, which is why the page states the reason itself rather than relying on being unreachable.

The privacy posture, stated plainly

Because users cannot read their submissions back, the app keeps a local mirror of what each install sent, purely for their own reference.

One-time Firebase setup

  1. Create a project at https://console.firebase.google.com. Stay on the Spark (free) plan — no billing account is needed, because we never use Cloud Functions.
  2. Authentication → Sign-in method → Anonymous → Enable. Every submission is attributed to an anonymous account, which is what gives an install a stable uid across restarts.
  3. Firestore Database → Create database → Native mode. Pick a region near most users; it cannot be changed later.
  4. Deploy the rules in firestore.rules — either paste them into the console’s Rules tab, or run firebase deploy --only firestore:rules --project <project id> from the repo root (the committed firebase.json points the CLI at firestore.rules). Do not skip this. The rules are the entire access model; the console’s default template allows far more than we want.
  5. Project settings → General → Your apps → Web app. Note the Project ID and the Web API key.

Is shipping the API key safe?

Yes, and it is unavoidable for a client-only design. A Firebase web API key identifies a project; it is not a credential, and Google documents it as publishable. It grants exactly what the security rules allow — here, “create one well-formed feedback document, attributed to your own anonymous account, and nothing else.” Anyone who unzips a release can extract it and write to the collection, so the rules do the real work: a field allowlist, an enum on kind, length caps, and uid == request.auth.uid.

There is no App Check option for a desktop app (its attestation providers are web/iOS/Android only). If the collection is ever abused in volume, the escape hatch is to put a Cloudflare Worker in front and ship a new endpoint.

Worth doing anyway: in the Google Cloud console, APIs & Services → Credentials → the browser key → API restrictions, limit the key to the Identity Toolkit API and Cloud Firestore API. It can’t stop someone writing feedback (the rules handle that), but it stops an extracted key being used against any other Google API enabled on the project.

Build-time configuration

The project id and API key are baked in at compile time:

EVE_TOOLING_FIREBASE_PROJECT_ID=your-project-id \
EVE_TOOLING_FIREBASE_API_KEY=AIza... \
  npm run tauri build

A local build without them is fine — feedback_status reports configured: false, the send button is disabled, and the UI offers the prefilled GitHub-issue route instead. That is what dev builds do by default, so local development never writes to the real collection. (Release builds are a different matter — see below.)

Local dev via .env

To exercise the real endpoint from npm run tauri dev without prefixing every command, copy .env.example to .env at the repo root and fill in the two keys:

cp .env.example .env
# then edit .env:
#   EVE_TOOLING_FIREBASE_PROJECT_ID=your-project-id
#   EVE_TOOLING_FIREBASE_API_KEY=AIza...

.env is git-ignored, so this stays a local, opt-in choice — a checkout with no .env still reports configured: false. src-tauri/build.rs loads it at compile time; a real environment variable of the same name overrides it, so CI is unaffected. Editing .env triggers a rebuild on the next tauri dev. Only those two keys are read — the Rust client speaks Firebase’s REST API directly and needs nothing else from a Firebase web config.

Test submissions land in the real feedback collection; delete them from the Firestore console (or use a throwaway project) if you’d rather not mix them with genuine feedback.

In CI

.github/workflows/release.yml passes both to tauri-action from repository secrets of the same names:

Secret Value
EVE_TOOLING_FIREBASE_PROJECT_ID the Firebase project id
EVE_TOOLING_FIREBASE_API_KEY the Firebase web API key

Set them under Settings → Secrets and variables → Actions, as Repository secrets — not Environment secrets. $ only resolves environment secrets for a job that declares an environment: key, and no job here does; an environment secret would arrive as an empty string.

A release fails if either is missing. The Require build config secrets step runs in each build-matrix leg of release.yml, before that leg builds anything, so each leg stops in seconds with an explicit error naming the missing secret. The alternative was worse: an empty secret builds perfectly and the only symptom is that no feedback ever arrives. A consequence worth knowing — a fork cannot run the release workflow without setting its own two secrets.

ci.yml deliberately does not set them, and is not gated: test runs must never write into the real collection.

Note src-tauri/build.rs emits cargo:rerun-if-env-changed for both and also loads the git-ignored .env described above. Cargo doesn’t track option_env! on its own, and CI restores a warm target cache — without that, a build could reuse an object file compiled before the variables existed and silently ship with feedback disabled.

Reading the corpus

Reading needs a service account, whose key bypasses security rules by design — keep it off the repo and out of any build.

  1. Project settings → Service accounts → Generate new private key. Save the JSON somewhere private (.local/ in this repo is git-ignored).
  2. Pull:

    GOOGLE_APPLICATION_CREDENTIALS=.local/service-account.json npm run feedback:pull
    

This writes two git-ignored files:

File What it is
.local/feedback.json Every submission, newest first — the machine-readable copy
.local/feedback.md A digest grouped by module and kind, with per-module average ratings

feedback.md is the one to skim, and the one to hand an agent when asking for a triage pass (“read .local/feedback.md, group the bugs by likely cause, propose issues”). Submissions are written by anyone holding the public web API key, so the script escapes table cells, fences every body as inert text and opens the digest with an untrusted user content banner; keep it that way when editing the script, and tell the agent to treat the content as data. The script has no dependencies — the service-account OAuth exchange is a signed JWT that node:crypto handles.

Each record carries Firestore’s own createTime as createdAt. That timestamp is server-side, so unlike a client-supplied one it cannot be forged or backdated — which is why the client sends no timestamp at all.

Reading the corpus in the app (maintainer account)

feedback-pull.mjs is the offline route. For reading the same corpus inside the app, the issue-board plugin (“Issues & Ratings”) has an In-app feedback panel: every submission with its kind, module, stars, text, character and app version, plus the star distribution and the lowest-rated modules. It reads Firestore over REST, from the plugin’s WASM sandbox, with no service account anywhere near it.

That needs exactly one identity to be allowed to read, and firestore.rules grants it to an Email/Password account you create for yourself:

  1. Authentication → Sign-in method → Email/Password → Enable. (Anonymous stays enabled; submissions still use it.)
  2. Authentication → Users → Add user. Use an address you control, then verify it — the rule requires email_verified, so an unverified account is refused like any other client.
  3. In firestore.rules, put that address in maintainers() (replacing the address already listed, if it isn’t yours), and deploy: firebase deploy --only firestore:rules --project <project id>.
  4. In the app: Plugins → activate Issues & Ratings → its Settings → fill in the project id, the web API key (the same one the build uses), and that account’s email and password. The panel switches on; leave any of them blank and it stays off.

What this does not change: no other client can read the corpus. Users still cannot read their own submissions back, the app itself cannot, and anybody who extracts the shipped API key gets an anonymous account, which carries no email and therefore never matches maintainers(). update and delete remain denied to every client including you — deletion is still a Firestore console action.

The credentials live in that plugin’s private key/value store (<app_data_dir>/plugins/issue-board/kv/), are never handed back over the plugin bridge, and leave the machine only as the body of one accounts:signInWithPassword call and the bearer token on the Firestore read. Running the plugin on a machine you don’t control means putting a password that can read the whole corpus on it — use the offline pull there instead.

Marking submissions read

The panel tracks which submissions you have already read: unread rows are bold with a dot, opening one marks it read, the dot toggles it back, and Mark all read clears whatever the current filters show.

That state is not stored in the submissions — feedback documents stay immutable (update, delete: if false). It lives in a separate feedbackState/{submissionId} collection holding one field, readAt, which only the maintainer can read or write:

match /feedbackState/{submission} {
  allow read, write: if isMaintainer() && isWellFormedState();
}

So the flags follow your account rather than the machine — read something on the desktop and it is read on the laptop. Marking is one batched documents:commit, so “mark all read” over hundreds of rows is a single request that either lands entirely or not at all. Unread is simply the absence of a document, so the collection only ever holds what was actually read, and deleting it resets everything to unread.

Replying to a reporter

A submission that carries a character name can be answered with an in-game EVE mail, sent manually from your own client — the reporter picked that character precisely so you could. This deliberately needs no extra ESI scope from the user: EVE exposes no email address through ESI at all, and sending mail as the user would require a esi-mail.send_mail.v1 token from them, which would be backwards.

Deleting a submission on request

Users cannot delete their own submissions (the rules deny delete to every client), so a request comes to you. They can quote the document id shown after sending, or the app’s local history. Delete the document in the Firestore console.

If it gets spammed

In rough order of effort:

  1. Delete the junk in the console.
  2. Tighten firestore.rules — shorter caps, or a stricter module check.
  3. Rotate to a new Firebase project and ship a release pointing at it.
  4. Move the write path behind a Cloudflare Worker that can rate-limit by IP.

The client already throttles itself (30s between submissions, 20 per rolling day per install), but that is a courtesy to honest users, not a defence — a hostile client simply won’t run our code.