-
Notifications
You must be signed in to change notification settings - Fork 164
Description
What happened?
When I make lint in chat, I met this error. As follows. I don't know how to solve.
cmd/api/admin-api/main.go:28:2: could not import github.com/OpenIMSDK/chat/pkg/common/config (-: # github.com/OpenIMSDK/chat/pkg/common/config
pkg/common/config/config.go:113:1: syntax error: non-declaration statement outside function body
pkg/common/config/config.go:115:1: syntax error: imports must appear before other declarations
pkg/common/config/im.go:71:1: syntax error: non-declaration statement outside function body
pkg/common/config/parse.go:164:1: syntax error: non-declaration statement outside function body
pkg/common/config/parse.go:166:1: syntax error: imports must appear before other declarations) (typecheck)
"github.com/OpenIMSDK/chat/pkg/common/config"
^
cmd/api/chat-api/main.go:31:2: could not import github.com/OpenIMSDK/chat/pkg/common/config (-: # github.com/OpenIMSDK/chat/pkg/common/config
pkg/common/config/config.go:113:1: syntax error: non-declaration statement outside function body
pkg/common/config/config.go:115:1: syntax error: imports must appear before other declarations
pkg/common/config/im.go:71:1: syntax error: non-declaration statement outside function body
pkg/common/config/parse.go:164:1: syntax error: non-declaration statement outside function body
pkg/common/config/parse.go:166:1: syntax error: imports must appear before other declarations) (typecheck)
"github.com/OpenIMSDK/chat/pkg/common/config"
^
cmd/rpc/admin-rpc/main.go:26:2: could not import github.com/OpenIMSDK/chat/pkg/common/config (-: # github.com/OpenIMSDK/chat/pkg/common/config
pkg/common/config/config.go:113:1: syntax error: non-declaration statement outside function body
pkg/common/config/config.go:115:1: syntax error: imports must appear before other declarations
pkg/common/config/im.go:71:1: syntax error: non-declaration statement outside function body
pkg/common/config/parse.go:164:1: syntax error: non-declaration statement outside function body
pkg/common/config/parse.go:166:1: syntax error: imports must appear before other declarations) (typecheck)
"github.com/OpenIMSDK/chat/pkg/common/config"
^
cmd/rpc/chat-rpc/main.go:26:2: could not import github.com/OpenIMSDK/chat/pkg/common/config (-: # github.com/OpenIMSDK/chat/pkg/common/config
pkg/common/config/config.go:113:1: syntax error: non-declaration statement outside function body
pkg/common/config/config.go:115:1: syntax error: imports must appear before other declarations
pkg/common/config/im.go:71:1: syntax error: non-declaration statement outside function body
pkg/common/config/parse.go:164:1: syntax error: non-declaration statement outside function body
pkg/common/config/parse.go:166:1: syntax error: imports must appear before other declarations) (typecheck)
"github.com/OpenIMSDK/chat/pkg/common/config"
^
tools/component/component.go:5:2: could not import github.com/OpenIMSDK/chat/pkg/common/config (-: # github.com/OpenIMSDK/chat/pkg/common/config
pkg/common/config/config.go:113:1: syntax error: non-declaration statement outside function body
pkg/common/config/config.go:115:1: syntax error: imports must appear before other declarations
pkg/common/config/im.go:71:1: syntax error: non-declaration statement outside function body
pkg/common/config/parse.go:164:1: syntax error: non-declaration statement outside function body
pkg/common/config/parse.go:166:1: syntax error: imports must appear before other declarations) (typecheck)
"github.com/OpenIMSDK/chat/pkg/common/config"
^
make: *** [Makefile:240: lint] Error 1
What did you expect to happen?
none
How can we reproduce it (as minimally and precisely as possible)?
none
Anything else we need to know?
No response
version
Cloud provider
OS version
Install tools
Checklist
-
pkg/common/config/config.go
⚠️ No Changes Made -
pkg/common/config/im.go
✅ Commite8618aa
-
pkg/common/config/parse.go
⚠️ No Changes Made -
cmd/api/admin-api/main.go
⚠️ No Changes Made -
cmd/api/chat-api/main.go
⚠️ No Changes Made -
cmd/rpc/admin-rpc/main.go
⚠️ No Changes Made -
cmd/rpc/chat-rpc/main.go
⚠️ No Changes Made -
tools/component/component.go
⚠️ No Changes Made -
pkg/common/config/config.go
❌ Sandbox failed so I made additional changes -
pkg/common/config/im.go
❌ Sandbox failed so I made additional changes -
pkg/common/config/parse.go
❌ Sandbox failed so I made additional changes -
cmd/api/admin-api/main.go
❌ Sandbox failed so I made additional changes -
cmd/api/chat-api/main.go
❌ Sandbox failed so I made additional changes -
cmd/rpc/admin-rpc/main.go
❌ Sandbox failed so I made additional changes -
cmd/rpc/chat-rpc/main.go
❌ Sandbox failed so I made additional changes