Re: promplot - assistance with golang port

2021-01-25 Thread Mikolaj Kucharski
On Mon, Jan 25, 2021 at 09:04:03AM -0700, Aaron Bieber wrote:
> 
> > Thank you! <3
> >
> > Do you see something like this on your end by any chance?
> >
> > $ make modgo-gen-modules
> > malformed JSON string, neither array, object, number, string or atom, at 
> > character offset 0 (before "(end of string)") at 
> > /home/mkucharski/openbsd/ports/infrastructure/bin/../lib/OpenBSD/PortGen/Port.pm
> >  line 58.
> > *** Error 255 in /home/mkucharski/openbsd/mystuff/graphics/promplot 
> > (/home/mkucharski/openbsd/ports/lang/go/go.port.mk:183 'modgo-gen-modules')
> >
> > I know your port had MODGO_MODULES and MODGO_MODFILES generated, but I
> > just run above make command as a test and it failed.
> 
> Ya. There are a combo of things happening:
> 
> 1. https://proxy.golang.org/qvl.io/promplot/@v/v0.16.0.mod shows no
>dependencies
> 2. The version comparison check in the portgen code is incorrect and the
>versions listed on https://proxy.golang.org/qvl.io/promplot/@v/list
>are not being correctly chosen.
> 
> I have a in-tree diff that isn't ready yet, but fixes the issues. I am
> not sure why v0.16.0.mod shows no dependencies. It could be that
> upstream pushed it before actually having the deps filled out.. I
> haven't looked yet.

I see. Thanks again for helping me with creating the port.

-- 
Regards,
 Mikolaj



Re: promplot - assistance with golang port

2021-01-25 Thread Aaron Bieber


Mikolaj Kucharski writes:

> On Mon, Jan 25, 2021 at 07:48:09AM -0700, Aaron Bieber wrote:
>> On Mon, 25 Jan 2021 at 07:40:56 -0700, Aaron Bieber wrote:
>> > On Sun, 24 Jan 2021 at 14:38:01 +, Mikolaj Kucharski wrote:
>> > > If some kind soul could push me in the right direction, I would greatly
>> > > appreciate it. See reattached port, what I have so far.
>> > > 
>> > > On Fri, Jan 01, 2021 at 02:17:31PM +, Mikolaj Kucharski wrote:
>> > > > 
>> > > > I looking for a tool which can easily generate a screenshot from
>> > > > Prometheus metrics and I found https://github.com/qvl/promplot
>> > > > 
>> > > > I have work in progress port, but it fails to build with:
>> > > > 
>> > > > ...
>> > > >  go install -modcacherw -v -p 1 github.com/qvl/promplot ;  fi;
>> > > > cannot find module providing package github.com/qvl/promplot: working 
>> > > > directory is not part of a module
>> > > > *** Error 1 in . 
>> > > > (/home/mkucharski/openbsd/ports/lang/go/go.port.mk:153 'do-build')
>> > > > 
>> > > > Any idea what I'm doing wrong?
>> > 
>> > MODGO_MODNAME needs to be set to the actual Go module name. Not a git repo.
>> > 
>> > The module name will be the first like in the 'go.mod' file. In this case 
>> > it's
>> > "qvl.io/promplot".
>> > 
>> > Normally, I would recommend creating the initial port with portgen, but it
>> > seems that this program hits a few bugs. I'll poke at it and see if I can 
>> > come
>> > up with a fix.
>> > 
>> 
>> Attached is a portgen'd version (found the bug, but I need to do more 
>> testing).
>> 
>> This should be enough to get ya going!
>> 
>
> Thank you! <3
>
> Do you see something like this on your end by any chance?
>
> $ make modgo-gen-modules
> malformed JSON string, neither array, object, number, string or atom, at 
> character offset 0 (before "(end of string)") at 
> /home/mkucharski/openbsd/ports/infrastructure/bin/../lib/OpenBSD/PortGen/Port.pm
>  line 58.
> *** Error 255 in /home/mkucharski/openbsd/mystuff/graphics/promplot 
> (/home/mkucharski/openbsd/ports/lang/go/go.port.mk:183 'modgo-gen-modules')
>
> I know your port had MODGO_MODULES and MODGO_MODFILES generated, but I
> just run above make command as a test and it failed.

