Skip to content

../../node_modules//index.d.ts(8,9): error TS2687: All declarations of 'observable' must have identical modifiers. [ERROR] Command not found: ng #3316

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
vksgautam1 opened this issue Jun 19, 2018 · 7 comments

Comments

@vksgautam1
Copy link

Description:
i made a new project so whenever i run a command
"ionic cordova run android"
this is giving me issue. so unable to run a build

../../node_modules//index.d.ts(8,9): error TS2687: All declarations of 'observable' must have identical modifiers. [ERROR] Command not found: ng

Steps to Reproduce:

Output:

My ionic info:


Ionic:

   ionic (Ionic CLI)          : 4.0.0-rc.8 (C:\Users\DELL\AppData\Roaming\nvm\v8.9.0\node_modules\ionic)
   Ionic Framework            : @ionic/angular 4.0.0-alpha.7
   @angular-devkit/core       : 0.7.0-rc.0
   @angular-devkit/schematics : 0.7.0-rc.0
   @angular/cli               : 6.0.8
   @ionic/ng-toolkit          : 1.0.0-rc.8
   @ionic/schematics-angular  : 1.0.0-rc.8

Cordova:

   cordova (Cordova CLI) : 8.0.0
   Cordova Platforms     : none

System:

   Android SDK Tools : 25.2.5
   NodeJS            : v8.9.0 (C:\Program Files\nodejs\node.exe)
   npm               : 5.5.1
   OS                : Windows 10

Other Information:
my package json
{ "name": "v4alpha", "version": "0.0.1", "author": "Ionic Framework", "homepage": "http://ionicframework.com/", "scripts": { "ng": "ng", "start": "ionic serve", "build": "ionic build", "test": "ng test", "lint": "ng lint", "e2e": "ng e2e" }, "private": true, "dependencies": { "@angular/common": "6.0.5", "@angular/core": "6.0.5", "@angular/forms": "6.0.5", "@angular/http": "6.0.5", "@angular/platform-browser": "6.0.5", "@angular/platform-browser-dynamic": "6.0.5", "@angular/router": "6.0.5", "@ionic-native/core": "5.0.0-beta.10", "@ionic-native/splash-screen": "5.0.0-beta.10", "@ionic-native/status-bar": "5.0.0-beta.10", "@ionic/angular": "4.0.0-alpha.7", "@ionic/ng-toolkit": "1.0.0-rc.8", "@ionic/schematics-angular": "1.0.0-rc.8", "cordova-android": "7.0.0", "cordova-plugin-device": "^2.0.2", "cordova-plugin-ionic-keyboard": "^2.0.5", "cordova-plugin-ionic-webview": "^1.1.19", "cordova-plugin-splashscreen": "^5.0.2", "cordova-plugin-whitelist": "^1.3.3", "core-js": "^2.5.3", "rxjs": "6.2.1", "zone.js": "^0.8.26" }, "devDependencies": { "@angular/cli": "6.0.8", "@angular/compiler": "6.0.5", "@angular/compiler-cli": "6.0.5", "@angular/language-service": "6.0.5", "@angular-devkit/architect": "0.7.0-rc.0", "@angular-devkit/build-angular": "0.7.0-rc.0", "@angular-devkit/core": "0.7.0-rc.0", "@angular-devkit/schematics": "0.7.0-rc.0", "@types/jasmine": "~2.8.6", "@types/jasminewd2": "~2.0.3", "@types/node": "~10.3.2", "codelyzer": "~4.3.0", "jasmine-core": "~2.99.1", "jasmine-spec-reporter": "~4.2.1", "karma": "~2.0.2", "karma-chrome-launcher": "~2.2.0", "karma-coverage-istanbul-reporter": "~2.0.0", "karma-jasmine": "~1.1.1", "karma-jasmine-html-reporter": "^0.2.2", "protractor": "~5.3.0", "ts-node": "~6.1.1", "tslint": "~5.10.0", "typescript": "~2.7.2" }, "description": "An Ionic project", "cordova": { "plugins": { "cordova-plugin-whitelist": {}, "cordova-plugin-device": {}, "cordova-plugin-splashscreen": {}, "cordova-plugin-ionic-webview": {}, "cordova-plugin-ionic-keyboard": {} }, "platforms": [ "android" ] } }

@ionitron-bot ionitron-bot bot added the triage label Jun 19, 2018
@imhoffd imhoffd removed the triage label Jun 19, 2018
@imhoffd
Copy link
Contributor

imhoffd commented Jun 19, 2018

@vksgautam1 Can you paste the output of npm ls @types/zen-observable ?

@vksgautam1
Copy link
Author

vksgautam1 commented Jun 20, 2018

