You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
CliRouter - Presenter tries to canonize the URL and redirect #217
Not sure if I missed something, but after update to 3.0.0 my cron scripts stopped working. I got them bound to Live:cron presenter for example. Running them with php /var/www/www/index.php Live:cron --do=cron --type=cloudTasks
The response is
<h1>Redirect</h1><p><ahref="http:/live/cron?do=cron&type=cloudTasks">Please click here to continue</a>.</p>
Steps To Reproduce
In my RouterFactory I use
$router = new RouteList();
$router[] = new \Nette\Application\Routers\CliRouter();
now run the project with the example command above and see the result.
Expected Behavior
Not autoCanonicalize the CLI requests
Possible Solution
$autoCanonicalize to false as a temporary solution.
Activity
genesiscz commentedon Apr 22, 2019
Currently I used startup() for it
even with it, it still does try to redirect to another page
I see that the callstack to redirectUrl is
so it's actually not just autoCanonize, but also detectedCsrf which redirect to "this"
How was this "fixed"
simply adding
to handleCron "fixed" the problem, but it's a bug that needs a fix, probably in checkRequirements in Nette\Application\UI\Component
genesiscz commentedon May 14, 2020
Fixed in new version (not sure which version fixed this)
genesiscz commentedon May 14, 2020
Ah, I forgot to delete the $this->autoCanonicalize = false;
Still getting this in v3.0.5