Ya. There are a combo of things happening:

1. https://proxy.golang.org/qvl.io/promplot/@v/v0.16.0.mod shows no
   dependencies
2. The version comparison check in the portgen code is incorrect and the
   versions listed on https://proxy.golang.org/qvl.io/promplot/@v/list
   are not being correctly chosen.

I have a in-tree diff that isn't ready yet, but fixes the issues. I am
not sure why v0.16.0.mod shows no dependencies. It could be that
upstream pushed it before actually having the deps filled out.. I
haven't looked yet.



Re: promplot - assistance with golang port

2021-01-25 Thread Mikolaj Kucharski
On Mon, Jan 25, 2021 at 07:48:09AM -0700, Aaron Bieber wrote:
> On Mon, 25 Jan 2021 at 07:40:56 -0700, Aaron Bieber wrote:
> > On Sun, 24 Jan 2021 at 14:38:01 +, Mikolaj Kucharski wrote:
> > > If some kind soul could push me in the right direction, I would greatly
> > > appreciate it. See reattached port, what I have so far.
> > > 
> > > On Fri, Jan 01, 2021 at 02:17:31PM +, Mikolaj Kucharski wrote:
> > > > 
> > > > I looking for a tool which can easily generate a screenshot from
> > > > Prometheus metrics and I found https://github.com/qvl/promplot
> > > > 
> > > > I have work in progress port, but it fails to build with:
> > > > 
> > > > ...
> > > >  go install -modcacherw -v -p 1 github.com/qvl/promplot ;  fi;
> > > > cannot find module providing package github.com/qvl/promplot: working 
> > > > directory is not part of a module
> > > > *** Error 1 in . (/home/mkucharski/openbsd/ports/lang/go/go.port.mk:153 
> > > > 'do-build')
> > > > 
> > > > Any idea what I'm doing wrong?
> > 
> > MODGO_MODNAME needs to be set to the actual Go module name. Not a git repo.
> > 
> > The module name will be the first like in the 'go.mod' file. In this case 
> > it's
> > "qvl.io/promplot".
> > 
> > Normally, I would recommend creating the initial port with portgen, but it
> > seems that this program hits a few bugs. I'll poke at it and see if I can 
> > come
> > up with a fix.
> > 
> 
> Attached is a portgen'd version (found the bug, but I need to do more 
> testing).
> 
> This should be enough to get ya going!
> 

Thank you! <3

Do you see something like this on your end by any chance?

$ make modgo-gen-modules
malformed JSON string, neither array, object, number, string or atom, at 
character offset 0 (before "(end of string)") at 
/home/mkucharski/openbsd/ports/infrastructure/bin/../lib/OpenBSD/PortGen/Port.pm
 line 58.
*** Error 255 in /home/mkucharski/openbsd/mystuff/graphics/promplot 
(/home/mkucharski/openbsd/ports/lang/go/go.port.mk:183 'modgo-gen-modules')

I know your port had MODGO_MODULES and MODGO_MODFILES generated, but I
just run above make command as a test and it failed.

-- 
Regards,
 Mikolaj



Re: promplot - assistance with golang port

