Seems we are now using some services from the client in the repo, due to how the factories and stuff are instantiated.
For EntityRevisionLookup, we have this (with ForbiddenSerializer used in EntityContentDataCodec):
I think the serializer in EntityContentDataCodec might be there to support the old internal serialization format (which exists for entities not edited for a long time, or for old revisions and might be needed for dump generation) and think we still need it.
I am concerned that whatever it does might (silently or in subtle ways) break and that we should be careful about using client services in the repo.
'EntityRevisionLookup' => function( RepositoryServiceContainer $services, WikibaseClient $client ) { $codec = new EntityContentDataCodec( $services->getEntityIdParser(), new ForbiddenSerializer( 'Entity serialization is not supported on the client!' ), $services->getEntityDeserializer(), $client->getSettings()->getSetting( 'maxSerializedEntitySize' ) * 1024 ); /** @var WikiPageEntityMetaDataAccessor $metaDataAccessor */ $metaDataAccessor = $services->getService( 'WikiPageEntityMetaDataAccessor' ); return new WikiPageEntityRevisionLookup( $codec, $metaDataAccessor, $services->getDatabaseName() ); },