I thought that hiding generics behind a flag is already a thing in Go 1.17?
If a feature is solid enough for stable release, don't make it an opt-out.
People can just avoid the language features they don't want to use. I
disagree with the suggestion of adding stuffs to go.mod to enable or
Hi,
I suggest that you check on MacOs the File System Events API and on Linux
inotify or fanotify.
Here are links:
https://developer.apple.com/library/archive/documentation/Darwin/Conceptual/FSEvents_ProgGuide/UsingtheFSEventsFramework/UsingtheFSEventsFramework.html
I tried:
strconv.Quote()
strconv.AppendQuote() (weird that this is faster than Quote)
fmt.Sprintf("%q")
scanning for !IsPrint() + bytes.Buffer
scanning for !IsPrint() + strings.Builder (sad that this is not faster than
Buffer)
scanning for !IsPrint() + string addition
```
$ go test -benchtime=5s
Please don't send screen captures. They're hard to read and people can't
copy/paste the code. Ideally you would send a https://play.golang.org/ link
but simply copy/pasting your code into the email is fine too.
Note that file timestamp resolution depends on the system: both hardware
and OS. Even
On Thu, 14 Oct 2021 at 04:58, 'Tim Hockin' via golang-nuts <
golang-nuts@googlegroups.com> wrote:
> Thanks for confirming. I wrote that function and erased a good bit of the
> overhead.
>
> bytes.Buffer for the no-escapes path and strconv.Quote otherwise.
>
Could you not use strconv.AppendQuote
Your application should never panic. If the cookie is invalid, treat it as
if the cookie were not set at all, and redirect to the login page.
As for security: I urge you to think again. I can see your postgres
instance blocks connections from unknown source IPs in pg_hba.conf, but
that's a
Answering the first one, my server panics with the error: secure cookie:
the value is invalid.
The error occurs if I restart the server and the session is saved in the
browser.
For me, it's enough just to delete this value from the browser so that the
server starts without panic,
but I would
It turns out that the bad options were in the pkg-config for ncurses on my
computer. Once I deleted them from the pkg-config files for ncurses and all
related items, the problem went away and github.com/gbin/goncurses worked
as expected.
On Monday, October 11, 2021 at 12:40:01 AM UTC-4 Ian
1. If you are getting a panic, then you should show the complete error
message together with the backtrace, and it will help someone diagnose
what's going on. I don't think that simply having stale sessions in your
cookie store should cause your program to crash. Indeed, that's one of the