mirror of
https://github.com/go-gitea/gitea.git
synced 2026-05-24 00:56:55 -05:00
Gitea doesn't open more than 5 tabs in browser #5588
Closed
opened 2025-11-02 06:29:57 -06:00 by GiteaMirror
·
28 comments
No Branch/Tag Specified
main
release/v1.25
release/v1.24
release/v1.23
release/v1.22
release/v1.21
release/v1.20
release/v1.19
release/v1.18
release/v1.17
release/v1.16
release/v1.15
release/v1.14
release/v1.13
release/v1.12
release/v1.11
release/v1.10
release/v1.9
release/v1.8
v1.25.3
v1.25.2
v1.25.1
v1.25.0
v1.24.7
v1.25.0-rc0
v1.26.0-dev
v1.24.6
v1.24.5
v1.24.4
v1.24.3
v1.24.2
v1.24.1
v1.24.0
v1.23.8
v1.24.0-rc0
v1.25.0-dev
v1.23.7
v1.23.6
v1.23.5
v1.23.4
v1.23.3
v1.23.2
v1.23.1
v1.23.0
v1.23.0-rc0
v1.24.0-dev
v1.22.6
v1.22.5
v1.22.4
v1.22.3
v1.22.2
v1.22.1
v1.22.0
v1.23.0-dev
v1.22.0-rc1
v1.21.11
v1.22.0-rc0
v1.21.10
v1.21.9
v1.21.8
v1.21.7
v1.21.6
v1.21.5
v1.21.4
v1.21.3
v1.21.2
v1.20.6
v1.21.1
v1.21.0
v1.21.0-rc2
v1.21.0-rc1
v1.20.5
v1.22.0-dev
v1.21.0-rc0
v1.20.4
v1.20.3
v1.20.2
v1.20.1
v1.20.0
v1.19.4
v1.21.0-dev
v1.20.0-rc2
v1.20.0-rc1
v1.20.0-rc0
v1.19.3
v1.19.2
v1.19.1
v1.19.0
v1.19.0-rc1
v1.20.0-dev
v1.19.0-rc0
v1.18.5
v1.18.4
v1.18.3
v1.18.2
v1.18.1
v1.18.0
v1.17.4
v1.18.0-rc1
v1.19.0-dev
v1.18.0-rc0
v1.17.3
v1.17.2
v1.17.1
v1.17.0
v1.17.0-rc2
v1.16.9
v1.17.0-rc1
v1.18.0-dev
v1.16.8
v1.16.7
v1.16.6
v1.16.5
v1.16.4
v1.16.3
v1.16.2
v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.4.0-rc1
v1.3.2
v1.3.1
v1.3.0
v1.3.0-rc2
v1.3.0-rc1
v1.2.3
v1.2.2
v1.2.1
v1.2.0
v1.2.0-rc3
v1.2.0-rc2
v1.1.4
v1.2.0-rc1
v1.1.3
v1.1.2
v1.1.1
v1.1.0
v1.0.2
v1.0.1
v1.0.0
v0.9.99
Labels
Clear labels
$20
$250
$50
$500
backport/done
💎 Bounty
docs-update-needed
good first issue
hacktoberfest
issue/bounty
issue/confirmed
issue/critical
issue/duplicate
issue/needs-feedback
issue/not-a-bug
issue/regression
issue/stale
issue/workaround
lgtm/need 2
modifies/api
modifies/translation
outdated/backport/v1.18
outdated/theme/markdown
outdated/theme/timetracker
performance/bigrepo
performance/cpu
performance/memory
performance/speed
pr/breaking
proposal/accepted
proposal/rejected
pr/wip
pull-request
reviewed/wontfix
💰 Rewarded
skip-changelog
status/blocked
topic/accessibility
topic/api
topic/authentication
topic/build
topic/code-linting
topic/commit-signing
topic/content-rendering
topic/deployment
topic/distribution
topic/federation
topic/gitea-actions
topic/issues
topic/lfs
topic/mobile
topic/moderation
topic/packages
topic/pr
topic/projects
topic/repo
topic/repo-migration
topic/security
topic/theme
topic/ui
topic/ui-interaction
topic/ux
topic/webhooks
topic/wiki
type/bug
type/deprecation
type/docs
type/enhancement
type/feature
type/miscellaneous
type/proposal
type/question
type/refactoring
type/summary
type/testing
type/upstream
Mirrored from GitHub Pull Request
No Label
type/bug
Milestone
No items
No Milestone
Projects
Clear projects
No project
No Assignees
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: github-starred/gitea#5588
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
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?
Originally created by @lakostin on GitHub (Jun 19, 2020).
1.12.0
2.17.1
Ubuntu 18.04.3 LTS
[x]):Description
I open pull request with multiple commits, then i open 5 new tabs in browser with each commit. Everything is ok. When i open the sixth tab and further they hang with message "Waiting for available socket..." until i close one of the previously opened tabs.
It can be reproduced in any browser.
What can this be connected to?
Screenshots
@lunny commented on GitHub (Jun 19, 2020):
can't reproduce in https://gitea.com
@lakostin commented on GitHub (Jun 19, 2020):
Updated description.
@wkobiela commented on GitHub (Jun 19, 2020):
@lakostin
Just checked myself, Gitea 1.12.0, GIT 2.26.2, MySQL, hosted on Synology.
Created PR with >5 commits, opened PR and each commit multiple times. No issues.
@lakostin commented on GitHub (Jun 19, 2020):
I have this isssue on multiple instances and even on different versions. All served by docker btw
@chxseh commented on GitHub (Jun 19, 2020):
Can confirm, opening any new tabs after 6 have loaded for me results in awaiting for socket. Hosting on Docker as well.
@dexterxx-pl commented on GitHub (Jun 19, 2020):
I had same issue here, just after updating to v1.12.
It's not related just to PR's - in my case I've just opened new tabs of issues of my project - loading just stucks... and it stucks for many minutes.
CPU usage stays at typical level, logs shows that database (MySQL in my case) also respond in typical time.
Now I've just figured out, that restarting gitea didn't solved problem, but restarting proxy (apache2) does.
After restarting I cannot now reproduce it 👎
@lakostin are you using proxy at front of gitea?
@chxseh commented on GitHub (Jun 19, 2020):
@dexterxx-pl Tried restarting my proxy in front of gitea to no effect.
@lafriks commented on GitHub (Jun 20, 2020):
I think it is related to events endpoint that uses sockets for getting events about new notifications. We should probably somehow limit sockets count per user probably
@deptyped commented on GitHub (Jun 20, 2020):
Same problem. But I could not reproduce this issue without a reverse proxy server (nginx in my case).
By the way, in Firefox pages stop loading after five clicks on the site in one tab.
UPD: Using http2 in nginx solved the problem
@zeripath commented on GitHub (Jun 20, 2020):
Yeah I suspect this is EventSource issues.
@zeripath commented on GitHub (Jun 20, 2020):
So I don't think this is the server holding things up but rather the browser. It looks like Firefox is blocking instead of just failing out.
@confusedsushi commented on GitHub (Jun 21, 2020):
I can confirm this. It happened first after upgrading to 1.12. I am running gitea on Windows 10 2004 with an apache reverse proxy on Ubuntu 18.04.
I am able to reproduce this with Firefox and Chrome.
@zeripath commented on GitHub (Jun 21, 2020):
Can anyone reproduce this on try?
@Governa commented on GitHub (Jun 22, 2020):
It seems I do. Both in Firefox and in Chromium.
I just have to Login and from the Dashboard open multiple commits in tabs. If then I click on "View source" it will not load until I close enough(about 5 tabs are left open) tabs.
It seems to be about 5 tabs in each browser, as I could test Chromium while Firefox tabs were still open.
@lakostin commented on GitHub (Jun 24, 2020):
Reproduced also in Gitea Version: 1.12.1 running with systemd.
Do not use any proxy server in front.
@flozzone commented on GitHub (Jun 24, 2020):
Also Reproducible
version: 1.12.1
proxy: apache 2.4
env: docker container
curl 'https://GITEA_HOST/user/events' -H 'User-Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:77.0) Gecko/20100101 Firefox/77.0' -H 'Accept: text/event-stream' -H 'Accept-Language: en-US,en;q=0.5' --compressed -H 'DNT: 1' -H 'Connection: keep-alive' -H 'Cookie: lang=en-US; i_like_gitea=33dxxxxxxxxx270; _csrf=zIz1_5HrJzMfqWC4XXXXXXXXXXXXXXXXXXXXXOTQyNw' -H 'Pragma: no-cache' -H 'Cache-Control: no-cache'@mind-overflow commented on GitHub (Jun 24, 2020):
This also happens while normally browsing Gitea, you do not need to open 5 different tabs at the same time. I have ran into this problem just by navigating through my commits and repository files, and have been running into it since at least version 1.11. I am now using 1.12.1 with the same identical problem.
Gitea is running behind an Apache2 reverse proxy, no docker. MySQL database. Ubuntu 20.04 LTS.
@42wim commented on GitHub (Jun 25, 2020):
I can also reproduce this (on gitea 1.12.1), the
/user/eventskeep pending.Related to https://developer.mozilla.org/en-US/docs/Web/API/EventSource and HTTP/2.
I've patched my own gitea to disable javascript going to
/user/eventsand everythings works fine now.There should be an option to disable this when people don't have access to HTTP/2 loadbalancers.
@westhom commented on GitHub (Jun 27, 2020):
I was seeing this issue in Firefox / Gitea 1.12.1, clicking around gitea a bunch would eventually cause requests to hang and never complete, essentially freezing the app. I noticed in the network debugger a lot of the requests were being fulfilled by the Service Worker.
I was able to fix my issue by going into
about:debuggingand unregistering the service worker for my gitea domain, then refreshing the tab. Now I can't reproduce the issue. The service worker appeared in the list after I re-opened for the first time, but all seems good now.@ratuka commented on GitHub (Jun 29, 2020):
Same here with Firefox and Chrome too.
@zeripath commented on GitHub (Jun 29, 2020):
Sorry about this. This one is my fault.
There is a workaround:
[ui.notification]EVENT_SOURCE_UPDATE_TIME=0oruse HTTP/2.0.I've finally managed to hack up a fix and will push up a PR to push the EventSource stuff into a SharedWorker but it will need review.
Unfortunately the setting doesn't work due to a misunderstanding on my behalf. My suspicion was the EventSource would not open if you hit the tab limit not - that it would prevent opening new tabs - and although I tested with opening multiple tabs it didn't cause these problems.
This code has been part of master for quite some time - I don't understand why it was only on release of Gitea 1.12 that this problem was noticed. Presumably try runs on HTTP/2.0?
@mind-overflow commented on GitHub (Jun 29, 2020):
EDIT: Looks like Firefox had cached some settings. I was still using HTTP 1.1 with my old session, however in incognito mode (and thus clearing the cookies too) switched me to HTTP 2.0, fixing the problem.
Very weird, since my server allows HTTP 2.0 connections and I still manage to have this issue... Are you sure about the second fix? I'm starting to doubt that my configuration could be faulty, even though the Firefox dev console says I'm using HTTP 2.0...
@chxseh commented on GitHub (Jun 29, 2020):
Doesn't appear to work for me, not sure if I just did something wrong.. Will try and figure out switching to HTTP/2.0.
@zeripath commented on GitHub (Jun 30, 2020):
@ChaseHall try -1 instead of 0?
@chxseh commented on GitHub (Jun 30, 2020):
@zeripath -1 just results in a 503. Nothing useful in docker logs about it..
@42wim commented on GitHub (Jun 30, 2020):
I can second that, same issues as @ChaseHall
@zeripath commented on GitHub (Jun 30, 2020):
@ChaseHall @42wim - sorry you're right - that's another bug with this too. 😞
@zeripath commented on GitHub (Jun 30, 2020):
OK #12095 will fix that too. Setting
EVENT_SOURCE_UPDATE_TIME=-1will disable all EventSources from that point.