France
I'm Simon Ser, I write open-source software.
From Simon Ser to ~sircmpwn/sr.ht-dev
--- contrib/crontab | 1 + 1 file changed, 1 insertion(+) diff --git a/contrib/crontab b/contrib/crontab index a4acea47ceb6..080483e4ec96 100644 --- a/contrib/crontab +++ b/contrib/crontab @@ -22,6 +22,7 @@ 0 19 * * 5 chronic /usr/local/bin/submit_image_build -n "Weekly scheduled build image refresh" -a amd64 freebsd/13.x 0 19 * * 6 chronic /usr/local/bin/submit_image_build -n "Weekly scheduled build image refresh" -a amd64 openbsd/latest 30 19 * * 6 chronic /usr/local/bin/submit_image_build -n "Weekly scheduled build image refresh" -a x86_64 rockylinux/9 0 19 * * 7 chronic /usr/local/bin/submit_image_build -n "Weekly scheduled build image refresh" -a amd64 freebsd/14.x [message trimmed]
From Simon Ser to ~sircmpwn/sr.ht-dev
On Thursday, November 30th, 2023 at 22:18, Conrad Hoffmann <ch@bitfehler.net> wrote: > Can you confirm that this is the same pattern and should be fixed also? > > https://git.sr.ht/~sircmpwn/todo.sr.ht/tree/master/item/api/trackers/import.go#L190-206 Yup, looks like it. This is not the first time I'm fixing one of these, and there may be more.
From Simon Ser to ~sircmpwn/sr.ht-dev
In case a panic happened, not doing anything will continue to unwind the stack. Not doing anything is actually better because that avoids loosing the original panic's stack trace. --- api/lists/middleware.go | 6 ------ 1 file changed, 6 deletions(-) diff --git a/api/lists/middleware.go b/api/lists/middleware.go index f9da37da0b72..f7113a8a2b06 100644 --- a/api/lists/middleware.go +++ b/api/lists/middleware.go @@ -39,8 +39,6 @@ func ImportMailingListSpool(ctx context.Context, listID int, spool io.Reader) { defer cancel() [message trimmed]
From Simon Ser to ~sircmpwn/sr.ht-dev
On Thursday, November 30th, 2023 at 16:30, Conrad Hoffmann <ch@bitfehler.net> wrote: > On 11/30/23 16:22, Simon Ser wrote: > > > On Thursday, November 30th, 2023 at 16:18, Conrad Hoffmann ch@bitfehler.net wrote: > > > > > 1. On export, we are modifying the patch email (adding the status > > > header), breaking DKIM along the way, and sort of, I don't know, > > > rewriting history? > > > > Not really. Prepending extra header fields to an e-mail is a typical > > thing to do to an email, the DKIM signature won't be broken because it > > doesn't cover the new header field. For instance, lists.sr.ht will > > prepend List-* and Sender, destination email servers will prepend
From Simon Ser to ~sircmpwn/sr.ht-dev
On Thursday, November 30th, 2023 at 16:18, Conrad Hoffmann <ch@bitfehler.net> wrote: > 1. On export, we are modifying the patch email (adding the status > header), breaking DKIM along the way, and sort of, I don't know, > rewriting history? Not really. Prepending extra header fields to an e-mail is a typical thing to do to an email, the DKIM signature won't be broken because it doesn't cover the new header field. For instance, lists.sr.ht will prepend List-* and Sender, destination email servers will prepend Received, etc. > 2. If this change goes live as is, imports of data that was created > before this change will not import any patchset status
From Simon Ser to ~sircmpwn/sr.ht-dev
Let's just use the toplevel go.mod instead. This upgrades core-go for the worker, so a small adjustment of JobContext.oauth2Token is required. --- go.mod | 10 + go.sum | 34 ++ worker/go.mod | 23 -- worker/go.sum | 837 ------------------------------------------------ worker/tasks.go | 4 +- 5 files changed, 46 insertions(+), 862 deletions(-) delete mode 100644 worker/go.mod delete mode 100644 worker/go.sum [message trimmed]
From Simon Ser to ~sircmpwn/sr.ht-dev
v1 is not maintained anymore. --- go.mod | 2 +- go.sum | 4 ++-- server/server.go | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/go.mod b/go.mod index 987ca5da69a6..875aef83b5c9 100644 --- a/go.mod +++ b/go.mod @@ -15,7 +15,7 @@ require ( github.com/emersion/go-sasl v0.0.0-20220912192320-0145f2c60ead github.com/emersion/go-smtp v0.18.0 [message trimmed]
From Simon Ser to ~sircmpwn/sr.ht-dev
Checking context.Cancelled is not enough, I also see the same issue
with context.DeadlineExceeded:
panic: Transaction error: driver: bad connection
Closure error: context deadline exceeded
goroutine 66664 [running]:
git.sr.ht/~sircmpwn/core-go/database.WithTx({0x5578e1847a58, 0xc0002c44e0}, 0x50?, 0xc000285f38)
git.sr.ht/~sircmpwn/core-go@v0.0.0-20231129165057-e7b8e02696a1/database/middleware.go:74 +0x2ce
git.sr.ht/~sircmpwn/builds.sr.ht/api/loaders.fetchUsersByID.func1({0xc0002cf190, 0x1, 0x1})
git.sr.ht/~sircmpwn/builds.sr.ht/api/loaders/middleware.go:34 +0x118
git.sr.ht/~sircmpwn/builds.sr.ht/api/loaders.(*usersByIDLoaderBatch).end(...)
git.sr.ht/~sircmpwn/builds.sr.ht/api/loaders/usersbyidloader_gen.go:222
git.sr.ht/~sircmpwn/builds.sr.ht/api/loaders.(*usersByIDLoaderBatch).startTimer(0xc00044a360, 0xc00042d380)
[message trimmed]
From Simon Ser to ~emersion/hut-dev
--- doc/hut.1.scd | 2 +- import.go | 20 +++++++++++++------- 2 files changed, 14 insertions(+), 8 deletions(-) diff --git a/doc/hut.1.scd b/doc/hut.1.scd index f8581c89473b..1b1ce0ee60dd 100644 --- a/doc/hut.1.scd +++ b/doc/hut.1.scd @@ -86,7 +86,7 @@ Additionally, mailing lists can be referred to by their email address. *export* <directory> Export account data. *import* <directory>[message trimmed]
From Simon Ser to ~emersion/hut-dev
I've addressed the remaining points, and pushed a version with these changes: - The filepath.Walk was effectively iterating recursively over all files in the imported directory. This is unnecessary, no need to walk a dir if there is an info.json there. - The PGP import was silently ignoring malformed files. A warning is now printed. - Added an error in case we find nothing to import in the directory. Thanks!