Re: [go-nuts] package is not in GOROOT

2021-04-09 Thread rob
Thanks. If only the docs would make that clear. My experience with reading them is: clear only if previously known. Much frustration about modules could have been avoided by more clearly written documentation So it goes -- rob drrob...@fastmail.com On Fri, Apr 9, 2021, at 11:

Re: [go-nuts] package is not in GOROOT

2021-04-09 Thread 'wagner riffel' via golang-nuts
On Wed, 7 Apr 2021 20:11:22 -0400 rob wrote: > Would it be a bad idea to use my ~go/src as a module? > I don't think so, I do have one global module like this for my own toys and throwaways programs. Yes, it would need to adjust your import paths according to the module, when I migrated to modu

Re: [go-nuts] package is not in GOROOT

2021-04-07 Thread 'Carla Pfaff' via golang-nuts
On Thursday, 8 April 2021 at 02:11:50 UTC+2 rob wrote: > Yes, you are absolutely correct that I've been struggling w/ modules. > > Would it be a bad idea to use my ~go/src as a module? > > cd ~/go/src > > go mod init src > > go mod tidy --> do I need this? > > And then I would have

Re: [go-nuts] package is not in GOROOT

2021-04-07 Thread rob
Yes, you are absolutely correct that I've been struggling w/ modules. Would it be a bad idea to use my ~go/src as a module?   cd ~/go/src   go mod init src   go mod tidy --> do I need this? And then I would have to edit my import statements slightly to include the module reference. --r

Re: [go-nuts] package is not in GOROOT

2021-04-07 Thread rob
It does help me. Thanks -- rob drrob...@fastmail.com On Wed, Apr 7, 2021, at 10:24 AM, wagner riffel wrote: > On Tue, 6 Apr 2021 19:39:00 -0400 > rob wrote: > > > > This example is on Win10 using go 1.16.3 > > > > Now I've created a directory tree outside of ~/go/src.  I'm using ~ > >

Re: [go-nuts] package is not in GOROOT

2021-04-07 Thread 'wagner riffel' via golang-nuts
On Tue, 6 Apr 2021 19:39:00 -0400 rob wrote: > > This example is on Win10 using go 1.16.3 > > Now I've created a directory tree outside of ~/go/src.  I'm using ~ > to mean %userprofile%, as this is win10 > > ~/gcode/rpng/rpng.go > > ~/gcode/tokenize/tokenize.go > > ~/gcode/hpcalc2/hpcalc2.go

[go-nuts] package is not in GOROOT

2021-04-06 Thread rob
> This example is on Win10 using go 1.16.3 Now I've created a directory tree outside of ~/go/src.  I'm using ~ to mean %userprofile%, as this is win10 ~/gcode/rpng/rpng.go ~/gcode/tokenize/tokenize.go ~/gcode/hpcalc2/hpcalc2.go And I updated my import statement to be "gcode/hpcalc2", etc.

[go-nuts] package is not in GOROOT

2021-04-05 Thread rob
I'm still struggling w/ modules to get my code to compile.  This example is on Win10 using go 1.16.3 ~/go/src/rpng/rpng.go ~/go/src/tokenize/tokenize.go ~/go/src/hpcalc2/hpcalc2.go I'm logged into ~/go/src and I type this, like I used to do in the "old" days:     go install rpng Now I get

Re: [go-nuts] package is not in goroot

2021-01-20 Thread Marvin Renich
* Jan Mercl <0xj...@gmail.com> [210120 15:27]: > On Wed, Jan 20, 2021 at 9:03 PM Marvin Renich wrote: > > > I still cannot find any mention of reserved import paths in any > > documentation (go help modules/importpath/gopath). It's just an issue > > on the tracker. > > When an important part of

Re: [go-nuts] package is not in goroot

2021-01-20 Thread Jan Mercl
On Wed, Jan 20, 2021 at 9:03 PM Marvin Renich wrote: > I still cannot find any mention of reserved import paths in any > documentation (go help modules/importpath/gopath). It's just an issue > on the tracker. When an important part of the implementation is undocumented then it's a documentation

Re: [go-nuts] package is not in goroot

