Skip to content

cargo watch to terminate the app when build process fails #3417

@gergelyk

Description

@gergelyk

In my typical development process I start from:

spin new -t http-rust -a example
cd example
spin watch

Then I alternately edit the code and test the app, e.g. using curl.

Whenever I make a mistake which results in compilation process failure, spin prints the error to stderr and keeps previous version of the app running. This requires me to constantly watch the output from spin or rely on IDE to highlight the problem. Otherwise I may end up testing outdated version of the code, which later leads to invalid reasoning.
The improvement that I would consider is terminating the app before starting compilation. This way any attempt of testing the app would reveal the compilation issue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions