air-verse / air

☁️ Live reload for Go apps

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

panic: unaligned 64-bit atomic operation in windows

liangruifeng opened this issue · comments

commented

PS E:\test\ginlearn> air


/ /\ | | | |)
/
/--\ || || _ v1.52.0, built with Go go1.22.3

watching .
!exclude tmp
building...
running...
panic: unaligned 64-bit atomic operation

goroutine 18 [running]:
runtime/internal/atomic.panicUnaligned()
C:/Users/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.3.windows-386/src/runtime/internal/atomic/unaligned.go:8 +0x2b
runtime/internal/atomic.Xadd64(0x2027b7c, 0x1)
C:/Users/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.3.windows-386/src/runtime/internal/atomic/atomic_386.s:125 +0x11
github.com/cosmtrek/air/runner.(*Engine).runBin.func2()
C:/Users/go/pkg/mod/github.com/cosmtrek/air@v1.52.0/runner/engine.go:550 +0x335
created by github.com/cosmtrek/air/runner.(*Engine).runBin in goroutine 10
C:/Users/go/pkg/mod/github.com/cosmtrek/air@v1.52.0/runner/engine.go:522 +0xd3

commented

btw, my windows is 64-bit

这个问题我也遇到了,版本:air v1.52.0, built with Go go1.22.3
重新安装 64位go安装包 解决了,应该加个“go版本与本机操作系统位数不匹配”的提示,配上解决方案。

found out the root cause, will fix in next version tks

Hello, I am on a Windows 11 Amd Ryzen 3 7320U and I am facing the same issue when I run the air command.

CODE BELOW

air

  __    _   ___  
 / /\  | | | |_) 
/_/--\ |_| |_| \_ v1.52.2, built with Go go1.22.3

watching .
watching controllers
watching initializers
watching models
!exclude tmp
building...
!exclude .git
!exclude .git
running...
panic: unaligned 64-bit atomic operation

goroutine 23 [running]:
runtime/internal/atomic.panicUnaligned()
        C:/Program Files (x86)/Go/src/runtime/internal/atomic/unaligned.go:8 +0x2b
runtime/internal/atomic.Xadd64(0x2031b0c, 0x1)
        C:/Program Files (x86)/Go/src/runtime/internal/atomic/atomic_386.s:125 +0x11
github.com/air-verse/air/runner.(*Engine).runBin.func2()
        C:/Users/henry/go/pkg/mod/github.com/air-verse/air@v1.52.2/runner/engine.go:550 +0x335
created by github.com/air-verse/air/runner.(*Engine).runBin in goroutine 22
        C:/Users/henry/go/pkg/mod/github.com/air-verse/air@v1.52.2/runner/engine.go:522 +0xd3

got that, wil fixed within this week