midday-ai / v1

An open-source starter kit based on Midday.
https://v1.run
MIT License
3.18k stars 285 forks source link

Can't connect Trigger #16

Closed northrn closed 2 months ago

northrn commented 2 months ago

Triggers cloud platform wants you to initialize Trigger in your project in order to link the two for creating and testing tasks. However the "npx trigger.dev@beta dev" command fails when running it in this project with the following message:

Trigger.dev (3.0.0-beta.56)
------------------------------------------------------
Key: Version | Task | Run
------------------------------------------------------
○ Building background worker…
X Error: Worker failed to build: no tasks found. Searched in 

I tried overriding the current config but then I get the following error:

Command failed with exit code 1: npm install --save-exact '@trigger.dev/sdk@3.0.0-beta.56'

npm WARN ERESOLVE overriding peer dependency
npm ERR! code EUNSUPPORTEDPROTOCOL
npm ERR! Unsupported URL Type "workspace:": workspace:*
northrn commented 2 months ago

@pontusab Project needs a "trigger" folder inside "jobs" where tasks are located. This will allow the Trigger CLI to find the tasks and connect to your dashboard to manage runs.

Tried creating a PR but can't submit as I'm not authorized.

pontusab commented 2 months ago

Just merged a fix, add your project in trigger.config.ts and then run bun run dev:jobs

normand1 commented 2 months ago

@pontusab no errors, but it's not finding the example.ts trigger. Any ideas?

✗ bun run dev:jobs
$ turbo jobs --filter=@v1/jobs
turbo 2.1.1

• Packages in scope: @v1/jobs
• Running jobs in 1 packages
• Remote caching disabled

No tasks were executed as part of this run.

 Tasks:    0 successful, 0 total
Cached:    0 cached, 0 total
  Time:    174ms 
normand1 commented 2 months ago

I had to make this update too in order for it to work for me, just FYI: https://github.com/midday-ai/v1/pull/40