-
Notifications
You must be signed in to change notification settings - Fork 1k
manifest.json is empty after dep init #149
Comments
Same thing here, project located at $ go version
go version go1.7 darwin/amd64
$ go end
go: unknown subcommand "end"
Run 'go help' for usage.
$ go env
GOARCH="amd64"
GOBIN=""
GOEXE=""
GOHOSTARCH="amd64"
GOHOSTOS="darwin"
GOOS="darwin"
GOPATH="/Users/kemal/go"
GORACE=""
GOROOT="/usr/local/go"
GOTOOLDIR="/usr/local/go/pkg/tool/darwin_amd64"
CC="clang"
GOGCCFLAGS="-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/81/jzjhd4m15sq1cj31pt52f0gh0000gn/T/go-build586013334=/tmp/go-build -gno-record-gcc-switches -fno-common"
CXX="clang++"
CGO_ENABLED="1"
$ |
Just confirming that I also hit this and wrote about it in the google group. I can verify that |
Are your dependencies under |
Nope, I have an empty project with a fresh install of go. So, dependencies are nowhere to be found. Cloned https://github.com/pksunkara/whitespaces and ran |
@pksunkara Yep, that's it I think! It wouldn't save into the Steps to reproduce:
EDIT: Removed workaround - not relevant to this convo |
Well, I guess, first of all, we probably need to separate |
It happened to me too. So, I did:
so, what exactly is the purpose of manifest ? |
This analogy with npm helps me remember.
|
Right, but package.json does hold all dependencies. I know dep is pre-alpha, just wondering if manifest.json will also hold all dependencies as it matures. |
Yeah, according to the design spec I read previously, it is supposed to. |
(sorry, I've not had time to get to this one yet)
Standard constraint declarations in Overrides are applied globally, superceding constraints declared by all dependencies (including any dependencies in your own If you're accustomed to npm, especially older versions (pre-flattening), this all works a bit differently because We don't really have docs optimized for end users yet (pre-alpha, sorry!), but there's more info about the mechanics in the gps docs. |
Ah, my above statement was ambiguous. I meant that according to the spec manifest.json was supposed to hold the top level dependencies and any other overrides. Sorry about the wording "all dependencies" |
Sure, that's the most important thing. As it stands right now, this is not fulfilled, as it expects these direct dependencies to exist in $GOPATH/src. In any case, the project is awesome and I feel it's going in the right direction, so I'll keep trying to poke holes in it (in a very friendly manner :) 👍 |
Thanks! please do :) 🎉
mm, that's not the case. The only part of Of course, this issue is about cases in which that fails, and for some reason the resulting manifest is empty...and that's a bug, and I'm not sure why it's doing it. But if you're seeing behavior that makes it seem like |
Oh wait...maybe this is it. If this is all it is, then it's a super-easy fix. I'll look tonight :) |
Ah, so, it seems like we actually did this intentionally for the first round with |
For the record, I find it highly surprising (read: bad) that first-level deps are only in manifest.json conditionally. I expect all first-level deps to be there. |
Agreed, and that's definitely the plan for the revisited command set - #277 |
I also found this issue with empty manifest.json I just want to make sure that it is a bug and will be fix before release, right ? @sdboyer By the way, it's a nice tool and we will happy for supporting dep will be put into the go toolchain in the near future 👍 |
Yes, we do intend to change this behavior with the respeccing of init. |
Pull in parser code from godep as part of not using build
This should, finally, be fixed 😄 |
I was asked to open this issue in this thread.
After running
dep init
with an existing project (located at$GOPATH/src/bitbucket.org/company_name/project_name
),manifest.json
has an empty JSON object ({}
), butlock.json
has all the correct dependencies.I can provide more info if needed.
The text was updated successfully, but these errors were encountered: