Connecting using IP in server search stuck at "Requesting server variables"

Server side: Debian Bullseye running an unmodified 6432 with txAdmin, a Windows server not using txAdmin also showed the same issue.
Clientside: Windows 10 22H2, Reproduced on both Production and Canary

When connecting to a Server using the IP in the search field (using >193.23.161.125:30120), connection hangs at “Requesting server variables…” UNLESS you press enter before “Loading server data” completes and shows the server info, once the server info is visible, connecting reliably fails.

Screen capture demonstrating the problem:


(the “Requesting server variables…” screen never clears or changes)

I set up a test server with ZAP Hosting that seems to reliably demonstrate the issue:
193.23.161.125:30120

There is no firewall or other filtering active on the vps while the problem occurs.

It seems there’s a check for CS_INITING which fails here:

The state appears to be reset from a cancelDefer call from UI, which is a little odd as there’s actually no deferred connection being canceled here.

Looking into this a little further, I suspect pressing ENTER here might actually be leading to a ‘Cancel’ button being pressed which tells the host code to cancel the connection (but before actually showing any interface updates so it gets in this weird stuck state).

This should be fixed by fix(ext/cfx-ui): preventDefault on Enter press for IP entry · citizenfx/fivem@12d1cdb · GitHub.

Confirmed! Connection works every time now, thank you.

what file is this??

But what do you do with the file??