0

During my lunchtimes I am building an Alexa app.

I was getting an error around alexa sdk not found and fixed that buy uploading the local version of alexa sdk (installed using npm).

However, when I then go in and use Lanmda's online nodejs editor for alexa, this overrides the alexa sdk I uploaded and I am back to square one.

How do you get round this issue? Do I have to do all my js coding offline and then upload each time? If so, it kind of defeats the object of having an online nodejs editor?

Charlie S
  • 4,366
  • 6
  • 59
  • 97

2 Answers2

0

I missed the warning message which should fix this:

"The deployment package of your Lambda function "Mimic" is too large to enable inline code editing. However, you can still invoke your function right now."

So basically my deployment package was too large so when I went to online edit, it overwrote what I had uploaded. I will reduce the deployment package size and hopefully that will allow online editing.

Charlie S
  • 4,366
  • 6
  • 59
  • 97
0

As you mentioned, the issue is that you overwrote your deployment package.

As an alternate solution, if your code is all in the same file, you can use one of the Alexa skill blueprints for lambda, which come with the Alexa-SDK pre-loaded. Then just paste your code into the console and you will be able to edit it directly, without fear of overwriting the Alexa-SDK.

You have to select the blueprint you want to use while you are creating the Lambda function, so the downside is you will need to create a new Lambda function. Checkout step four of this walkthrough section: https://github.com/alexa/skill-sample-nodejs-howto#create-an-aws-lambda-function

Ben Helsey
  • 26
  • 3