2021-01-25 Thread Aaron Bieber
On Mon, 25 Jan 2021 at 07:40:56 -0700, Aaron Bieber wrote:
> On Sun, 24 Jan 2021 at 14:38:01 +, Mikolaj Kucharski wrote:
> > If some kind soul could push me in the right direction, I would greatly
> > appreciate it. See reattached port, what I have so far.
> > 
> > On Fri, Jan 01, 2021 at 02:17:31PM +, Mikolaj Kucharski wrote:
> > > 
> > > I looking for a tool which can easily generate a screenshot from
> > > Prometheus metrics and I found https://github.com/qvl/promplot
> > > 
> > > I have work in progress port, but it fails to build with:
> > > 
> > > ...
> > >  go install -modcacherw -v -p 1 github.com/qvl/promplot ;  fi;
> > > cannot find module providing package github.com/qvl/promplot: working 
> > > directory is not part of a module
> > > *** Error 1 in . (/home/mkucharski/openbsd/ports/lang/go/go.port.mk:153 
> > > 'do-build')
> > > 
> > > Any idea what I'm doing wrong?
> 
> MODGO_MODNAME needs to be set to the actual Go module name. Not a git repo.
> 
> The module name will be the first like in the 'go.mod' file. In this case it's
> "qvl.io/promplot".
> 
> Normally, I would recommend creating the initial port with portgen, but it
> seems that this program hits a few bugs. I'll poke at it and see if I can come
> up with a fix.
> 

Attached is a portgen'd version (found the bug, but I need to do more testing).

This should be enough to get ya going!

> > > 
> > 
> > -- 
> > Regards,
> >  Mikolaj
> 
> 


promplot.tgz
Description: Binary data


Re: promplot - assistance with golang port

2021-01-25 Thread Aaron Bieber
On Sun, 24 Jan 2021 at 14:38:01 +, Mikolaj Kucharski wrote:
> If some kind soul could push me in the right direction, I would greatly
> appreciate it. See reattached port, what I have so far.
> 
> On Fri, Jan 01, 2021 at 02:17:31PM +, Mikolaj Kucharski wrote:
> > 
> > I looking for a tool which can easily generate a screenshot from
> > Prometheus metrics and I found https://github.com/qvl/promplot
> > 
> > I have work in progress port, but it fails to build with:
> > 
> > ...
> >  go install -modcacherw -v -p 1 github.com/qvl/promplot ;  fi;
> > cannot find module providing package github.com/qvl/promplot: working 
> > directory is not part of a module
> > *** Error 1 in . (/home/mkucharski/openbsd/ports/lang/go/go.port.mk:153 
> > 'do-build')
> > 
> > Any idea what I'm doing wrong?

MODGO_MODNAME needs to be set to the actual Go module name. Not a git repo.

The module name will be the first like in the 'go.mod' file. In this case it's
"qvl.io/promplot".

Normally, I would recommend creating the initial port with portgen, but it
seems that this program hits a few bugs. I'll poke at it and see if I can come
up with a fix.

> > 
> 
> -- 
> Regards,
>  Mikolaj




Re: promplot - assistance with golang port

2021-01-24 Thread Mikolaj Kucharski
If some kind soul could push me in the right direction, I would greatly
appreciate it. See reattached port, what I have so far.

On Fri, Jan 01, 2021 at 02:17:31PM +, Mikolaj Kucharski wrote:
> 
> I looking for a tool which can easily generate a screenshot from
> Prometheus metrics and I found https://github.com/qvl/promplot
> 
> I have work in progress port, but it fails to build with:
> 
> ...
>  go install -modcacherw -v -p 1 github.com/qvl/promplot ;  fi;
> cannot find module providing package github.com/qvl/promplot: working 
> directory is not part of a module
> *** Error 1 in . (/home/mkucharski/openbsd/ports/lang/go/go.port.mk:153 
> 'do-build')
> 
> Any idea what I'm doing wrong?
> 

-- 
Regards,
 Mikolaj


promplot-0.16.0-port.tgz
Description: application/tar-gz


promplot - assistance with golang port

2021-01-01 Thread Mikolaj Kucharski
Hi,

I looking for a tool which can easily generate a screenshot from
Prometheus metrics and I found https://github.com/qvl/promplot

I have work in progress port, but it fails to build with:

...
 go install -modcacherw -v -p 1 github.com/qvl/promplot ;  fi;
cannot find module providing package github.com/qvl/promplot: working directory 
is not part of a module
*** Error 1 in . (/home/mkucharski/openbsd/ports/lang/go/go.port.mk:153 
'do-build')

Any idea what I'm doing wrong?

-- 
Regards,
 Mikolaj


promplot-0.16.0-port.tgz
Description: application/tar-gz