[email protected] E:\Working Project\ionic4\v4alpha
`-- (empty)

@vksgautam1
Copy link
Author

vksgautam1 commented Jun 20, 2018

i made another testing project and same issue happened. is there any kind of setup or environment issues.
here is another project

 ionic start newProject

What type of project would you like to create?

We recommend angular. To learn more about project types, see the CLI documentation[1]. To bypass this prompt next time,
supply the --type option.

[1]: https://ionicframework.com/docs/cli/starters.html

? Project type: angular

Let's pick the perfect starter template!

Starter templates are ready-to-go Ionic apps that come packed with everything you need to build your app. To bypass this
prompt next time, supply template, the second argument to ionic start.

? Starter template: tabs
√ Preparing directory .\newProject - done!
√ Downloading and extracting tabs starter - done!
? Integrate your new app with Cordova to target native iOS and Android? Yes
> ionic integrations enable cordova --quiet
√ Downloading integration cordova - done!
√ Copying integrations files to project - done!
[OK] Integration cordova added!

Installing dependencies may take several minutes.

     *   IONIC  DEVAPP   *

 Speed up development with the Ionic DevApp, our fast, on-device testing mobile app

  -     Test on iOS and Android without Native SDKs
  -     LiveReload for instant style and JS updates

 -->    Install DevApp: https://bit.ly/ionic-dev-app    <--

────────────────────────────────────────────────────────────

> npm i
npm WARN deprecated [email protected]: 1.2.0 should have been a major version bump
npm WARN deprecated [email protected]: All versions below 4.0.1 of Nodemailer are deprecated. See https://nodemailer.com/status/
npm WARN deprecated [email protected]: stop using this version
npm WARN deprecated [email protected]: This project is unmaintained
npm WARN deprecated [email protected]: If using 2.x branch, please upgrade to at least 2.1.6 to avoid a serious bug with socket data flow and an import issue introduced in 2.1.0
npm WARN deprecated [email protected]: Use uuid module instead
npm WARN deprecated [email protected]: This project is unmaintained

> [email protected] install E:\Working Project\ionic4\newProject\node_modules\uws
> node-gyp rebuild > build_log.txt 2>&1 || exit 0


> [email protected] install E:\Working Project\ionic4\newProject\node_modules\node-sass
> node scripts/install.js

Cached binary found at C:\Users\DELL\AppData\Roaming\npm-cache\node-sass\4.9.0\win32-x64-57_binding.node

> [email protected] postinstall E:\Working Project\ionic4\newProject\node_modules\node-sass
> node scripts/build.js

Binary found at E:\Working Project\ionic4\newProject\node_modules\node-sass\vendor\win32-x64-57\binding.node
Testing binary
Binary is fine

> @angular/[email protected] postinstall E:\Working Project\ionic4\newProject\node_modules\@angular\cli
> node ./bin/ng-update-message.js

npm notice created a lockfile as package-lock.json. You should commit this file.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})

added 1304 packages in 416.843s
> git init

     *   IONIC  PRO   *

 Supercharge your Ionic development with the Ionic Pro SDK

  -     Track runtime errors in real-time, back to your original TypeScript
  -    Push remote updates and skip the app store queue

 Learn more about Ionic Pro: https://ionicframework.com/pro

────────────────────────────────────────────────────────────

? Install the free Ionic Pro SDK and connect your app? No
> git add -A
> git commit -m "Initial commit" --no-gpg-sign

[INFO] Next Steps:

       - Go to your newly created project: cd .\newProject
       - Get Ionic DevApp for easy device testing: https://bit.ly/ionic-dev-app`
```

@vksgautam1
Copy link
Author

for v3 projects it is working fine.

@imhoffd
Copy link
Contributor

imhoffd commented Jun 20, 2018

Can you tell me which module actually has the error? your pasted error strips out the module:

../../node_modules//index.d.ts(8,9): error TS2687: All declarations of 'observable' must have identical modifiers. [ERROR] Command not found: ng

Please use triple backticks when posting output it doesn't strip anything and is readable. See https://github.com/adam-p/markdown-here/wiki/Markdown-Cheatsheet#code-and-syntax-highlighting

@vksgautam1
Copy link
Author

vksgautam1 commented Jun 21, 2018

ERROR in ../../node_modules/@types/zen-observable/index.d.ts(8,9): error TS2687: All declarations of 'observable' must have identical modifiers.

related one to this is with rxjs.

https://github.com/angular/angular/issues/24245

edit-
npm i @types/zen-observable.
update to this is gonna solve this issue. 

@imhoffd
Copy link
Contributor

imhoffd commented Jun 21, 2018

Cool, looks like latest rxjs and zen-observable/@types/zen-observable fix this issue.

@imhoffd imhoffd closed this as completed Jun 21, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants