Comments (8)
Can you run:
go get -u github.com/masseelch/render
go get -u github.com/liip/sheriff
goimports -w .
go run -mod=mod main.go
I will set up a clean GO_ENV this evening and try to reproduce the issue. Might have something to with cached packages by go get
.
from elk.
Hey @imperiutx, thank you for reaching out and reporting this.
Can you please show me the contents of your go.mod
file?
Does goimports -w .
add the missing imports?
from elk.
The contents of go.mod file:
module elk-example
go 1.16
require (
entgo.io/ent v0.8.1-0.20210720072308-756517e559eb
github.com/go-chi/chi/v5 v5.0.3
github.com/go-playground/validator/v10 v10.7.0
github.com/leodido/go-urn v1.2.1 // indirect
github.com/lib/pq v1.10.2
go.uber.org/atomic v1.8.0 // indirect
go.uber.org/multierr v1.7.0 // indirect
go.uber.org/zap v1.18.1
golang.org/x/crypto v0.0.0-20210616213533-5ff15b29337e // indirect
golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c // indirect
golang.org/x/text v0.3.6 // indirect
)
I tried to install goimports but it returned:
go imports -w .
go imports: unknown command
from elk.
The correct command is goimports
instead of go imports
. Note the missing space. So in whole:
goimports -w .
in the root of your project (most likely elk-example
).
from elk.
I'm sorry, my bad. After re-run the commands below, the errors are still there:
➜ elk-example go generate ./...
go: finding module for package github.com/masseelch/elk
go: found github.com/masseelch/elk in github.com/masseelch/elk v0.2.2
➜ elk-example goimports -w .
➜ elk-example go run -mod=mod main.go
# elk-example/ent/http
ent/http/create.go:28:3: undefined: render
ent/http/create.go:42:3: undefined: render
ent/http/create.go:53:4: undefined: render
ent/http/create.go:56:4: undefined: render
ent/http/create.go:60:12: undefined: sheriff
ent/http/create.go:66:3: undefined: render
ent/http/create.go:70:2: undefined: render
ent/http/create.go:84:3: undefined: render
ent/http/create.go:92:3: undefined: render
ent/http/create.go:103:4: undefined: render
ent/http/create.go:103:4: too many errors
from elk.
Weird 🤔 I'll look into it. Sorry for the inconvenience!
from elk.
After running the above commands, server is running. Thank you for your support
from elk.
Glad i could help. I will update the post. Thank you again for reporting this!
from elk.
Related Issues (20)
- Does not generate when using other types for IDs HOT 7
- Provide elk command HOT 7
- no OAS-type exists for field.JSON fields HOT 8
- Consider generating a client? HOT 9
- Remove arbitrary numbers in OpenApi JSON objects HOT 12
- Chi will not compile HOT 1
- Generate http handler with errors "invalid import path" HOT 6
- Curl add user HOT 20
- Update Error Message / HTTP Folder HOT 8
- Missing zap import? HOT 3
- Question: How to change JSON-output specification HOT 3
- Go module indirect dependency HOT 3
- missing required field "name" HOT 1
- question if elk solves this ent deficit HOT 1
- How do you deal with sanitization? HOT 3
- Open api async ? HOT 2
- no OAS-type exists for "[]byte" HOT 3
- easyjson complains when generating code to a different package.
- Problem testing the ent-elk crud example HOT 2
- Support other framework (e.g. gin/echo). HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from elk.