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
Stack trace in the logs when attempting to save a UriInput node with an invalid node:
System.AggregateException: One or more errors occurred. ---> System.UriFormatException: Invalid URI: The format of the URI could not be determined.
at System.Uri.CreateThis (System.String uri, System.Boolean dontEscape, System.UriKind uriKind) [0x0007b] in <ef151b6abb5d474cb2c1cb8906a8b5a4>:0
at System.Uri..ctor (System.String uriString) [0x00014] in <ef151b6abb5d474cb2c1cb8906a8b5a4>:0
at BaseX.DataTreeValue.ExtractURL () [0x00036] in <2cab77e73b74412faa09a9eb8498c7b9>:0
at BaseX.DataTreeValue.Extract[T] () [0x000b1] in <2cab77e73b74412faa09a9eb8498c7b9>:0
at FrooxEngine.DataTreeAssetProcessor+<Process>d__1.MoveNext () [0x000e5] in <c15eff494aa74d1a8369da64f3d2fe2a>:0
The problem is that UriInput::ParseValue treats its contents as a relative or absolute URI, while DataTreeValue attempts to create a URI from the contents and checks that it is a valid URI. These two methods are not compatible.
abc is a relative URI, and will not parse as a valid URI.
Solution 1: Change DataTreeValue::ExtractURL to construct a Uri in the same way as UriInput. This allows both relative and aboluste URIs to be serialized : return new Uri(value.Substring(1), UriKind.RelativeOrAbsolute); This may also require that TryExtractURL also be updated to accept relative URIs.
Solution 2: Do not accept relative URIs in UriInput. This means existing LogiX that relies on this behavior may break.
Solution 3: Use the same code as Cast_string_to_Uri does: if the text cannot initially be converted to a Uri using UriKind.Absolute, prepend http:// and try again. This would result in http://abc which is a valid Uri. Also, see the proposed Parse Uri node.
Describe the bug?
You can't save a URI input node if it has an invalid URI typed into it. (or anything that contains one)
Relevant issues
Didn't find any.
To Reproduce
Expected behavior
The item should be saved to my inventory.
Log Files
No response
Screenshots
No response
How often does it happen?
Always
Does the bug persist after restarting Neos?
Yes
Neos Version Number
Beta 2021.11.10.1265
What Platforms does this occur on?
Windows
Link to Reproduction Item/World
I literally cannot provide this.
Did this work before?
I Don't Know
If it worked before, on which build?
No response
Additional context
No response
Reporters
Cameron#7818
KodeyTheNeko#1284
The text was updated successfully, but these errors were encountered: