[ERROR] An error occurred while running npm i (exit code 1): code400

国庆来了,npm 的命令都不可以用:我新建了一个ionic的项目

ionic start ionc tabs

出现了这个报错:如下:

PS G:\lianxi\myionic02> ionic start myionic03 tabs
√ Creating directory .\myionic03 - done!
√ Downloading and extracting tabs starter - done!

? Would you like to integrate your new app with Cordova to target native iOS and Android? No
√ Personalizing ionic.config.json and package.json - done!

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
× Running command - failed!
[ERROR] An error occurred while running npm i (exit code 1):

npm ERR! code E400
npm ERR! 400 Bad Request: @angular/[email protected]

npm ERR! A complete log of this run can be found in:
npm ERR! C:\Program Files\nodejs\node_cache\_logs\2018-10-10T00_42_27_177Z-debug.log

图片看的应该更清晰一些:

百度,谷歌搜了很多,没有找到答案,我一直以为是node或者angular的问题,

后来某位大神给我说可能是ionic‘的问题,至此问题才得以解决:

在c盘找到了.npmrc这个文件

把第一行和第4行删除,

在此执行  ionic start ionc tabs

问题完美解决

原文地址:https://www.cnblogs.com/adong69/p/9765489.html

时间: 2024-10-07 08:39:13

[ERROR] An error occurred while running npm i (exit code 1): code400的相关文章

This usually happens because your environment has changed since running `npm install`.

[4/8] ? node-sass error E:\webstorm_workspace\hzl-admin\node_modules\node-sass: Command failed. Exit code: 1 Command: node scripts/build.js 此时运行按照提示执行  npm rebuild node-sass  命令,(如若不行,则先运行npm install node-sass命令执行) 然后再运行 node命令,启动服务. 原文地址:https://www

eclipse - An internal error occurred during: &quot;Running Android Lint&quot;

概述 也不晓得为什么,编译eclipse,设置打开,就自动报错: An internal error occurred during: "Running Android Lint" solution 打开 eclipse根目录下的 'eclipse.ini'文件,将有'-Xms'和'-Xmx'的两行进行修改, 将原内容 1 -startup 2 plugins/org.eclipse.equinox.launcher_1.2.0.v20110502.jar 3 --launcher.l

Mac Error Create Android Project - “Errors running builder &#39;Android Resource Manager&#39; on project”

http://stackoverflow.com/questions/18096315/mac-error-create-android-project-errors-running-builder-android-resource-man 在mac笔记本上运行android eclipse报标题的错误,然后在stackoverflow上找到了答案 18down votefavorite 5 I spent the whole day just trying to create a simple

安装qc 出现error An error occurred while attempting to connect to the database.

When trying to install mercury quality center starter edition 9.0 on Windows XP media center, I am getting the following error Wrong attributes  "An error occurred while attempting to connect to the database. Please check that the database is availab

出现Uncaught Error: Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.的情况

记录出现Uncaught Error: Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.报错的情况 基本是需要显示的值不对 1. 在标签里面直接使用Object <div>{name: '张三'}</div> 2. 原文地址:https://www.cnblogs.com/victo

usr/bin/mysqladmin: refresh failed; error: &#39;Unknown error&#39;

debian wheezy 升级后, 因为授权错误, 导致密码给修改, 在debian的mysql safe下也无法进入. 我在/etc/mysql/my.cnf 里面已经修改了bind-address 为局域网ip 进而执行了 GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' IDENTIFIED BY '123456' WITH GRANT OPTION; 然后重载授权表: FLUSH PRIVILEGES; 然后重启后, 虽然可以远程链接, 但是debia

BIP Requests Are Failing With Error &quot;OPP Error Oracle.apps.xdo.XDOException: Error Creating Lock Fil

In this Document   Symptoms   Cause   Solution   References Applies to: BI Publisher (formerly XML Publisher) - Version 12.1 to 12.2 [Release 12.1 to 12.2] Information in this document applies to any platform. Symptoms BiP Requests are failing: ERROR

Xcode5.1.1支持低版本和image not found和Couldn&#39;t register XXXX with the bootstrap server. Error: unknown error code.

一:问题  targets中证书的设置 1.项目支持多设备(Xcode5.1.1支持低版本) 2.真机测试要确保Code Siging 设置没问题 支持的最低版本 二 :问题:image  not found Library not loaded: /System/Library/Frameworks/AdSupport.framework/AdSupport   Referenced from: /var/mobile/Applications/0083F6DD-6466-48B4-8F6D-

PHP-问题处理Fatal error: Uncaught Error: Call to undefined function simplexml_load_file()

1.问题 今天重新安装了ubuntu,PHP,MySQL,Apache,到测试CMS项目时发生一个错误: Fatal error: Uncaught Error: Call to undefined function simplexml_load_file() 2.解决: 2.1 安装php-xml: sudo apt-get install php-xml 2.2重启apache服务: sudo service apache2 restart