有一个错误,"Cannot find module rxjs/websocket"
当我运行“ npm i
”
我尝试了“ npm i --save rxjs-websocekts
”和“ rxjs-websocekts@6
”
但没有解决
并搜索此错误
但我找不到解决方法。
离子信息
Ionic:
ionic (Ionic CLI) : 4.2.1 (/usr/local/lib/node_modules/ionic)
Ionic Framework : ionic-angular 3.9.6
@ionic/app-scripts : 3.2.3
Cordova:
cordova (Cordova CLI) : 8.1.2 (cordova-lib@8.1.1)
Cordova Platforms : android 7.1.4
Cordova Plugins : cordova-plugin-ionic-keyboard 2.1.3, cordova-plugin-ionic-webview 2.2.0, (and 15other plugins)
System:
Android SDK Tools : 26.1.1 (/root/Android/Sdk)
NodeJS : v6.5.0 (/usr/local/bin/node)
npm : 3.10.3
OS : Linux 4.15
package.json
{
"name": "bm_client",
"version": "0.0.1",
"author": "Ionic Framework",
"homepage": "http://ionicframework.com/",
"private": true,
"scripts": {
"start": "ionic-app-scripts serve",
"clean": "ionic-app-scripts clean",
"build": "ionic-app-scripts build",
"lint": "ionic-app-scripts lint",
"ios": "ionic cordova run ios -- --buildFlag='-UseModernBuildSystem=0'"
},
"dependencies": {
"@angular/animations": "5.2.11",
"@angular/common": "5.2.11",
"@angular/compiler": "5.2.11",
"@angular/compiler-cli": "5.2.11",
"@angular/core": "5.2.11",
"@angular/forms": "5.2.11",
"@angular/http": "5.2.11",
"@angular/platform-browser": "5.2.11",
"@angular/platform-browser-dynamic": "5.2.11",
"@ionic-native/android-permissions": "4.20.0",
"@ionic-native/app-version": "4.20.0",
"@ionic-native/calendar": "4.18.0",
"@ionic-native/camera": "4.3.3",
"@ionic-native/core": "4.12.0",
"@ionic-native/device": "4.17.0",
"@ionic-native/facebook": "4.7.0",
"@ionic-native/fcm": "4.20.0",
"@ionic-native/firebase": "4.20.0",
"@ionic-native/keyboard": "4.20.0",
"@ionic-native/mobile-accessibility": "4.20.0",
"@ionic-native/photo-viewer": "4.20.0",
"@ionic-native/splash-screen": "4.12.0",
"@ionic-native/status-bar": "4.12.0",
"@ionic-native/wheel-selector": "4.16.0",
"@ionic/storage": "2.1.3",
"@ngx-translate/core": "8.0.0",
"@ngx-translate/http-loader": "2.0.1",
"@types/lodash": "4.14.118",
"@types/node": "10.12.2",
"@ultimate/ngxerrors": "1.4.0",
"add": "2.0.6",
"angular-progress-bar": "1.0.8",
"angular2-highcharts": "0.5.5",
"angular2-signaturepad": "2.8.0",
"angularfire2": "5.0.1",
"build": "0.1.4",
"chart.js": "2.7.3",
"com-sarriaroman-photoviewer": "1.2.2",
"cordova": "8.1.2",
"cordova-android": "~7.1.4",
"cordova-browser": "5.0.4",
"cordova-ios": "4.5.5",
"cordova-plugin-android-permissions": "1.0.0",
"cordova-plugin-app-version": "0.1.9",
"cordova-plugin-camera": "4.0.3",
"cordova-plugin-device": "2.0.2",
"cordova-plugin-facebook4": "4.2.1",
"cordova-plugin-fcm-with-dependecy-updated": "2.4.0",
"cordova-plugin-ionic-keyboard": "2.1.3",
"cordova-plugin-ionic-webview": "2.2.0",
"cordova-plugin-ios-camera-permissions": "1.2.0",
"cordova-plugin-iroot": "0.8.0",
"cordova-plugin-network-information": "git+https://github.com/apache/cordova-plugin-network-information.git",
"cordova-plugin-splashscreen": "5.0.2",
"cordova-plugin-statusbar": "2.4.2",
"cordova-plugin-whitelist": "1.3.3",
"cordova-sqlite-storage": "2.5.0",
"cordova-wheel-selector-plugin": "1.1.2",
"date-fns": "1.29.0",
"firebase": "5.4.2",
"intl": "1.2.5",
"ionic-angular": "3.9.6",
"ionic-long-press": "1.5.0",
"ionic2-calendar": "0.4.5",
"ionic3-calendar-en": "1.1.3",
"ionicons": "3.0.0",
"js-sha256": "0.9.0",
"lodash": "4.17.11",
"moment": "2.22.2",
"ng-circle-progress": "1.0.0",
"ng2-charts": "1.6.0",
"phonegap-plugin-mobile-accessibility": "1.0.5",
"phonegap-plugin-multidex": "1.0.0",
"plugin": "0.3.3",
"rxjs": "6.3.2",
"rxjs-compat": "6.0.0-tactical-rc.1",
"slide-ruler": "1.1.1",
"socket.io-client": "2.2.0",
"sw-toolbox": "3.6.0",
"webpack-merge": "4.1.4",
"zone.js": "0.8.26"
},
"devDependencies": {
"@ionic/app-scripts": "3.2.3",
"@ionic/lab": "1.0.8",
"typescript": "2.6.2"
},
"description": "An Ionic project",
"cordova": {
"plugins": {
"cordova-plugin-whitelist": {},
"cordova-plugin-statusbar": {},
"cordova-plugin-device": {},
"cordova-plugin-splashscreen": {},
"cordova-plugin-ionic-keyboard": {},
"cordova-wheel-selector-plugin": {},
"cordova-plugin-facebook4": {
"APP_ID": "272085810142209",
"APP_NAME": "bodymanager",
"FACEBOOK_HYBRID_APP_EVENTS": "false",
"FACEBOOK_ANDROID_SDK_VERSION": "4.40.0"
},
"cordova-plugin-android-permissions": {},
"phonegap-plugin-mobile-accessibility": {},
"cordova-plugin-camera": {
"CAMERA_USAGE_DESCRIPTION": "default",
"PHOTOLIBRARY_USAGE_DESCRIPTION": "default"
},
"cordova-plugin-app-version": {},
"cordova-plugin-ios-camera-permissions": {
"CAMERA_USAGE_DESCRIPTION": "default",
"PHOTOLIBRARY_ADD_USAGE_DESCRIPTION": "default",
"PHOTOLIBRARY_USAGE_DESCRIPTION": "default",
"MICROPHONE_USAGE_DESCRIPTION": "This app needs microphone access"
},
"cordova-plugin-iroot": {
"ENABLE_BUSYBOX_CHECK": "true"
},
"cordova-plugin-fcm-with-dependecy-updated": {},
"com-sarriaroman-photoviewer": {},
"cordova-plugin-ionic-webview": {}
},
"platforms": [
"browser",
"ios",
"android"
]
}
}
在运行“ npm install
”时
├── UNMET PEER DEPENDENCY @angular/common@5.2.11
├── UNMET PEER DEPENDENCY @angular/core@5.2.11
├── @ionic-native/calendar@4.18.0
├── @ionic-native/camera@4.3.3
├── @ionic-native/core@4.12.0
├── @ionic-native/device@4.17.0
├── @ionic-native/facebook@4.7.0
├── @ionic-native/splash-screen@4.12.0
├── @ionic-native/status-bar@4.12.0
├── @ionic-native/wheel-selector@4.16.0
├── @types/node@10.12.2
├── angular-progress-bar@1.0.8
├─┬ angularfire2@5.0.1
│ ├── UNMET PEER DEPENDENCY @angular/common@^6.0.0
│ ├── UNMET PEER DEPENDENCY @angular/core@^6.0.0
│ ├── @angular/fire@5.0.0
│ ├── UNMET PEER DEPENDENCY @angular/platform-browser@^6.0.0
│ └── UNMET PEER DEPENDENCY @angular/platform-browser-dynamic@^6.0.0
├── chart.js@2.7.3
├─┬ cordova-sqlite-storage@2.5.0
│ └── cordova-sqlite-storage-dependencies@1.2.0
├── cordova-wheel-selector-plugin@1.1.2
├── date-fns@1.29.0
├─┬ firebase@5.4.2
│ ├─┬ @firebase/app@0.3.3
│ │ ├── @firebase/app-types@0.3.2
│ │ ├─┬ @firebase/util@0.2.1
│ │ │ └── tslib@1.9.0
│ │ └── tslib@1.9.0
│ ├─┬ @firebase/auth@0.7.4
│ │ └── @firebase/auth-types@0.3.4
│ ├─┬ @firebase/database@0.3.4
│ │ ├── @firebase/database-types@0.3.2
│ │ ├── @firebase/logger@0.1.1
│ │ └── tslib@1.9.0
│ ├─┬ @firebase/firestore@0.7.2
│ │ ├── @firebase/firestore-types@0.6.0
│ │ ├── @firebase/webchannel-wrapper@0.2.8
│ │ ├─┬ grpc@1.13.1
│ │ │ └─┬ node-pre-gyp@0.10.3
│ │ │ ├── detect-libc@1.0.3
│ │ │ ├─┬ mkdirp@0.5.1
│ │ │ │ └── minimist@0.0.8
│ │ │ ├─┬ needle@2.2.1
│ │ │ │ ├─┬ debug@2.6.9
│ │ │ │ │ └── ms@2.0.0
│ │ │ │ ├─┬ iconv-lite@0.4.23
│ │ │ │ │ └── safer-buffer@2.1.2
│ │ │ │ └── sax@1.2.4
│ │ │ ├─┬ nopt@4.0.1
│ │ │ │ ├── abbrev@1.1.1
│ │ │ │ └─┬ osenv@0.1.5
│ │ │ │ ├── os-homedir@1.0.2
│ │ │ │ └── os-tmpdir@1.0.2
│ │ │ ├─┬ npm-packlist@1.1.11
│ │ │ │ ├─┬ ignore-walk@3.0.1
│ │ │ │ │ └─┬ minimatch@3.0.4
│ │ │ │ │ └─┬ brace-expansion@1.1.11
│ │ │ │ │ ├── balanced-match@1.0.0
│ │ │ │ │ └── concat-map@0.0.1
│ │ │ │ └── npm-bundled@1.0.3
│ │ │ ├─┬ npmlog@4.1.2
│ │ │ │ ├─┬ are-we-there-yet@1.1.5
│ │ │ │ │ ├── delegates@1.0.0
│ │ │ │ │ └─┬ readable-stream@2.3.6
│ │ │ │ │ ├── core-util-is@1.0.2
│ │ │ │ │ ├── isarray@1.0.0
│ │ │ │ │ ├── process-nextick-args@2.0.0
│ │ │ │ │ ├── string_decoder@1.1.1
│ │ │ │ │ └── util-deprecate@1.0.2
│ │ │ │ ├── console-control-strings@1.1.0
│ │ │ │ ├─┬ gauge@2.7.4
│ │ │ │ │ ├── aproba@1.2.0
│ │ │ │ │ ├── has-unicode@2.0.1
│ │ │ │ │ ├── object-assign@4.1.1
│ │ │ │ │ ├── signal-exit@3.0.2
│ │ │ │ │ ├─┬ string-width@1.0.2
│ │ │ │ │ │ ├── code-point-at@1.1.0
│ │ │ │ │ │ └─┬ is-fullwidth-code-point@1.0.0
│ │ │ │ │ │ └── number-is-nan@1.0.1
│ │ │ │ │ ├─┬ strip-ansi@3.0.1
│ │ │ │ │ │ └── ansi-regex@2.1.1
│ │ │ │ │ └── wide-align@1.1.3
│ │ │ │ └── set-blocking@2.0.0
│ │ │ ├─┬ rc@1.2.8
│ │ │ │ ├── deep-extend@0.6.0
│ │ │ │ ├── ini@1.3.5
│ │ │ │ ├── minimist@1.2.0
│ │ │ │ └── strip-json-comments@2.0.1
│ │ │ ├─┬ rimraf@2.6.2
│ │ │ │ └─┬ glob@7.1.2
│ │ │ │ ├── fs.realpath@1.0.0
│ │ │ │ ├─┬ inflight@1.0.6
│ │ │ │ │ └── wrappy@1.0.2
│ │ │ │ ├── inherits@2.0.3
│ │ │ │ ├── once@1.4.0
│ │ │ │ └── path-is-absolute@1.0.1
│ │ │ ├── semver@5.5.0
│ │ │ └─┬ tar@4.4.4
│ │ │ ├── chownr@1.0.1
│ │ │ ├── fs-minipass@1.2.5
│ │ │ ├── minipass@2.3.3
│ │ │ ├── minizlib@1.1.0
│ │ │ ├── safe-buffer@5.1.2
│ │ │ └── yallist@3.0.2
│ │ └── tslib@1.9.0
│ ├─┬ @firebase/functions@0.3.0
│ │ ├── @firebase/functions-types@0.2.0
│ │ ├── @firebase/messaging-types@0.2.3
│ │ └── tslib@1.9.0
│ ├─┬ @firebase/messaging@0.3.5
│ │ └── tslib@1.9.0
│ ├─┬ @firebase/polyfill@0.3.3
│ │ ├── core-js@2.5.5
│ │ └── promise-polyfill@7.1.2
│ └─┬ @firebase/storage@0.2.3
│ ├── @firebase/storage-types@0.2.3
│ └── tslib@1.9.0
├── UNMET PEER DEPENDENCY ionic-angular@3.9.6
├── ionic2-calendar@0.4.5
├── moment@2.22.2
├── ng-circle-progress@1.0.0
├── UNMET PEER DEPENDENCY rxjs@6.3.2
├── rxjs-compat@6.0.0-tactical-rc.1
└── webpack-merge@4.1.4
然后出现错误
“未捕获的错误:找不到模块“ rxjs / websocket”。”
我从未使用过“ rxjs/websocket
”模块。
这个错误突然出现了。
对于此错误,我应该删除或添加什么?
提前谢谢
当我尝试“ npm install rxjs@6 rxjs-compat@6 --save
”然后
投放服务
以上错误
[app-scripts] [19:10:36] ionic-app-scripts 3.2.3
[app-scripts] [19:10:36] watch started ...
[app-scripts] [19:10:36] build dev started ...
[app-scripts] [19:10:36] clean started ...
[app-scripts] [19:10:36] clean finished in 8 ms
[app-scripts] [19:10:36] copy started ...
[app-scripts] [19:10:36] deeplinks started ...
[app-scripts] [19:10:36] deeplinks finished in 419 ms
[app-scripts] [19:10:36] transpile started ...
[app-scripts] [19:10:41] typescript: node_modules/rxjs/internal/types.d.ts, line: 81
[app-scripts] [19:10:41] typescript: node_modules/rxjs/internal/types.d.ts, line: 81
[app-scripts] [19:10:41] typescript: node_modules/rxjs/internal/types.d.ts, line: 81
[app-scripts] [19:10:41] typescript: node_modules/rxjs/internal/types.d.ts, line: 82
[app-scripts] [19:10:41] typescript: node_modules/rxjs/internal/types.d.ts, line: 82
[app-scripts] [19:10:41] typescript: node_modules/rxjs/internal/types.d.ts, line: 82
[app-scripts] [19:10:41] typescript: node_modules/rxjs/internal/types.d.ts, line: 81
[app-scripts] [19:10:41] typescript: node_modules/rxjs/internal/types.d.ts, line: 81
[app-scripts] [19:10:41] typescript: node_modules/rxjs/internal/types.d.ts, line: 81
[app-scripts] [19:10:41] typescript: node_modules/rxjs/internal/types.d.ts, line: 81
[app-scripts] [19:10:41] typescript: node_modules/rxjs/internal/types.d.ts, line: 81
[app-scripts] [19:10:41] typescript: node_modules/rxjs/internal/types.d.ts, line: 82
[app-scripts] [19:10:41] typescript: node_modules/rxjs/internal/types.d.ts, line: 82
[app-scripts] [19:10:41] typescript: node_modules/rxjs/internal/types.d.ts, line: 82
[app-scripts] [19:10:41] typescript: node_modules/rxjs/internal/types.d.ts, line: 82
[app-scripts] [19:10:41] typescript: node_modules/rxjs/internal/types.d.ts, line: 82
[app-scripts] ';' expected.
[app-scripts] L81: export declare type ObservedValueOf<O> = O extends ObservableInput<infer T> ? T :never;
[app-scripts] L82: export declare type ObservedValuesFromArray<X> = X extends Array<ObservableInput<infer T>> ? T : never;
[app-scripts] ';' expected.
[app-scripts] L81: export declare type ObservedValueOf<O> = O extends ObservableInput<infer T> ? T :never;
[app-scripts] L82: export declare type ObservedValuesFromArray<X> = X extends Array<ObservableInput<infer T>> ? T : never;
[app-scripts] Expression expected.
[app-scripts] L81: export declare type ObservedValueOf<O> = O extends ObservableInput<infer T> ? T :never;
[app-scripts] L82: export declare type ObservedValuesFromArray<X> = X extends Array<ObservableInput<infer T>> ? T : never;
[app-scripts] ';' expected.
[app-scripts] L81: export declare type ObservedValueOf<O> = O extends ObservableInput<infer T> ? T :never;
[app-scripts] L82: export declare type ObservedValuesFromArray<X> = X extends Array<ObservableInput<infer T>> ? T : never;
[app-scripts] ';' expected.
[app-scripts] L81: export declare type ObservedValueOf<O> = O extends ObservableInput<infer T> ? T :never;
[app-scripts] L82: export declare type ObservedValuesFromArray<X> = X extends Array<ObservableInput<infer T>> ? T : never;
[app-scripts] Expression expected.
[app-scripts] L81: export declare type ObservedValueOf<O> = O extends ObservableInput<infer T> ? T :never;
[app-scripts] L82: export declare type ObservedValuesFromArray<X> = X extends Array<ObservableInput<infer T>> ? T : never;
[app-scripts] 'ObservableInput' only refers to a type, but is being used as a value here.
[app-scripts] L81: export declare type ObservedValueOf<O> = O extends ObservableInput<infer T> ? T :never;
[app-scripts] L82: export declare type ObservedValuesFromArray<X> = X extends Array<ObservableInput<infer T>> ? T : never;
[app-scripts] Cannot find name 'infer'.
[app-scripts] L81: export declare type ObservedValueOf<O> = O extends ObservableInput<infer T> ? T :never;
[app-scripts] L82: export declare type ObservedValuesFromArray<X> = X extends Array<ObservableInput<infer T>> ? T : never;
[app-scripts] Cannot find name 'T'.
[app-scripts] L81: export declare type ObservedValueOf<O> = O extends ObservableInput<infer T> ? T :never;
[app-scripts] L82: export declare type ObservedValuesFromArray<X> = X extends Array<ObservableInput<infer T>> ? T : never;
[app-scripts] Cannot find name 'T'.
[app-scripts] L81: export declare type ObservedValueOf<O> = O extends ObservableInput<infer T> ? T :never;
[app-scripts] L82: export declare type ObservedValuesFromArray<X> = X extends Array<ObservableInput<infer T>> ? T : never;
[app-scripts] 'never' only refers to a type, but is being used as a value here.
[app-scripts] L81: export declare type ObservedValueOf<O> = O extends ObservableInput<infer T> ? T :never;
[app-scripts] L82: export declare type ObservedValuesFromArray<X> = X extends Array<ObservableInput<infer T>> ? T : never;
[app-scripts] 'ObservableInput' only refers to a type, but is being used as a value here.
[app-scripts] L81: export declare type ObservedValueOf<O> = O extends ObservableInput<infer T> ? T :never;
[app-scripts] L82: export declare type ObservedValuesFromArray<X> = X extends Array<ObservableInput<infer T>> ? T : never;
[app-scripts] Cannot find name 'infer'.
[app-scripts] L81: export declare type ObservedValueOf<O> = O extends ObservableInput<infer T> ? T :never;
[app-scripts] L82: export declare type ObservedValuesFromArray<X> = X extends Array<ObservableInput<infer T>> ? T : never;
[app-scripts] Cannot find name 'T'.
[app-scripts] L81: export declare type ObservedValueOf<O> = O extends ObservableInput<infer T> ? T :never;
[app-scripts] L82: export declare type ObservedValuesFromArray<X> = X extends Array<ObservableInput<infer T>> ? T : never;
[app-scripts] Cannot find name 'T'.
[app-scripts] L81: export declare type ObservedValueOf<O> = O extends ObservableInput<infer T> ? T :never;
[app-scripts] L82: export declare type ObservedValuesFromArray<X> = X extends Array<ObservableInput<infer T>> ? T : never;
[app-scripts] 'never' only refers to a type, but is being used as a value here.
[app-scripts] L81: export declare type ObservedValueOf<O> = O extends ObservableInput<infer T> ? T :never;
[app-scripts] L82: export declare type ObservedValuesFromArray<X> = X extends Array<ObservableInput<infer T>> ? T : never;
答案 0 :(得分:0)
尝试安装echo
和from sklearn.multiclass import OneVsRestClassifier
from sklearn.svm import LinearSVC
clf = OneVsRestClassifier(LinearSVC())
clf.fit(X_train, y_train)
npm安装rxjs @ 6 rxjs-compat @ 6-保存
答案 1 :(得分:0)
您的代码或其他模块正在使用rxjs / websocket。 github上提到了一个解决方案。
https://github.com/stbui/angular-material-app/issues/39 https://github.com/stbui/angular-material-app/issues/39