12f4ea03a8
refactor: add /v3 suffix to module path for proper Go semver
...
Build and Release / Create Release (push) Successful in 0s
Trigger Vault Plugin Rebuild / Trigger Vault Rebuild (push) Successful in 0s
Build and Release / Integration Tests (PostgreSQL) (push) Successful in 2m48s
Build and Release / Lint (push) Failing after 5m2s
Build and Release / Build Binaries (amd64, windows, windows-latest) (push) Has been skipped
Build and Release / Build Binaries (amd64, darwin, linux-latest) (push) Has been skipped
Build and Release / Build Binaries (amd64, linux, linux-latest) (push) Has been skipped
Build and Release / Build Binaries (arm64, darwin, linux-latest) (push) Has been skipped
Build and Release / Build Binaries (arm64, linux, linux-latest) (push) Has been skipped
Build and Release / Unit Tests (push) Successful in 5m37s
Go's semantic import versioning requires v2+ modules to include the
major version in the module path. This enables using proper version
tags (v3.x.x) instead of pseudo-versions.
Updated module path: code.gitcaddy.com/server/v3
2026-01-17 17:53:59 -05:00
af6d4addd4
code.caddy rename
Build and Release / Create Release (push) Successful in 0s
Build and Release / Integration Tests (PostgreSQL) (push) Successful in 3m7s
Build and Release / Lint (push) Successful in 5m21s
Build and Release / Unit Tests (push) Successful in 5m46s
Build and Release / Build Binaries (amd64, linux, linux-latest) (push) Successful in 3m44s
Build and Release / Build Binaries (amd64, darwin, linux-latest) (push) Successful in 4m4s
Build and Release / Build Binaries (arm64, darwin, linux-latest) (push) Successful in 3m23s
Build and Release / Build Binaries (arm64, linux, linux-latest) (push) Successful in 3m47s
Build and Release / Build Binaries (amd64, windows, windows-latest) (push) Successful in 8h6m28s
2026-01-17 09:02:21 -05:00
6543
2ab56829f5
Add proper error message if session provider can not be created ( #35520 )
...
the middleware that creates the session provider just panics if on
creation the config is wrong.
this is not catched and so you just get an cryptic stacktrace with no
point where to look at (as user).
## Before
```
2025/09/16 03:56:37 ...xer/stats/indexer.go:87:populateRepoIndexer() [I] Done (re)populating the repo stats indexer with existing repositories
2025/09/16 03:56:37 modules/ssh/ssh.go:387:Listen() [I] Adding SSH host key: /var/lib/gitea/data/ssh/gitea.rsa
2025/09/16 03:56:37 modules/ssh/init.go:26:Init() [I] SSH server started on :1234. Cipher list ([chacha20-poly1305@openssh.com aes128-ctr aes192-ctr aes256-ctr aes128-gcm@openssh.com aes256-gcm@openssh.com ]), key exchange algorithms ([curve25519-sha256 ecdh-sha2-nistp256 ecdh-sha2-nistp384 ecdh-sha2-nistp521 diffie-hellman-group14-sha256 diffie-hellman-group14-sha1]), MACs ([hmac-sha2-256-etm@openssh.com hmac-sha2-256 hmac-sha1])
2025/09/16 03:56:37 ...s/graceful/server.go:50:NewServer() [I] Starting new SSH server: tcp::1234 on PID: 83337
2025/09/16 03:56:38 cmd/web.go:231:func1() [F] PANIC: dial tcp 127.0.0.1:6379: connect: connection refused
gitea.com/go-chi/session@v0.0.0-20240316035857-16768d98ec96/session.go:239 (0x1cdb908)
code.gitea.io/gitea/routers/common/middleware.go:108 (0x2547f5a)
code.gitea.io/gitea/routers/web/web.go:270 (0x278b8e9)
code.gitea.io/gitea/routers/init.go:185 (0x2850d89)
code.gitea.io/gitea/cmd/web.go:211 (0x295c5ad)
code.gitea.io/gitea/cmd/web.go:262 (0x295cacb)
code.gitea.io/gitea/cmd/main.go:111 (0x2953422)
github.com/urfave/cli/v2@v2.27 .2/command.go:276 (0x1cc3dfd)
github.com/urfave/cli/v2@v2.27 .2/command.go:269 (0x1cc4084)
github.com/urfave/cli/v2@v2.27 .2/app.go:333 (0x1cc086a)
github.com/urfave/cli/v2@v2.27 .2/app.go:307 (0x2953f18)
code.gitea.io/gitea/cmd/main.go:172 (0x2953efc)
code.gitea.io/gitea/main.go:46 (0x2998498)
runtime/proc.go:283 (0x4471ca)
runtime/asm_amd64.s:1700 (0x484a20)
```
## After
```
2025/09/22 22:52:35 .../templates/htmlrenderer.go:118:initHTMLRenderer() [D] Creating static HTML Renderer
2025/09/22 22:52:35 routers/web/web.go:273:Routes() [F] common.Sessioner failed: failed to create session middleware: dial tcp 127.0.0.1:6379: connect: connection refused
```
---------
Signed-off-by: 6543 <6543@obermui.de >
2025-09-28 12:24:19 +00:00
wxiaoguang
edab7c205e
Remove incorrect "db.DefaultContext" usages ( #35366 )
2025-08-28 03:52:43 +00:00
JakobDev
001669ef9f
Next round of db.DefaultContext refactor ( #27089 )
...
Part of #27065
2023-09-16 14:39:12 +00:00
silverwind
01d3d331e1
Replace interface{} with any ( #25686 )
...
Result of running `perl -p -i -e 's#interface\{\}#any#g' **/*` and `make fmt`.
Basically the same [as golang did](2580d0e08d ).
2023-07-04 18:36:08 +00:00
flynnnnnnnnnn
487cb6a411
Implement FSFE REUSE for golang files ( #21840 )
...
Change all license headers to comply with REUSE specification.
Fix #16132
Co-authored-by: flynnnnnnnnnn <flynnnnnnnnnn@github>
Co-authored-by: John Olheiser <john.olheiser@gmail.com >
2022-11-27 18:20:29 +00:00
6543
e0a2bd79c9
format with gofumpt ( #18184 )
...
* gofumpt -w -l .
* gofumpt -w -l -extra .
* Add linter
* manual fix
* change make fmt
2022-01-20 18:46:10 +01:00
Lunny Xiao
4aeb0c73b6
Refactor auth package ( #17962 )
2022-01-02 21:12:35 +08:00
Lunny Xiao
ce67a0e254
Move session to models/login ( #17338 )
...
Move model/session.go to models/login
2021-10-17 19:51:56 +01:00
zeripath
969f068e3a
Create DB session provider(based on xorm) ( #13031 )
...
* Create Xorm session provider
This PR creates a Xorm session provider which creates
the appropriate Session table for macaron/session.
Fix #7137
Signed-off-by: Andrew Thornton <art27@cantab.net >
* extraneous l
Signed-off-by: Andrew Thornton <art27@cantab.net >
* fix lint
Signed-off-by: Andrew Thornton <art27@cantab.net >
* use key instead of ID to be compatible with go-macaron/session
Signed-off-by: Andrew Thornton <art27@cantab.net >
* And change the migration too.
Signed-off-by: Andrew Thornton <art27@cantab.net >
* Update spacing of imports
Co-authored-by: 6543 <6543@obermui.de >
* Update modules/session/xorm.go
Co-authored-by: techknowlogick <matti@mdranta.net >
* add xorm provider to the virtual provider
Signed-off-by: Andrew Thornton <art27@cantab.net >
* prep for master merge
* prep for merge master
* As per @lunny
* move migration out of the way
* Move to call this db session as per @lunny
Signed-off-by: Andrew Thornton <art27@cantab.net >
Co-authored-by: 6543 <6543@obermui.de >
Co-authored-by: techknowlogick <matti@mdranta.net >
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
2021-02-15 00:33:31 -05:00