make sure usernames & reponames are url encoded #271
Labels
No Label
has/backport
has/pull
in progress
invalid
kind/breaking
kind/bug
kind/build
kind/deployment
kind/docs
kind/enhancement
kind/feature
kind/lint
kind/proposal
kind/question
kind/refactor
kind/security
kind/testing
kind/translation
kind/ui
need/backport
priority/critical
priority/low
priority/maybe
priority/medium
reviewed/duplicate
reviewed/invalid
reviewed/wontfix
skip-changelog
status/blocked
status/needs-feedback
status/needs-reviews
status/wip
upstream/gitea
No Milestone
No Assignees
3 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: gitea/go-sdk#271
Loading…
Reference in New Issue
Block a user
No description provided.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
"the SDK does not do any URL pathencoding for putative usernames or reponames - if say we relax the rules for reponames to allow umlauts or you want to use the SDK elsewhere you need to pathencode them" - zeripath
[x] does
link, _ := url.Parse(...)
encode when you uselink.String()
ToDo:
One of the reasons why we currently don't allow "special" characters for repo/usernames, is that the gitea stores repos on disk in an non-efficient manner, such that on disk the folders are named username/repo.git and some filesystems (really bad ones) dont allow "special" characters as folder names.
Note: I put "special" in quotes, as those characters aren't special but some computers/filesystems can't handle them due to their creators not considering non-english alphabets (quelle surprise).
And I have an idea for how to avoid that...
Repositories should just be stored by id.
@zeripath this is a ustream problem i think (have to fix in gitea)
yeah I am aware 😛
make sure usernames & reponames are url encoded ?to make sure usernames & reponames are url encoded