Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Browser Dialer lost connection after reloading browser websocket page on Xray-core v24.9.30 . #3882

Open
3 of 4 tasks
tkszhzy opened this issue Oct 5, 2024 · 8 comments
Open
3 of 4 tasks
Labels
bug Something isn't working

Comments

@tkszhzy
Copy link

tkszhzy commented Oct 5, 2024

Integrity requirements

  • I confirm that I have read the documentation, understand the meaning of all the configuration items I wrote, and did not pile up seemingly useful options or default values.
  • I provided the complete config and logs, rather than just providing the truncated parts based on my own judgment.
  • I searched issues and did not find any similar issues.
  • The problem can be successfully reproduced in the latest Release

Description

If reopen websoket page , Broswer dialer will not work anymore .

and must reboot xray to work.

Reproduction Method

none

Client config


none

Server config


none

Client log

[Info] [3827992590] app/proxyman/outbound: app/proxyman/outbound: failed to process outbound traffic > proxy/vless/outbound: failed to find an available destination > common/retry: [websocket: close 1001 (going away)] > common/retry: all retry attempts failed

Server log


none
@Fangliding
Copy link
Member

configuration

@RPRX
Copy link
Member

RPRX commented Oct 5, 2024

If reopen websoket page , Broswer dialer will not work anymore .

and must reboot xray to work.

@Fangliding 你试下能不能复现

@Fangliding
Copy link
Member

Fangliding commented Oct 5, 2024

If reopen websoket page , Broswer dialer will not work anymore .
and must reboot xray to work.

@Fangliding 你试下能不能复现

我都没用过 要config的原因很大一部分是我复现要用 然而99%的人全部把要求当耳旁风 修就算了别人就一句不能用还得自己写配置测有没有真的有点淦了

@mmmray
Copy link
Collaborator

mmmray commented Oct 7, 2024

#3832

@PoneyClairDeLune I just saw that onmessage = and addEventListener("message") are mixed in the same PR. the intention is to overwrite the previous event handler with a new one, but I think the current code might run both. I'm not sure. Anyway, this PR is the only change to BD in 24.9.30

@PoneyClairDeLune
Copy link
Contributor

@mmmray Ouch, gotta see how to prevent multiple handlers from getting run when available.

@mmmray mmmray added the bug Something isn't working label Oct 8, 2024
@hossinasaadi
Copy link
Contributor

@mmmray Ouch, gotta see how to prevent multiple handlers from getting run when available.

may you should prevent like :

ws.addEventListener("message", (event) => {},{ once: true })

https://github.com/PoneyClairDeLune/Xray-core/blob/3632e83faa70f2bdd08507c54b251ecd22092e6c/transport/internet/browser_dialer/dialer.html#L136-L137

@mmmray
Copy link
Collaborator

mmmray commented Oct 12, 2024

I'm tempted to just revert addEventListener to ws.onmessage -- i think it's actually easier to reason about what happens with that kind of syntax

mmmray added a commit to mmmray/Xray-core that referenced this issue Oct 12, 2024
XTLS#3882 (comment)

This does not fix the linked issue, just a random bug I found.
mmmray added a commit to mmmray/Xray-core that referenced this issue Oct 12, 2024
XTLS#3882 (comment)

This does not fix the linked issue, just a random bug I found.
@mmmray
Copy link
Collaborator

mmmray commented Oct 12, 2024

opened a PR for that #3906, but while testing, I found that I cannot reproduce this issue at all (even on main) -- anyway, please test the linked PR, and/or figure out which version introduced the issue

RPRX pushed a commit that referenced this issue Oct 13, 2024
#3882 (comment)

This does not fix the linked issue, just a random bug I found.
leninalive pushed a commit to amnezia-vpn/amnezia-xray-core that referenced this issue Oct 29, 2024
XTLS#3882 (comment)

This does not fix the linked issue, just a random bug I found.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

6 participants