Skip to content

PHP8.4 connection error #131

@4wifi

Description

@4wifi

Trying to make a connection to the router with PHP 8.4 (FPM) fails with this error. No other changes made other than swapping from php82-php-fpm to php84-php-fpm

PHP Fatal error: Uncaught RouterOS\Exceptions\StreamException: Stream timed out in XXXX/evilfreelancer/routeros-api-php/src/Streams/ResourceStream.php:55
Stack trace:
#0 XXXX/evilfreelancer/routeros-api-php/src/APILengthCoDec.php(115): RouterOS\Streams\ResourceStream->read()
#1 XXXX/evilfreelancer/routeros-api-php/src/APIConnector.php(53): RouterOS\APILengthCoDec::decodeLength()
#2 XXXX/vendor/evilfreelancer/routeros-api-php/src/Client.php(255): RouterOS\APIConnector->readWord()
#3 XXXX/vendor/evilfreelancer/routeros-api-php/src/Client.php(310): RouterOS\Client->readRAW()
#4 XXXX/RouterOS.php(906): RouterOS\Client->read()

Have rolled back for now, will look at writing REST equiv of my class but like your old-API just fine and wondered if there was an easy fix.

Please do not just link back to the readme, the code work PERFECTLY on PHP8.2 but when moving to PHP8.4 with the exact same list of installed packages it fails with this error. API is enabled in both instances on the router and has been working perfectly for a long time.

Metadata

Metadata

Labels

bugSomething isn't working

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions