Javascript error after updating to 1.17.0 #9414

Closed
opened 2025-11-02 08:37:58 -06:00 by GiteaMirror · 6 comments
Owner

Originally created by @wolfbeast on GitHub (Aug 17, 2022).

Description

I'm in the process of updating out Gitea instance to 1.17.0 from 1.12.6, and ran into it throwing a JS error after upgrading and migrating successfully.

09:54:40.024 error { target: SharedWorker, isTrusted: true, message: "ReferenceError: EventSource is not defined", filename: "https://repo.palemoon.org/assets/js/eventsource.sharedworker.js", lineno: 1, colno: 85, srcElement: SharedWorker, currentTarget: SharedWorker, eventPhase: 2, bubbles: false, cancelable: true } 1 index.js:37:15714
	Gg/< https://repo.palemoon.org/assets/js/index.js:37:15714

This is on the Pale Moon web browser (we use Gitea for Pale Moon development).
Of note, Pale Moon does not support the ambiguous global window.event MSIE quirk (deprecated on mainstream browsers also) which may be the issue here?

Screenshots

gitea1

Gitea Version

1.17.0

Can you reproduce the bug on the Gitea demo site?

No

Operating System

Windows 10

Browser Version

Pale Moon 31.2.0.1

Originally created by @wolfbeast on GitHub (Aug 17, 2022). ### Description I'm in the process of updating out Gitea instance to 1.17.0 from 1.12.6, and ran into it throwing a JS error after upgrading and migrating successfully. ``` 09:54:40.024 error { target: SharedWorker, isTrusted: true, message: "ReferenceError: EventSource is not defined", filename: "https://repo.palemoon.org/assets/js/eventsource.sharedworker.js", lineno: 1, colno: 85, srcElement: SharedWorker, currentTarget: SharedWorker, eventPhase: 2, bubbles: false, cancelable: true } 1 index.js:37:15714 Gg/< https://repo.palemoon.org/assets/js/index.js:37:15714 ``` This is on the Pale Moon web browser (we use Gitea for Pale Moon development). Of note, Pale Moon does not support the ambiguous global `window.event` MSIE quirk (deprecated on mainstream browsers also) which _may_ be the issue here? ### Screenshots ![gitea1](https://user-images.githubusercontent.com/3359132/185066233-df5744b4-3bfe-4cb4-ae15-40a207362fc1.png) ### Gitea Version 1.17.0 ### Can you reproduce the bug on the Gitea demo site? No ### Operating System Windows 10 ### Browser Version Pale Moon 31.2.0.1
GiteaMirror added the topic/uitype/bug labels 2025-11-02 08:37:58 -06:00
Author
Owner

@lunny commented on GitHub (Aug 17, 2022):

Should be fixed by #20663

@lunny commented on GitHub (Aug 17, 2022): Should be fixed by #20663
Author
Owner

@wolfbeast commented on GitHub (Aug 17, 2022):

Thanks!
I did some digging myself and found it seems to be because while we do support EventSource (and have since forever) and SharedWorkers, we currently don't support EventSource in workers. I opened an issue on our end to fix that, as well.

of note attempting to disable EventSource use through EVENT_SOURCE_UPDATE_TIME = -1 doesn't actually help here.

@wolfbeast commented on GitHub (Aug 17, 2022): Thanks! I did some digging myself and found it seems to be because while we do support EventSource (and have since forever) and SharedWorkers, we currently don't support EventSource _in_ workers. I opened an issue on our end to fix that, as well. of note attempting to disable EventSource use through `EVENT_SOURCE_UPDATE_TIME = -1` doesn't actually help here.
Author
Owner

@silverwind commented on GitHub (Aug 17, 2022):

BTW, does PaleMoon support Websocket inside SharedWorker?

@silverwind commented on GitHub (Aug 17, 2022): BTW, does PaleMoon support Websocket inside SharedWorker?
Author
Owner

@wolfbeast commented on GitHub (Aug 17, 2022):

BTW, does PaleMoon support Websocket inside SharedWorker?

Yes, websockets are available in workers.

@wolfbeast commented on GitHub (Aug 17, 2022): > BTW, does PaleMoon support Websocket inside SharedWorker? Yes, websockets are available in workers.
Author
Owner

@eeyrjmr commented on GitHub (Aug 17, 2022):

Is this related to or a duplicate of : https://github.com/go-gitea/gitea/issues/20572

@eeyrjmr commented on GitHub (Aug 17, 2022): Is this related to or a duplicate of : https://github.com/go-gitea/gitea/issues/20572
Author
Owner

@wolfbeast commented on GitHub (Aug 17, 2022):

@eeyrjmr Yes it seems to be a duplicate. I'll just wait for it to make it to the release train.

@wolfbeast commented on GitHub (Aug 17, 2022): @eeyrjmr Yes it seems to be a duplicate. I'll just wait for it to make it to the release train.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#9414