Closed HyperBrain closed 7 years ago
Investigated the issue. The problem is, that SLS logs
filters all log streams that have $LATEST
in their name:
return _.chain(reply.logStreams)
.filter(stream => stream.logStreamName.includes('[$LATEST]'))
.map('logStreamName')
.value();
Naturally, deployed aliases would never occur as $LATEST but with the actually deployed version.
So the correct fix would be that the alias plugin checks the current version for any alias and just emits the logs for the selected alias.
Invoking
serverless logs
leads to error message.Additionally to this defect, the alias plugin should add support for the
--alias
option to show the log from an aliased function.