我是AWS的新手我开始探索AWS文档并考虑从NodeJS应用程序连接AWS sdk,因为我安装了npm aws-lib,如下所示。
能否帮助我解决这个问题。
class BaseClass { static var classType: SomeEnum { get { return SomeEnum.BaseType } } } class DerivedClass : BaseClass { // ERROR: Class var overrides 'final' class var static var classType: SomeEnum { get { return SomeEnum.DerivedType } } }
appss-MacBook-Pro-2:NodeJS apps$ npm install aws-lib
aws-lib@0.3.0 node_modules/aws-lib
├── underscore@1.5.2
├── xml2js@0.1.14
└── sax@0.1.5
appss-MacBook-Pro-2:NodeJS apps$ npm test
npm ERR! Darwin 15.0.0
npm ERR! argv "node" "/usr/local/bin/npm" "test"
npm ERR! node v0.12.7
npm ERR! npm v2.11.3
npm ERR! path /Users/apps/Desktop/IOT/NodeJS/package.json
npm ERR! code ENOENT
npm ERR! errno -2
npm ERR! enoent ENOENT, open '/Users/apps/Desktop/IOT/NodeJS/package.json'
npm ERR! enoent This is most likely not a problem with npm itself
npm ERR! enoent and is related to npm not being able to find a file.
npm ERR! enoent
npm ERR! Please include the following file with any support request:
npm ERR! /Users/apps/Desktop/IOT/NodeJS/npm-debug.log
appss-MacBook-Pro-2:NodeJS apps$
的输出如下:
npm-debug.log
答案 0 :(得分:1)
你确实安装了aws-lib
。您可以通过查看项目目录中的node_modules
目录来验证它。
您接下来要做的就是调用npm test
,但看起来您的test
文件中没有package.json
部分,因此npm
不知道要为test
运行什么。