shuttle-hq/shuttle

[Bug]: Deployment with running test will fail

kigawas opened this issue · 3 comments

What happened?

Deploy with test cargo shuttle deploy will fail with:

2024-07-16T01:56:22.974+09:00 [Deployer]  INFO shuttle_proto::_runtime_client: connecting runtime client
2024-07-16T01:56:29.975+09:00 [Deployer]  INFO Entering Crashed state
2024-07-16T01:56:29.975+09:00 [Deployer]  INFO Cleaning up startup crashed deployment
2024-07-16T01:56:29.975+09:00 [Deployer] ERROR shuttle_deployer::deployment::run: {error="Failed to get runtime: failed to start shuttle runtime"} Service startup encountered an error

Deployment crashed

Run the following for more details

cargo shuttle logs 1daab0f7-ed00-4392-9c76-1373e214f083

--no-test is fine

Version

v0.46.0

Which operating system(s) are you seeing the problem on?

In deployment

Which CPU architectures are you seeing the problem on?

In deployment

Relevant log output

See above

Duplicate declaration

  • I have searched the issues and there are none like this.

Hi, are you using any tests in your application? Shuttle will try to run tests by default if there are any.

A common cause of failure might be that you're trying to use something like testcontainers that spins up dev containers locally, which the Shuttle environment currently can't do (and will therefore invalidate the tests).

There should be no test containers, just axum routers

Closing since the new shuttle.dev builder will not run tests by default.