Re: [go-nuts] `golang.org/x/tools/go/packages: unexpected new packages during load` when upgrading to 1.24.1

2025-03-07 Thread 'Jim Idle' via golang-nuts
It look like gosec can be told what version of Go it inspecting. The error sounds like it is saying that this package is not known to it, which would make sense if somewhere you have told it it is inspecting 1.23.6 as then this would be an unexpected package in that version of Go. Have you up

Re: [go-nuts] Looking for a SQLite statement parser

2024-11-26 Thread 'Jim Idle' via golang-nuts
I revamped the Go code generation not so long ago - performance is sound with reasonably well written grammars, and very good with good grammars. Unfortunately the sample grammars for SQL are poor and will give massive performance problems with all targets (Java, C++, etc). I decided not to spen

Re: [go-nuts] How to have panic messages show in a PowerShell console

2024-02-28 Thread 'Jim Idle' via golang-nuts
You should upgrade your Go installation to the latest version and retry. Go 1.6.3, if that is not a typo is very old. Jim On Feb 28 2024, at 11:35 am, Thom BENTLEY wrote: > Hi All, > > OS: Windows 10 > GoLang: go1.6.3 windows/386 > > I am trying to have a go executable run and show the panics it

Re: [go-nuts] Re: Weird error when trying to fetch a module.

2023-09-15 Thread 'Jim Idle' via golang-nuts
The go.mod at the root was one thing that might work, but it will cause the entire repo to be pulled in so the tag will still have to be sec/go/ etc. On Fri, Sep 15, 2023 at 15:15 Brian Candler wrote: > > Keep your go source at the root of the repo and tag that > > Or would it be OK just to put

Re: [go-nuts] Re: Parsing difficult JSON

2023-09-14 Thread 'Jim Idle' via golang-nuts
You can also unmarshal in stages to Raw and then unmarshal the next piece based on what you have so far. I presume that you cannot change the format? On Fri, Sep 15, 2023 at 01:05 Tobias Klausmann wrote: > Hi! > > On Thu, 14 Sep 2023, Brian Candler wrote: > > Could you just unmarshal it to a map

Re: [go-nuts] Re: Weird error when trying to fetch a module.

2023-09-14 Thread 'Jim Idle' via golang-nuts
It’s an absolute nightmare to publish modules from subdirectories. I gave up for ANTLR and created a new repo with the source code in the root directory. But the art is that you need to create a tag named with the subdirectory. I was able to make that work until we needed a v{n} tag. Which as far

Re: [go-nuts] Slog and error tracing

2023-08-10 Thread 'Jim Idle' via golang-nuts
You are logging the same error many times and then trying to solve that in the logs. Try this: Only log the error where it is handled, otherwise wrap it and return it without logging. At some point, you will log it as either an error if there is nothing you can do about it, or a warning if someho

Re: [go-nuts] go package dating back to 2009

2023-07-26 Thread 'Jim Idle' via golang-nuts
Decred is a project that was originally put together by someone who never claimed the moniker used by the originator. I suggest that 'Bravo Moua' is trying to claim authorship. HOwever, it is clear that I am Spartacus. https://thedecreddigest.wordpress.com/2017/06/10/decred-where-did-it-all-begi

Re: [go-nuts] [net.mail] ReadMessage returns nil, io.EOF when email w/o body.

2023-07-18 Thread 'Jim Idle' via golang-nuts
If you are doing any serious email work, you might find that the enmime module is useful. https://github.com/jhillyerd/enmime And perhaps this: https://github.com/gatherstars-com/jwz Jim On Wed, Jul 19, 2023 at 9:07 AM Karan Gupta wrote: > That is correct. It is the same issue. > Thanks for

Re: [go-nuts] Go routines consuming memory

2023-06-06 Thread 'Jim Idle' via golang-nuts
gt; And the use of ChatGPT to create some of the examples caused an eye-roll > so strong I was surprised it didn't physically hurt. > > On Tue, Jun 6, 2023 at 8:29 PM 'Jim Idle' via golang-nuts < > golang-nuts@googlegroups.com> wrote: > >> This benchmark is w

Re: [go-nuts] Go routines consuming memory

2023-06-06 Thread &#x27;Jim Idle' via golang-nuts
This benchmark is worthless for all languages used. - Each Go routine will be given a 2K stack. - Go routines are managed by Go, threads by the operating system. - C# uses a thread pool. - There's a lot wrong with this article, not just with things being claimed about Go. - Bench

Re: [go-nuts] go mod download fails on docker for 1.20 (but not for 1.18)

2023-05-21 Thread &#x27;Jim Idle' via golang-nuts
My guess is that IPV6 is disabled in your containers. If you use docker run -it xxx yyy -c "ip -6 addr show dev eth0; ip -6 route show" Then you can find out if that is the case. On Mon, May 22, 2023 at 8:29 AM Joao Miguel Ferreira < joao.miguel.c.ferre...@gmail.com> wrote: > Hello all, > > My

Re: [go-nuts] Avoid forcing my module users' to carry dependencies from code that live under the same repo just as examples/ debugging purposes.

2023-04-15 Thread Jim Idle
; golang-nuts@googlegroups.com> wrote: > On Fri, 2023-04-14 at 14:01 +0800, Jim Idle wrote: > > You might start with this repo: > > > > https://github.com/golang-standards/project-layout > > > > This is not an 'official' standard, though it does encapsula

Re: [go-nuts] Avoid forcing my module users' to carry dependencies from code that live under the same repo just as examples/ debugging purposes.

2023-04-13 Thread Jim Idle
You might start with this repo: https://github.com/golang-standards/project-layout This is not an 'official' standard, though it does encapsulate the things that are standard go such as the internal directory. Personally I avoid its recommendation to use a directory 'pkg' to store your module co

[go-nuts] Re: Correctly tagging a module in a subdirectory of a Github repo

2023-03-03 Thread Jim Idle
s" Am I on the right path? Sorry to speculate here on the group, but I cannot just go start messing around on the master branch and testing it out, or I would have done so. Jim On Saturday, March 4, 2023 at 12:09:48 PM UTC+8 Jim Idle wrote: > For historic reasons, which are too diffi

[go-nuts] Correctly tagging a module in a subdirectory of a Github repo

2023-03-03 Thread Jim Idle
For historic reasons, which are too difficult to change (and pre-modules), the runtime module for the ANTLR v4 Go runtime is held in a subdirectory of the antlr/antlr4 Github repo. This is complicated by the fact that organizations have written scripts into their build to copy the source code into

Re: [go-nuts] Creating and Linking to Shared Library Version of Go Runtime? (with possible solution)

2023-01-30 Thread Jim Idle
Looking back at your posts, I think you got there because your initial build of the shared library was via sudo? I don’t think that was correct and you didn’t need sudo. If the shared library only contained code needed for your executable, then it could only be shared by other instances of your ex

Re: [go-nuts] Re: Changes to x509 in Go 1.18

2022-03-28 Thread Jim Idle
considered > valid that go1.18 does not? If so, can you file an issue at > https://github.com/golang/go/issues for investigation? > > On Thursday, March 24, 2022 at 2:10:10 AM UTC-4 Jim Idle wrote: > >> Having just upgraded to 1.18, I find that quite a few encrypted >>

Re: [go-nuts] Changes to x509 in Go 1.18

2022-03-28 Thread Jim Idle
On Mar 29, 2022 at 2:48:34 AM, Davanum Srinivas wrote: > Jim, > > Looks like we ended up seeing the same problem in a kubernetes test case > as well: > https://github.com/kubernetes/kubernetes/issues/108956 > > -- Dims > > On Thu, Mar 24, 2022 at 2:09 AM Jim Idle wrote

[go-nuts] Changes to x509 in Go 1.18

2022-03-23 Thread Jim Idle
Having just upgraded to 1.18, I find that quite a few encrypted connections, for instance https to a Neptune instance on AWS, now fail with: x509: “*.x.neptune.amazonaws.com” certificate is not standards compliant It seems to be related to this comment: https://cs.opensource.google/go/go

[go-nuts] JWZ Email Threading algorithm now available

2021-08-11 Thread Jim Idle
A few people were talking about email parsing etc on this forum, so perhaps this will be useful to some people: https://github.com/gatherstars-com/jwz Fully implements the JWZ Threading algorithm in go. It provides: - Threading via interface - Sort with custom comparator func - Walk wi

Re: [go-nuts] Re: Email threading package?

2021-08-10 Thread Jim Idle
Hi, I was going to need to write this anyway, so I took today to write it and the company decided we can open source it. I have literally just pushed it to github, so please report any problems if you try it out. I have not proofread and checked the documentation yet, so I have made it 0.9.0 for t

Re: [go-nuts] doubts

2021-07-12 Thread Jim Idle
If you are just starting out, I would use Iris rather than gin-gonic. You can then borrow from the many examples for that framework: https://github.com/iris-contrib/examples On Sun, Jul 11, 2021 at 1:38 AM Sree lekshmi MG wrote: > hey all i am the beginner in golang ,and now i want to slove *

Re: [go-nuts] Fwd: protoc-gen-go and go modules

2021-05-12 Thread Jim Idle
Create a separate module that contains only the .proto files and use the generate directive. You can then version that module and share it. If your client is some other language, you can generate Its code from the same repo at the same version using your CI. For instance generate a pip wheel as wel

[go-nuts] Code generation with LLVM bindings

2020-04-01 Thread Jim Idle
It isn't immediately obvious to me which package should be used to generate code using LLVM and go bindings. On the one hand there is this package: https://godoc.org/llvm.org/llvm/bindings/go/llvm But I also see this one: https://github.com/llir/llvm Which seems to be specifically about IR.

Re: [go-nuts] Proposal: provide runtime sigprocmask api to block some signal for go runtime

2019-08-14 Thread &#x27;Jim Idle' via golang-nuts
*Note that you must not use sigprocmask in multi-threaded processes, because each thread has its own signal mask and there is no single process signal mask. According to POSIX, the behavior of sigprocmask in a multi-threaded process is “unspecified”. * There is a lot more to signal handling than s

Re: [go-nuts] I know you cannot kill a goroutine, but ...

2019-08-12 Thread &#x27;Jim Idle' via golang-nuts
Good luck on your implementation. I suggest though that you will find too many issues like this to use go routines as the base model for a user. I looked in to threads as a model for jBASE and even with that model, it was going to be too fraught with difficulty. Unless you are considering a product