forwardemail / forwardemail/superagent
@types/supertest 4.1.14 is breaking in docker build: Cannot find name 'Blob'
- Dominant language
- JavaScript
- Stars
- 16.6k
- Forks
- 1.3k
- PR merge metrics
- No merged PRs in 30d
Description
Hey guys, thanks for all the good work your doing.
I had to downgrade a project to @types/supertest 4.1.13 since I was getting a weird problem with typescript while building in docker. It came through in the patch version 4.1.14 since we had carrots on ^. I've learned my lesson and locked all the package versions going forward. So we only update when we want to.
But anyways If your interested:
Here's the docker file. Were using node 14-ish
```
FROM node:14-slim
WORKDIR /usr/src/app
COPY . ./
RUN npm ci
RUN npm run build:packages
RUN npm run build
EXPOSE 3000
CMD [ "npm", "start" ]
```
Then running docker build
`docker build . --progress=plain`
The error:
```
#9 2.857 > tsc --project tsconfig.json
#9 2.857
#9 7.071 ../../node_modules/@types/superagent/index.d.ts(34,29): error TS2304: Cannot find name 'Blob'.
#9 7.102 npm ERR! code ELIFECYCLE
#9 7.102 npm ERR! errno 2
#9 7.105 npm ERR! @rh-estore-bff/trade-service@1.0.7 build: `tsc --project tsconfig.json`
#9 7.105 npm ERR! Exit status 2
#9 7.105 npm ERR!
#9 7.105 npm ERR! Failed at the @rh-estore-bff/trade-service@1.0.7 build script.
#9 7.105 npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
```
I think this is a configuration issue on our side though. I tried to reproduce this on a git repo without our code and the problem is not there.
Contributor guide
Assessment
This issue has not been assessed yet.