adobe / aio-cli-plugin-app

Create, Build and Deploy Cloud Native Applications
Apache License 2.0
19 stars 35 forks source link

Pack command failing with "Cannot read properties of undefined (reading 'includes')" #773

Closed MichaelGoberling closed 7 months ago

MichaelGoberling commented 7 months ago

Problem

The aio app pack command is failing with the following error:

Error: Cannot read properties of undefined (reading \'includes\')

It seems that the aio api-mesh get command no longer throws an error when there isn't an api mesh configured for the project, it simply returns some text to stderr

So since the execa call doesn't throw, the pack command tries to serialize the stdout as JSON here, fails, and then in the try it looks for err.stderr here, which doesn't exist

Potential Solution

If there's stderr from the call to get the api-mesh, throw it as an error so it can be processed

aiojbot commented 7 months ago

JIRA issue created: https://jira.corp.adobe.com/browse/ACNA-2869