Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 7 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ jobs:

- uses: pnpm/action-setup@v4
with:
version: 9
version: 9.15.0

- uses: actions/setup-node@v4
with:
Expand All @@ -59,8 +59,13 @@ jobs:
- name: Type check
run: pnpm typecheck

- name: Run migrations
run: pnpm --filter @repo/db db:migrate:ci
env:
DATABASE_URL: postgres://test:test@localhost:5432/test

- name: Test
run: pnpm test --run
run: pnpm test
env:
NODE_ENV: test
DATABASE_URL: postgres://test:test@localhost:5432/test
Expand Down
2 changes: 1 addition & 1 deletion apps/backend/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"typecheck": "tsc --noEmit",
"lint": "biome check .",
"lint:fix": "biome check --fix .",
"test": "cross-env NODE_ENV=test vitest",
"test": "cross-env NODE_ENV=test vitest run",
"build": "swc src --out-dir dist --config-file .swcrc && tsc-alias && cp package.json dist/",
"db:generate": "drizzle-kit generate",
"db:migrate": "drizzle-kit push",
Expand Down
5 changes: 4 additions & 1 deletion apps/backend/src/jobs/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,10 @@ export async function addJob<T extends JobName>(

const queue = queueMap[name];

return (queue as Queue<JobData[T]>).add(name, data, {
// Queue<any> collapses all generics so .add() accepts (string, data) without ExtractNameType inference errors
// biome-ignore lint/suspicious/noExplicitAny: BullMQ ExtractNameType bug (github.com/taskforcesh/bullmq/issues/3369)
const q = queue as unknown as Queue<any>;
return q.add(name, data, {
delay: options?.delay,
priority: options?.priority,
removeOnComplete: 100,
Expand Down
1 change: 1 addition & 0 deletions packages/db/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
"clean": "rimraf dist",
"db:generate": "drizzle-kit generate",
"db:migrate": "drizzle-kit push",
"db:migrate:ci": "drizzle-kit migrate",
"db:studio": "drizzle-kit studio"
},
"dependencies": {
Expand Down
Loading