bitpay / bitcore

A full stack for bitcoin and blockchain-based applications
https://bitcore.io/
MIT License
4.85k stars 2.09k forks source link

bitcore-client 8.6.0: error TS2688: Cannot find type definition file for 'request-promise-native' #2357

Open jamespharvey20 opened 5 years ago

jamespharvey20 commented 5 years ago

Cannot successfully build bitcore master, v8.6.0 (ebb58c5), or previously working v8.3.4 (49166f0). Downgrading nodejs from 12.9.1 to 11.15.0 gets around #2353, but then after npm install running npm run, it gives this error:

> bitcore-node@8.3.4 clean /home/bitcore/bitcore.git.f/packages/bitcore-node
> rm -rf build

node_modules/bitcore-client/ts_build/wallet.d.ts:2:23 - error TS2688: Cannot find type definition file for 'request-promise-native'.

2 /// <reference types="request-promise-native" />

Because bitcore-client is given as a @^ dependency, attempting to recompile v8.3.4 using a virtual machine not updated since v8.3.4 was installed, now fails. It shows it's pulling in bitcore-client v8.6.0. I don't seem to be able to force it to use 8.3.4, because that version is no longer on the npm erver. https://www.npmjs.com/package/bitcore-client only shows 8.1.0 and 8.6.0, so all the others must either have never been published there, or deleted.

I was a bit surprised to see this, since this bitcore git repo includes packages/bitcore-client/. It must not be using the in-tree source, but instead getting it from npm.

npm 6.11.2, nodejs 11.15.0.

micahriggan commented 5 years ago

Are you running npm install from the root directory of bitcore or a specific package? If you do a particular package then it will pull from npm, but top level uses lerna bootstrap on post install to do the symlinks

jamespharvey20 commented 5 years ago

Are you running npm install from the root directory of bitcore or a specific package? If you do a particular package then it will pull from npm, but top level uses lerna bootstrap on post install to do the symlinks

Yes. :-( After trying to diagnose the nodejs 12 problem, I was running npm install in packages/bitcore-node.

Makes sense why that way it pulls from npm.

Sorry about that. Probably time to close this issue, but in case I'm wrong and there's something worth changing here, I'll leave that to you guys.

I'm now successfully running v8.6.0, after downgrading nodejs to 11.

Matthelonianxl commented 5 years ago

Weth Silk .org Oblmfge Firebase 8 .org updating DOCS Firebase Alexa Electroneum light Silk Firebase Ar p1281.pdf chitecure