janus-idp / backstage-plugins

Plugins for Backstage
https://janus-idp.io
Apache License 2.0
125 stars 127 forks source link

`yarn tsc` failing on `orchestrator-backend` on the `main` branch #1848

Closed rm3l closed 5 days ago

rm3l commented 5 days ago

Describe the bug

I rebased my PR (https://github.com/janus-idp/backstage-plugins/pull/1471) onto main, and noticed some failures due to recent changes in the orchestrator-backend.

I checked main and noticed that yarn tsc also errors out.

https://github.com/janus-idp/backstage-plugins/actions/runs/9698241417/job/26765971595

Expected Behavior

yarn tsc should pass with no error.

What are the steps to reproduce this bug?

$ yarn workspace @janus-idp/backstage-plugin-orchestrator-backend tsc

yarn workspace v1.22.20
yarn run v1.22.20
$ tsc
src/service/router.ts:1178:31 - error TS2304: Cannot find name 'JiraEvent'.

1178     const event = req.body as JiraEvent;
                                   ~~~~~~~~~

src/service/router.ts:1179:20 - error TS2339: Property 'jiraService' does not exist on type 'PublicServices'.

1179     await services.jiraService.handleEvent(event);
                        ~~~~~~~~~~~

Found 2 errors in the same file, starting at: src/service/router.ts:1178

error Command failed with exit code 2.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
error Command failed.
Exit code: 2
Command: /home/asoro/.nvm/versions/node/v20.12.2/bin/node
Arguments: /home/asoro/.nvm/versions/node/v20.12.2/lib/node_modules/yarn/lib/cli.js tsc
Directory: /home/asoro/work/projects/backstage/janus-idp/backstage-plugins/plugins/orchestrator-backend
Output:

info Visit https://yarnpkg.com/en/docs/cli/workspace for documentation about this command.

Versions of software used and environment

$ node --version                                                
v20.12.2

$ yarn --version                                                     
1.22.20
rm3l commented 5 days ago

/cc @anludke /cc @gciavarrini

Seems to be related to https://github.com/janus-idp/backstage-plugins/pull/1833 which was merged recently.

gciavarrini commented 5 days ago

@rm3l Thanks for opening this issue. Fixed by #1850