2021-01-20 Thread Marvin Renich
* Jan Mercl <0xj...@gmail.com> [210120 10:46]: > On Wed, Jan 20, 2021 at 3:57 PM Marvin Renich wrote: > > > I don't understand what you are saying. What is a "reserved import > > path" and where is it defined? > > See https://github.com/golang/go/issues/32819 ??? Thanks for pointing this out!

Re: [go-nuts] package is not in goroot

2021-01-20 Thread Jan Mercl
On Wed, Jan 20, 2021 at 3:57 PM Marvin Renich wrote: > I don't understand what you are saying. What is a "reserved import > path" and where is it defined? See https://github.com/golang/go/issues/32819 -- You received this message because you are subscribed to the Google Groups "golang-nuts"

Re: [go-nuts] package is not in goroot

2021-01-20 Thread Marvin Renich
* Marvin Renich [210120 09:58]: > * Jan Mercl <0xj...@gmail.com> [210120 09:32]: > > On Wed, Jan 20, 2021 at 2:58 PM Marvin Renich wrote: > > > > > The error message is really incomplete, and therefore confusing. It > > > should be "package ... is not in GOROOT or any element of GOPATH". > > >

Re: [go-nuts] package is not in goroot

2021-01-20 Thread Marvin Renich
* Jan Mercl <0xj...@gmail.com> [210120 09:32]: > On Wed, Jan 20, 2021 at 2:58 PM Marvin Renich wrote: > > > The error message is really incomplete, and therefore confusing. It > > should be "package ... is not in GOROOT or any element of GOPATH". > > _That_ would be incorrect and confusing. Res

Re: [go-nuts] package is not in goroot

2021-01-20 Thread Jan Mercl
On Wed, Jan 20, 2021 at 2:58 PM Marvin Renich wrote: > The error message is really incomplete, and therefore confusing. It > should be "package ... is not in GOROOT or any element of GOPATH". _That_ would be incorrect and confusing. Reserved import paths are never searched for in GOPATH. -- Y

Re: [go-nuts] package is not in goroot

2021-01-20 Thread Marvin Renich
* Alexander Mills [210119 16:54]: > i am getting this weird error message: > > package twitch/go-scripts/dynamo-creators-to-s3/lib is not in GOROOT > (/usr/local/Cellar/go/1.15.6/libexec/src/twitch/go-scripts/dynamo-creators-to-s3/lib) > > my GOPATH=$PWD/scripts/go > > so there is only 1 GOPA

Re: [go-nuts] package is not in goroot

2021-01-19 Thread 'Dan Kortschak' via golang-nuts
On Tue, 2021-01-19 at 16:08 -0800, Alexander Mills wrote: > I have never seen the dot needed, I have used plenty of packages that > are in GOPATH but not GOROOT https://go.googlesource.com/go/+/go1.15.6/src/cmd/go/internal/search/search.go#542 This is why it is saying that it's expecting it to b

Re: [go-nuts] package is not in goroot

2021-01-19 Thread Alexander Mills
I have never seen the dot needed, I have used plenty of packages that are in GOPATH but not GOROOT On Tue, Jan 19, 2021 at 2:04 PM 'Dan Kortschak' via golang-nuts wrote: > > On Tue, 2021-01-19 at 13:54 -0800, Alexander Mills wrote: > > i am getting this weird error message: > > > > package twitc

Re: [go-nuts] package is not in goroot

2021-01-19 Thread 'Dan Kortschak' via golang-nuts
On Tue, 2021-01-19 at 13:54 -0800, Alexander Mills wrote: > i am getting this weird error message: > > package twitch/go-scripts/dynamo-creators-to-s3/lib is not in GOROOT > (/usr/local/Cellar/go/1.15.6/libexec/src/twitch/go-scripts/dynamo- > creators-to-s3/lib) > > my GOPATH=$PWD/scripts/go >

[go-nuts] package is not in goroot

2021-01-19 Thread Alexander Mills
i am getting this weird error message: package twitch/go-scripts/dynamo-creators-to-s3/lib is not in GOROOT (/usr/local/Cellar/go/1.15.6/libexec/src/twitch/go-scripts/dynamo-creators-to-s3/lib) my GOPATH=$PWD/scripts/go so there is only 1 GOPATH [image: Screen Shot 2021-01-19 at 1.52.30 PM.pn