Austinb / GameQ

A PHP Gameserver Status Query Library
https://austinb.github.io/GameQ/
GNU Lesser General Public License v3.0
403 stars 136 forks source link

Running into a socket creation problem #717

Closed lewislarsen closed 8 months ago

lewislarsen commented 8 months ago

Hi there,

I am working on a little project that utilises this package and I've run into a little problem when trying to query servers.

The error:

GameQ\Exception\Query: GameQ\Query\Native::create - Error creating socket to server 127.0.0.1:0. Error: Can't assign requested address in /Users/lewislarsen/sites/aura/vendor/austinb/gameq/src/GameQ/Query/Native.php:126

I think it's due to my local development environment, I am using Laravel Valet which sends all localhost requests through nginx and resolves them to .test tld.

I was passing a Minecraft server (mc.hypixel.net:25565) to GameQ with no query port specified. I do have debug mode option for the library enabled.

I am using version 3.1.0 of GameQ with PHP 8.2.11 on MacOS Sonoma.

If you have any recommendations on resolving this, I would be extremely grateful.

lewislarsen commented 8 months ago

Looks like a computer restart fixed it, weird! Thank you. :)