In the following code the TranslationWalker will be replaced by KnpPaginator and won't be applied.
$page = 1;
$limit = 1000;
$query = $repo->createQueryBuilder('a')
->getQuery()
->setHint(
Query::HINT_CUSTOM_OUTPUT_WALKER,
'\Gedmo\Translatable\Query\TreeWalker\TranslationWalker'
)
;
$paginator = $this->container->get('knp_paginator');
$pagination = $paginator->paginate($query, $page, $limit, ['distinct' => false]);
Extra check here will solve the problem.
In the following code the
TranslationWalkerwill be replaced by KnpPaginator and won't be applied.Extra check here will solve the problem.