Commit Graph
14 Commits
Author SHA1 Message Date
adamfandClaude Opus 5.5 71344a1f8d Declare GraphQL auth in the schema and drop the Go Claude client
Authorisation: @admin and @signedIn schema directives replace the 25
hand-copied resolver checks. A test fails if a mutation has neither and
is not on the public allow-list, so a new mutation cannot ship unguarded.

IDs: uint model IDs bind through graphql.UintID, removing the ten
int(obj.ID) resolvers.

Job status is a GraphQL enum, tied to services.statusOrder by a test.
Input is strict, so the mutations no longer coerce an unknown status to
"applied"; output is lenient so one legacy row cannot fail the list.

deleteJobApplication and deleteJobAppReference now error on a missing id
like the other deletes.

The rowing reader, the job extractor and now the email classifier reach
the Python service through one services.CallPython helper. The email
pipeline's prompt and fence stripping moved to Python, and
anthropic-sdk-go is gone from go.mod.

Fix the auth test fixture, whose 11-byte secret had been panicking the
services test package since InitAuth began requiring 32 bytes. Add a
test that keeps the python service's compose environment list in step
with the env registry.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-12 14:39:19 +01:00
adamfandClaude Opus 5.5 b8670246a8 Add browser job capture to the job tracker
Deploy with Docker Compose / deploy (push) Successful in 1m31s
A Violentmonkey userscript, served by the site and installed from /cv/jobs,
adds the posting open in the browser (LinkedIn, an ATS, any company page) to
the tracker. Claude reads the title, company and location off the page text.

- Three token-guarded REST routes under /api/jobs/capture (status, extract,
  upsert). They take a bearer token, JOB_CAPTURE_TOKEN, because the auth
  cookies are SameSite=Lax and never sent from another origin. An unset token
  switches the routes off.
- The upsert matches on a canonical posting URL, then (company, job title),
  so a capture and the email pipeline do not make two rows for one job.
- The Claude call is a new internal Python route, /internal/jobs/extract,
  alongside the rowing reader; the client and fence stripping they share move
  to python/app/claude.py.
- New "saved" status ranked below "applied", and a description column holding
  the posting text, shown per row on the tracker.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-12 13:33:28 +01:00
adamfandClaude Code ff186f04a7 Spotify unauthenticated: throttled log + admin reconnect on Listening widget
Deploy with Docker Compose / deploy (push) Successful in 40s
- Backend logs a rate-limited (1/h) "not authenticated" line when a resolver
  finds the Spotify client nil instead of silently degrading to null.
- New public-but-gated spotifyNeedsReauth query: false for everyone except
  an admin session whose backend has no client.
- The /stp Listening widget offers admins a "Reconnect Spotify" button that
  hits /api/spotify/auth and navigates to the returned authorisation URL;
  non-admins still see the widget degrade as before.

Co-Authored-By: Claude Code <[email protected]>
2026-09-22 22:54:48 +01:00
adamfandClaude Opus 5 64df70e5d2 Document codebase: comments, per-area READMEs, deployment guide
Readability pass across all four areas of the stack. Comments explain why
rather than what, concentrated at the points where behaviour is non-obvious:
concurrency, caching, auth, scraping and nginx templating.

Backend: doc comments on every exported declaration across handlers,
services, models and resolvers. Resolver commentary lives inside function
bodies so gqlgen does not strip it on regeneration; schema files use #
comments rather than description blocks so introspection output is
unchanged. Extracted the duplicated auth-cookie blocks into helpers.

Frontend: header comments on every component, store and view, including
STATUS: notes marking which of the parallel/legacy views are still live.
Documented the non-reactive animation-state pattern, the homeData hub and
the WebSocket stale-socket guard. Removed a few dead imports and named the
reconnect-backoff and poll-interval constants.

Python: module and function docstrings covering the Travelodge scraping
contract, the deadline threading, the two-executor concurrency and the
NDJSON streaming protocol.

Infra: header blocks on every compose file, nginx template, Dockerfile and
entrypoint, covering the config selection, envsubst allow-lists, rate-limit
semantics and volume persistence. Hoisted the duplicated envsubst variable
list in nginx/entrypoint.sh.

New: backend/README.md, python/README.md, DEPLOYMENT.md, .env.example,
backend/graph/doc.go. Refreshed vue/README.md. Corrected CLAUDE.md, which
stated a 24h access token where main.go sets 7 days.

No behaviour change. go build/vet, vite build, py_compile and docker
compose config all pass.

Co-Authored-By: Claude Opus 5 <[email protected]>
2026-09-16 15:57:48 +01:00
adamfandClaude Fable 5.1 6037729edd Add admin-only private chat messages and message deletion
Deploy with Docker Compose / deploy (push) Successful in 58s
Admins can flag a chat message as private so only other admin
connections receive it, and can delete any message. Admin status is
read from the auth cookies on the WebSocket upgrade request.

