Error when pushing to new repo: Internal Server Response Decoding Failed #10672

Closed
opened 2025-11-02 09:15:00 -06:00 by GiteaMirror · 3 comments
Owner

Originally created by @gabriel-vasile on GitHub (Apr 17, 2023).

Description

To reproduce:

  1. in gitea web interface create a new repo
  2. locally, create a new git repo with:
echo a > a
git init
git add .
git commit -m "first commit"
git remote add origin your_remote_from_step_1
git push -u origin master

Important: use master branch in this test. Problem does not reproduce with main.

Expected: push works and success message is received from remote.
Got: push works but error message is received from remote:
image

It seems to problem was introduced in f4538791f5.

Gitea Version

last commit in master

Can you reproduce the bug on the Gitea demo site?

Yes

Log Gist

No response

Screenshots

No response

Git Version

No response

Operating System

No response

How are you running Gitea?

make build && ./gitea web

Database

None

Originally created by @gabriel-vasile on GitHub (Apr 17, 2023). ### Description To reproduce: 1. in gitea web interface create a new repo 2. locally, create a new git repo with: ``` echo a > a git init git add . git commit -m "first commit" git remote add origin your_remote_from_step_1 git push -u origin master ``` Important: use `master` branch in this test. Problem does not reproduce with `main`. Expected: push works and success message is received from remote. Got: push works but error message is received from remote: ![image](https://user-images.githubusercontent.com/10602896/232486221-02bf6f52-60b6-4811-930b-254c2233bb89.png) It seems to problem was introduced in https://github.com/go-gitea/gitea/commit/f4538791f5fc82b173608fcf9c30e36ec01dc9d3. ### Gitea Version last commit in master ### Can you reproduce the bug on the Gitea demo site? Yes ### Log Gist _No response_ ### Screenshots _No response_ ### Git Version _No response_ ### Operating System _No response_ ### How are you running Gitea? make build && ./gitea web ### Database None
GiteaMirror added the type/bug label 2025-11-02 09:15:00 -06:00
Author
Owner

@wxiaoguang commented on GitHub (Apr 17, 2023):

Could be fixed by: Fix incorrect internal response type #24173

@wxiaoguang commented on GitHub (Apr 17, 2023): Could be fixed by: Fix incorrect internal response type #24173
Author
Owner

@gabriel-vasile commented on GitHub (Apr 18, 2023):

The error is not printed anymore but the formatting seems a little off to me.

gabriel@tbook:~/tmp/qwer$ git push -u origin master
Enumerating objects: 3, done.
Counting objects: 100% (3/3), done.
Writing objects: 100% (3/3), 861 bytes | 861.00 KiB/s, done.
Total 3 (delta 0), reused 0 (delta 0), pack-reused 0
remote: . Processing 1 references  <-------------- THIS LINE HERE
remote: Processed 1 references in total
To localhost:a/qwer.git
 * [new branch]      master -> master
Branch 'master' set up to track remote branch 'master' from 'origin'.
@gabriel-vasile commented on GitHub (Apr 18, 2023): The error is not printed anymore but the formatting seems a little off to me. ```bash gabriel@tbook:~/tmp/qwer$ git push -u origin master Enumerating objects: 3, done. Counting objects: 100% (3/3), done. Writing objects: 100% (3/3), 861 bytes | 861.00 KiB/s, done. Total 3 (delta 0), reused 0 (delta 0), pack-reused 0 remote: . Processing 1 references <-------------- THIS LINE HERE remote: Processed 1 references in total To localhost:a/qwer.git * [new branch] master -> master Branch 'master' set up to track remote branch 'master' from 'origin'. ```
Author
Owner

@wxiaoguang commented on GitHub (Apr 18, 2023):

The error is not printed anymore but the formatting seems a little off to me.

It's related to this one:

@wxiaoguang commented on GitHub (Apr 18, 2023): > The error is not printed anymore but the formatting seems a little off to me. It's related to this one: * https://github.com/go-gitea/gitea/issues/23364
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#10672