fix: update docker event format to use template syntax#62
fix: update docker event format to use template syntax#62kiitosu wants to merge 1 commit intolocalstack:mainfrom
Conversation
|
@kiitosu thanks for the contribution! Aren't Edit: I use Edit 2: Asked AI about it. This is the response:
|
|
@skyrpex |
|
Thanks @kiitosu for the quick feedback and raising this issue 🐛 Since this does impact users that are stuck on older docker versions, we'll find some time to tackle it properly. |
Summary
This PR fixes the issue where LocalStack container state in the VSCode extension stays in
startingorstoppingand never transitions torunningorstopped.my environment
VSCode: Version: 1.104.1
LocalStack Toolkit: 1.2.3
macOS (Apple M1 Pro): Sequoia 15.7
docker: 20.10.21, build baeda1f82a
Problem
starting/stopping.docker ps) showed that the container itself had already reachedrunning/stopped.Investigation
When inspecting Docker events:
→ No events were captured.
But with:
docker events --filter container=localstack-main \ --filter event=start --filter event=stop --filter event=kill \ --filter event=die --filter event=restart \ --format '{{json .}}'→ Events were captured correctly (
start,stop,die, etc.).This difference in formatting prevented the extension from correctly updating the container state.
Fix
--format '{{json .}}'when capturing Docker events.starting→runningandstopping→stopped.Verification
make vsix..vsixfile in VSCode.runningandstopped.