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

Failure of LinkTest.testAllLinks() #561

Closed
fedejeanne opened this issue Jul 4, 2023 · 12 comments · Fixed by #566 or eclipse-platform/eclipse.platform.releng.aggregator#1209
Closed

Comments

@fedejeanne
Copy link
Contributor

The test failed in this run of the PR #560

java.lang.IllegalArgumentException: Illegal character in scheme name at index 0: %20http://wiki.eclipse.org/Execution_Environment_Descriptions
java.lang.IllegalArgumentException: java.lang.IllegalArgumentException: Illegal character in scheme name at index 0: %20http://wiki.eclipse.org/Execution_Environment_Descriptions
	at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
	at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:77)
	at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
	at java.base/java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:499)
	at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:480)
	at java.base/java.util.concurrent.ForkJoinTask.getThrowableException(ForkJoinTask.java:562)
	at java.base/java.util.concurrent.ForkJoinTask.reportException(ForkJoinTask.java:591)
	at java.base/java.util.concurrent.ForkJoinTask.invoke(ForkJoinTask.java:689)
	at java.base/java.util.stream.ForEachOps$ForEachOp.evaluateParallel(ForEachOps.java:159)
	at java.base/java.util.stream.ForEachOps$ForEachOp$OfRef.evaluateParallel(ForEachOps.java:173)
	at java.base/java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:233)
	at java.base/java.util.stream.ReferencePipeline.forEach(ReferencePipeline.java:596)
	at java.base/java.util.stream.ReferencePipeline$Head.forEach(ReferencePipeline.java:765)
	at org.eclipse.ua.tests.doc.internal.linkchecker.LinkTest.testAllLinks(LinkTest.java:82)
...
@fedejeanne
Copy link
Contributor Author

Failed again in #563

@fedejeanne
Copy link
Contributor Author

Does anyone know how to test this locally?

I tried following this guide but it's outdated/unclear: https://github.com/eclipse-platform/eclipse.platform/tree/master/ua/infocenter-web

@merks
Copy link
Contributor

merks commented Jul 6, 2023

I can run this test locally, but it doesn't run well at all:

image

I think very likely the two highlighted space characters in these two files are the cause of problem:

image

@fedejeanne
Copy link
Contributor Author

fedejeanne commented Jul 6, 2023

Thanks for the tip!
I also run into the same exception when running the tests (FileNotFoundException) and I think it's because there is no WebServer running so there is no online help at all.

I removed the whitespaces in #277 .

@jukzi
Copy link
Contributor

jukzi commented Jul 8, 2023

I removed the whitespaces in #271 .

277 ?

@Bananeweizen
Copy link
Contributor

A fix is ready to be merged in #566. I'd just like to get a second opinion on my claim that the test code is actually wrong, because blanks are allowed around URIs in HTML.

@jukzi
Copy link
Contributor

jukzi commented Jul 9, 2023

For (x)html5 a whitspace is explicitly allowed "A string is a valid URL potentially surrounded by spaces if, after stripping leading and trailing whitespace (https://www.w3.org/TR/2014/REC-html5-20141028/infrastructure.html#strip-leading-and-trailing-whitespace) from it, it is a valid URL."
For html4 it was not: "href = uri [CT]"

HannesWell added a commit to HannesWell/eclipse.platform that referenced this issue Jul 9, 2023
@HannesWell
Copy link
Member

HannesWell commented Jul 9, 2023

For (x)html5 a whitspace is explicitly allowed "A string is a valid URL potentially surrounded by spaces if, after stripping leading and trailing whitespace (https://www.w3.org/TR/2014/REC-html5-20141028/infrastructure.html#strip-leading-and-trailing-whitespace) from it, it is a valid URL." For html4 it was not: "href = uri [CT]"

If all documents use HTML-5, then I think it would be OK to ignore leading/failing white-space in the test.

But the question is of course, do they all use HTML-5?

HannesWell added a commit to HannesWell/eclipse.platform that referenced this issue Jul 9, 2023
@HannesWell
Copy link
Member

But the question is of course, do they all use HTML-5?

The doc-type of the help-page is <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">, so it looks like this is html 4. What a bummer.

However I wonder why the updates in the extension-point schema definitions are not incorporated immediately into the help?
Even in my Eclipse SDK with Build id: I20230708-1800 (which is the latest build, the leading space is still present).

@laeubi
Copy link
Contributor

laeubi commented Jul 9, 2023

The doc-type of the help-page is , so it looks like this is html 4. What a bummer.

eclipse-platform/www.eclipse.org-eclipse#43

However I wonder why the updates in the extension-point schema definitions are not incorporated immediately into the help?

Have you bumped the doc bundles?

@HannesWell
Copy link
Member

The doc-type of the help-page is , so it looks like this is html 4. What a bummer.

eclipse-platform/www.eclipse.org-eclipse#43

That would be nice.

However I wonder why the updates in the extension-point schema definitions are not incorporated immediately into the help?

Have you bumped the doc bundles?

Yes, that was (very like) the problem. Thanks for the hint!
Just merged eclipse-platform/eclipse.platform.releng.aggregator#1209 and the result looks promosing. After tonight's I-build this issue should be gone.

Keep this issue open until then.

@HannesWell
Copy link
Member

Build is green now.
Thanks to everyone who participated!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
6 participants