Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

BUG: NodeTypeManager can crash in cli context #4888

Open
mhsdesign opened this issue Feb 12, 2024 · 0 comments
Open

BUG: NodeTypeManager can crash in cli context #4888

mhsdesign opened this issue Feb 12, 2024 · 0 comments

Comments

@mhsdesign
Copy link
Member

I found out that flow nodetypes:list can throw an error

No base URI could be provided.
This probably means a call was made outside of an HTTP request and a base
URI was neither configured nor specified as $fallbackRequest.

  Type: Neos\Flow\Http\Exception
  Code: 1567529953
  File: Data/Temporary/Development/Cache/Code/Flow_Object_Classes/Neos_Flow_Http_Ba
        seUriProvider.php
  Line: 9

that was caused by me using the thumbnail option which is post processed here (introduced with 277989f)

$thumbnailUrl = $this->resourceManager->getPublicPackageResourceUriByPath($thumbnailUrl);

of course this logic already seems a bit hacky and we could move this out to the neos ui to use an endpoint for resolving the uri neos/neos-ui#3695, but still that code alone should not crash on cli.

i would propose that just / is used as base uri if nothing is found.

flow nodetypes:show Neos.Demo:Document.Page --path ui.help.thumbnail
NodeType configuration "Neos.Demo:Document.Page.ui.help.thumbnail":

/_Resources/Static/Packages/Neos.Neos/Images/dummy-image.svg
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: No status
Development

No branches or pull requests

1 participant