Skip to content

Interactive start: Ensure valid state of instance after project creation #8257

Description

@medikoo

When we setup a new project with a interactive CLI, after new template is downloaded, internals tweak already initialized instance so it behaves as it if was intialized in context of just created service.

Still as it's not full new initialization it's prone to issues, e.g. already initialized plugins are not reloaded, while they initially assumed they work out of service context (and that's not fixed), e.g. it got exposed with newly added configuration validation mechanism, which now reports Unrecognized provider 'aws' right after setting up AWS project:

sls output
Serverless: No project detected. Do you want to create a new one? Yes
Serverless: What do you want to make? AWS Node.js
Serverless: What do you want to call this project? marko

Project successfully created in 'marko' folder.
Serverless: Configuration warning: Unrecognized provider 'aws'
Serverless:  
Serverless: You're relying on provider plugin which doesn't provide a validation schema for its config.
Serverless: Please report the issue at its bug tracker linking: https://www.serverless.com/framework/docs/providers/aws/guide/plugins#extending-validation-schema
Serverless: You may turn off this message with "configValidationMode: off" setting
Serverless:  

It was fixed with temporary patch at #8258

Installed version

Framework Core: 2.0.0
Plugin: 4.0.2
SDK: 2.3.2
Components: 3.1.3

Proposed solution

After new service is setup, initialize a new serverless instance in its context and let it take over further steps of Interactive CLI

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions