Skip to content

Commit b394a4c

Browse files
feat: Refined issue filters and search (Closes #815)
2 parents 50a93c6 + 4b4586d commit b394a4c

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

63 files changed

+3212
-885
lines changed

.github/workflows/ci.yml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -297,6 +297,9 @@ jobs:
297297
with:
298298
version: latest
299299

300+
- name: Generate config.toml from template
301+
run: cp supabase/config.toml.template supabase/config.toml
302+
300303
- name: Start Supabase (minimal services for migrations)
301304
run: |
302305
supabase start -x "studio,realtime,storage-api,edge-runtime,logflare,vector,imgproxy,supavisor,postgres-meta"
@@ -355,6 +358,9 @@ jobs:
355358
with:
356359
version: latest
357360

361+
- name: Generate config.toml from template
362+
run: cp supabase/config.toml.template supabase/config.toml
363+
358364
- name: Make Supabase integration script executable
359365
run: chmod +x ./scripts/run-supabase-integration-tests.sh ./scripts/supabase-init-for-tests.sh
360366

@@ -415,6 +421,9 @@ jobs:
415421
if: steps.playwright-cache.outputs.cache-hit != 'true'
416422
run: pnpm exec playwright install --with-deps chromium
417423

424+
- name: Generate config.toml from template
425+
run: cp supabase/config.toml.template supabase/config.toml
426+
418427
- name: Make E2E script executable
419428
run: chmod +x ./scripts/supabase-init-for-tests.sh
420429

@@ -486,6 +495,9 @@ jobs:
486495
if: steps.playwright-cache.outputs.cache-hit != 'true'
487496
run: pnpm exec playwright install --with-deps chromium
488497

498+
- name: Generate config.toml from template
499+
run: cp supabase/config.toml.template supabase/config.toml
500+
489501
- name: Make E2E script executable
490502
run: chmod +x ./scripts/supabase-init-for-tests.sh
491503

@@ -557,6 +569,9 @@ jobs:
557569
if: steps.playwright-cache.outputs.cache-hit != 'true'
558570
run: pnpm exec playwright install --with-deps chromium
559571

572+
- name: Generate config.toml from template
573+
run: cp supabase/config.toml.template supabase/config.toml
574+
560575
- name: Make E2E script executable
561576
run: chmod +x ./scripts/supabase-init-for-tests.sh
562577

@@ -631,6 +646,9 @@ jobs:
631646
if: steps.playwright-cache.outputs.cache-hit != 'true'
632647
run: pnpm exec playwright install webkit
633648

649+
- name: Generate config.toml from template
650+
run: cp supabase/config.toml.template supabase/config.toml
651+
634652
- name: Make E2E script executable
635653
run: chmod +x ./scripts/supabase-init-for-tests.sh
636654

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,8 @@ node_modules/
7979
supabase/.temp/
8080
supabase/.branches/
8181
supabase/config.toml.bak.*
82+
# Generated from config.toml.template (worktree-specific)
83+
supabase/config.toml
8284

8385
# Archived v1 test artifacts and build caches
8486
# (should have been ignored in v1, preventing future similar issues)

.jules/bolt.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,3 +7,8 @@
77

88
**Learning:** Independent DB queries in Server Components often default to serial execution (waterfall). Always wrap independent queries in `Promise.all`. Fetching large datasets just to count them (e.g. `array.length`) is an anti-pattern; use `count()` in SQL instead.
99
**Action:** Audit page loaders for serial `await` calls on independent data and replace array-based counting with SQL aggregation.
10+
11+
## 2025-02-14 - Composite Index Optimization
12+
13+
**Learning:** Replacing an index on `(A)` with `(A, B)` is a safe optimization when queries filter by `A` and sort by `B`. It allows the DB to fetch pre-sorted data, avoiding a sort operation, while still supporting lookups on `A`.
14+
**Action:** Always check if a frequently sorted column can be added to an existing filter index to create a composite index.

.jules/palette.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,3 +17,8 @@
1717

1818
**Learning:** When placing interactive elements (like `Select` or `Button`) inside data tables, relying solely on column headers is insufficient for screen reader users navigating by control. A simple "Edit" or "Select" announcement lacks context.
1919
**Action:** Pass the row entity's name (e.g., user name) to the interactive component and use it in a dynamic `aria-label` (e.g., "Change role for John Doe").
20+
21+
## 2025-05-21 - [Dynamic Accessible Names for Select Triggers]
22+
23+
**Learning:** Shadcn UI `SelectTrigger` with a static `aria-label` overrides the screen reader announcement of the selected value. This leaves users knowing "Select Status" but not the _current_ status.
24+
**Action:** Use a dynamic `aria-label` that includes the current value (e.g., `aria-label={\`Status: ${valueLabel}\`}`) to provide full context.

.jules/sentinel.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,3 +29,9 @@
2929
**Vulnerability:** Found `TestAdminButton` containing hardcoded test credentials was statically imported into the login form, including the credentials in the production JavaScript bundle.
3030
**Learning:** Static imports of development-only components include their code (and secrets) in production bundles unless tree-shaken, which is unreliable for side-effect imports or complex components.
3131
**Prevention:** Use `next/dynamic` to lazily load development-only components, ensuring their code is split into a separate chunk that is never requested in production unless the component is rendered.
32+
33+
## 2026-01-25 - Sensitive Information Exposure in User Invitation
34+
35+
**Vulnerability:** Admin invitation actions (`inviteUser`, `resendInvite`) were throwing raw error messages (including potential SMTP error details) which were then displayed to the user via toast notifications.
36+
**Learning:** Even admin-only actions must be secure against information disclosure. Relying on `throw new Error(details)` in Server Actions often propagates the details to the client unless intercepted.
37+
**Prevention:** Always wrap external service calls (like Email, DB) in `try/catch` blocks in Server Actions. Log the full error securely on the server, and throw a generic, sanitized error message to the client.

AGENTS.md

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,18 @@ If your tool does not support skills, read the file path directly.
3838

3939
### Worktrees & Ports
4040

41-
We use git worktrees for parallel environments. Run `python3 scripts/sync_worktrees.py` to sync config.
41+
We use git worktrees for parallel environments. Config is managed via templates to prevent local leaks.
42+
43+
**Workflow**:
44+
45+
1. Run `python3 scripts/sync_worktrees.py` to generate `supabase/config.toml` and `.env.local` from templates.
46+
2. `supabase/config.toml` is ignored by git; do not track it.
47+
48+
**Troubleshooting**:
49+
50+
- _Config Mismatch_: If ports don't match the table below, re-run `python3 scripts/sync_worktrees.py`.
51+
- _Supabase Failures_: Run `supabase stop --all` then re-run the sync script.
52+
- _Template Changes_: If you need to change shared config, edit `supabase/config.toml.template` in the project root.
4253

4354
| Worktree | Next.js | Supabase API | Postgres |
4455
| :---------- | :------ | :----------- | :------- |

README.md

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -86,8 +86,7 @@ cd PinPoint
8686
pnpm install
8787
cp .env.example .env.local # then fill in Supabase + DB vars
8888

89-
supabase start # in one terminal
90-
pnpm run dev # in another
89+
pnpm run dev # automatically ensures Supabase is running
9190
```
9291

9392
Open `http://localhost:<PORT>` (see `.env.local`) to use the app.
@@ -120,7 +119,6 @@ pnpm run test # unit + PGlite integration tests
120119
pnpm run test:integration # Supabase-backed integration tests
121120
pnpm run smoke # Playwright smoke E2E tests
122121
pnpm run preflight # full local CI gate before pushing
123-
# See docs/E2E_DOCKER.md for running Safari tests locally via Docker
124122
```
125123

126124
For more detail, see `docs/DEVELOPMENT.md` and `docs/TESTING_PLAN.md`.

docs/DEVELOPMENT.md

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -34,18 +34,15 @@ If you’re trying to understand how to implement something, read:
3434

3535
```bash
3636
pnpm install
37-
cp .env.example .env.local
38-
# Fill in Supabase + database env vars
37+
python3 scripts/sync_worktrees.py
3938
```
4039

41-
3. **Start Supabase + Dev Server**
40+
This generates `supabase/config.toml` and `.env.local` from templates. These files are ignored by git to keep your local environment clean.
4241

43-
```bash
44-
# In one terminal
45-
supabase start
42+
3. **Start Dev Server**
4643

47-
# In another terminal
48-
pnpm run dev
44+
```bash
45+
pnpm run dev # automatically ensures Supabase is running
4946
```
5047

5148
4. **Run Fast Checks While Iterating**

docs/E2E_DOCKER.md

Lines changed: 0 additions & 36 deletions
This file was deleted.

drizzle/0002_add_issue_indexes.sql

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
CREATE INDEX "idx_issues_severity" ON "issues" USING btree ("severity");--> statement-breakpoint
2+
CREATE INDEX "idx_issues_priority" ON "issues" USING btree ("priority");

0 commit comments

Comments
 (0)