Co-Authored-By: Claude Fable 5.1 <[email protected]>
2026-09-16 15:22:26 +01:00
adamfandClaude Opus 5 894c158afd Add places / things-to-do list with admin management
Deploy with Docker Compose / deploy (push) Successful in 16m21s
Backend: new Place GORM model (title, location, notes, image, category,
cost, priority, done) with auto-migration, a place.graphql schema, and
resolvers for the places query plus admin-only create/update/delete.
Regenerate gqlgen output against gqlgen v0.17.95, which requires Go 1.26 —
bump go.mod and the builder image to match.

Frontend: a places Pinia store, a CreatePlace admin form, and a
PlacesTable rendered as a new tab in the Collage cell, with inline
done-toggle and delete for admins. Rework the Admin page into a
sidebar-navigated panel layout (picking up the previously unreachable
CreateBookmark form) and give Login proper field labels, submit state,
and error feedback.

Co-Authored-By: Claude Opus 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01KcFtkisHcKJuTZAnv3fVzA
2026-09-12 18:10:41 +01:00
adamfandClaude Opus 4.6 b96b7d7a93 Split schema.graphql and schema.resolvers.go into per-domain files
Deploy with Docker Compose / deploy (push) Successful in 3m36s
Move Query/Mutation field declarations from the monolithic schema.graphql
into each domain's .graphql file using extend type, so gqlgen places
resolvers in the matching *.resolvers.go files. Extract helper functions
into *_helpers.go files to prevent gqlgen from commenting them out.

Co-Authored-By: Claude Opus 4.6 <[email protected]>
2026-04-15 18:57:23 +01:00
adamfandClaude Opus 4.6 759614e92d Add job application quick reference for storing profile links and experience
Deploy with Docker Compose / deploy (push) Successful in 3m34s
Auth-protected CRUD for personal info (LinkedIn, GitHub, etc.) and
experience entries, stored in the database so nothing sensitive is in
the public repo. Displayed as a categorized panel on the Job Applications page.

Co-Authored-By: Claude Opus 4.6 <[email protected]>
2026-04-13 12:38:53 +01:00
adamfandClaude Sonnet 4.6 66f32cdbd2 Add database-backed bookmarks via GraphQL
Deploy with Docker Compose / deploy (push) Successful in 3m47s
Replace hardcoded bookmarks in the frontend with a GORM-backed Bookmark
model exposed through GraphQL query and admin-only create/delete mutations.
Frontend groups bookmarks by category dynamically from the store.

Co-Authored-By: Claude Sonnet 4.6 <[email protected]>
2026-04-13 12:04:13 +01:00
adamfandClaude Sonnet 4.6 8f3c369ed8 Add job application tracker (admin-only)
Deploy with Docker Compose / deploy (push) Has been cancelled
Full CRUD GraphQL API for tracking job applications with status workflow.
Frontend component in CV view, hidden from print. Login now redirects to
intended route after auth via query param.

Co-Authored-By: Claude Sonnet 4.6 <[email protected]>
2026-04-13 09:51:31 +01:00
adamfandClaude Opus 4.6 264df132df Add Steam integration showing online status and recent games
Deploy with Docker Compose / deploy (push) Has been cancelled
Fetches player summary and recently played games from Steam API with
5-minute server-side caching. Displays in the home sidebar with online
indicator and game artwork.

Co-Authored-By: Claude Opus 4.6 <[email protected]>
2026-03-26 01:59:34 +00:00
adamfandClaude Opus 4.6 7a737f6d10 Handle missing Spotify auth gracefully instead of returning errors
Deploy with Docker Compose / deploy (push) Successful in 3m42s
Return nil/empty results when Spotify client is not authenticated,
preventing GraphQL errors from breaking the home page data query.

Co-Authored-By: Claude Opus 4.6 <[email protected]>
2026-03-25 17:02:11 +00:00
adamfandClaude Sonnet 4.6 7381cda7b8 Move Gitea feed from frontend to backend with cached GraphQL proxy
Deploy with Docker Compose / deploy (push) Successful in 4m39s
Replaces direct browser-to-Gitea API calls with a backend service that
proxies and caches the feed (1-min TTL), served via the existing GraphQL
HomeData query. Commit message parsing now happens server-side.

Co-Authored-By: Claude Sonnet 4.6 <[email protected]>
2026-03-17 00:14:59 +00:00
adamfandClaude Opus 4.6 0360b1f7f1 Consolidate frontend REST calls with GraphQL
Deploy with Docker Compose / deploy (push) Failing after 1s
Replace 5 separate REST calls on home page load with a single GraphQL
query. Add homeData store that fetches posts, favorites, activities,
spotify, and auth in one request. Convert all admin mutations and
auth flows to use GraphQL. Add album images to Spotify GraphQL schema.

Co-Authored-By: Claude Opus 4.6 <[email protected]>
2026-03-16 15:29:22 +00:00