Open liveHarshit opened 4 months ago
What do you use go version? Recently go version of air is updated at here. I also had encouted same problem today. so I updated to go 1.22 in my docker environment, so I cloud resolve it.
So, Please try to update Go version 1.22.
I agree with @liveHarshit that this is indeed a breaking change.
As per official readme, it should be possible to do go install
using go 1.18:
Same happened to me. Trying to build my Docker container based on Go 1.20 and got:
github.com/cosmtrek/air/runner: cannot compile Go 1.22 code
Update to 1.22 did work, but is there a way to get it fixed without changing the Go version?
@yuyuyu0905 I have to do go install github.com/cosmtrek/air@v1.49.0
Same happened to me today, Changed it to go install github.com/air-verse/air@latest
Latest air package is breaking v1.50.0
failed to solve: process "/bin/sh -c go install github.com/cosmtrek/air@latest" did not complete successfully: exit code: 1