Skip to content
New issue

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

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

Already on GitHub? # to your account

Legacy layer load order incorrect #111

Closed
dleffler opened this issue Feb 21, 2023 · 2 comments
Closed

Legacy layer load order incorrect #111

dleffler opened this issue Feb 21, 2023 · 2 comments

Comments

@dleffler
Copy link

I'm still using the legacy interface with v4.10.0. The loading order in /lib/xmlrpc.inc is NOT correct and will cause an error. The 'Traits' libraries need to be loaded before the 'Helper' libraries, and the 'Traits/PayloadBearer' also needs to be added/loaded. Here's my amended (working) list

// the list is sorted more-or-less in dependency order
include_once(__DIR__.'/../src/Exception.php');
include_once(__DIR__.'/../src/Exception/FaultResponseException.php');
include_once(__DIR__.'/../src/Exception/ParsingException.php');
include_once(__DIR__.'/../src/Exception/XmlException.php');
include_once(__DIR__.'/../src/Exception/XmlRpcException.php');
include_once(__DIR__.'/../src/Exception/TransportException.php');
include_once(__DIR__.'/../src/Exception/HttpException.php');
include_once(__DIR__.'/../src/Exception/ServerException.php');
include_once(__DIR__.'/../src/Exception/NoSuchMethodException.php');
include_once(__DIR__.'/../src/Exception/StateErrorException.php');
include_once(__DIR__.'/../src/Exception/TypeErrorException.php');
include_once(__DIR__.'/../src/Exception/ValueErrorException.php');
include_once(__DIR__.'/../src/PhpXmlRpc.php');
include_once(__DIR__.'/../src/Traits/CharsetEncoderAware.php');
include_once(__DIR__.'/../src/Traits/LoggerAware.php');
include_once(__DIR__.'/../src/Traits/DeprecationLogger.php');
include_once(__DIR__.'/../src/Traits/ParserAware.php');
include_once(__DIR__.'/../src/Traits/PayloadBearer.php');
include_once(__DIR__.'/../src/Helper/Charset.php');
include_once(__DIR__.'/../src/Helper/Date.php');
include_once(__DIR__.'/../src/Helper/Http.php');
include_once(__DIR__.'/../src/Helper/Interop.php');
include_once(__DIR__.'/../src/Helper/Logger.php');
include_once(__DIR__.'/../src/Helper/XMLParser.php');
include_once(__DIR__.'/../src/Value.php');
include_once(__DIR__.'/../src/Request.php');
include_once(__DIR__.'/../src/Response.php');
include_once(__DIR__.'/../src/Client.php');
include_once(__DIR__.'/../src/Encoder.php');
@gggeek
Copy link
Owner

gggeek commented Feb 22, 2023

Doh. Sorry about that.

I definitely have to include in the CI tests something which eschews the autoloading mechanisms to make sure that the .inc files do work stand-alone. Hopefully I should be able to do that within a couple of days...

@gggeek
Copy link
Owner

gggeek commented Feb 22, 2023

Fixed in 4.10.1. Specific tests added.

@gggeek gggeek closed this as completed Feb 22, 2023
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants