Open drzraf opened 2 years ago
More generally, it's really hard to debug streams when something goes wrong.
problems
does not help (it may even keeps correctly configured website from running https://github.com/getgrav/grav-plugin-problems/issues/28) but probably should.
WIth Grav 1.7, I could set GRAV_ENVIRONMENT
in httpd configuration, or a setup.php
file, or a user/config/streams.yaml
file overriden by localhost/config/*
files. When these are needed, it's not rare to struggle with the above errors or page not found
but it's almost impossible to figure out what's wrong with Grav configuration, because Grav won't says which files it considered, which it ignored, and what are the paths that it's actually considering when looking for pages/config/plugins/...
It'd would be a lifesaver to obtain a dump of the actual paths in such a case.
Another thing that may need to be fixed in https://learn.getgrav.org/17/advanced/multisite-setup :
This environment
setup key does not seem to be used.
return [
'environment' => $name,
...
];
I'd add that Clockwork (when debugging is actually taken into account) does help! It shows actual configuration, streams, ... but if you get a 404 even though streams are corrects, then it's very hard to figure out what's happening.
When
user://
points to a directory missing aplugins/
directory (for whatever reason, from permission tosetup.php
,streams.yaml
, to debugging config order/override), this strange error is thrown (Failed to open dir: plugins:// does not exist.
) with this stack:A more explicit error about uninitialized or badly initialized streams would really help (in particular, printing the actual path(s) looked for)