Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

"Link Checker Failed to validate URL" on some links with empty space characters

bobbym33667819
Level 3
Level 3

I'm receiving an error that the Link Checker fails to validate some URLs because of illegal character and that character always seems to be the space character (ASCII: 32). However other similar links have no problem being validate as I can see at etc/linkchecker.html. Please have a look at the errors below.

0.04.2018 15:32:37.715 *ERROR* [sling-default-5637-com.day.cq.rewriter.linkchecker.impl.LinkCheckerTask.2368] com.day.cq.rewriter.linkchecker.impl.LinkCheckerTask Failed to validate URL http://10.112.100.240:4502/assetdetails.html/content/dam/msi-dam/photography/room-scenes/bedroom/1-2... 0006.tif: java.net.URISyntaxException: Illegal character in path at index 109: http://10.112.100.240:4502/assetdetails.html/content/dam/msi-dam/photography/room-scenes/bedroom/1-2... 0006.tif

10.04.2018 15:32:37.715 *ERROR* [sling-default-5637-com.day.cq.rewriter.linkchecker.impl.LinkCheckerTask.2368] com.day.cq.rewriter.linkchecker.impl.LinkCheckerTask Failed to validate URL http://10.112.100.240:4502/assetdetails.html/content/dam/msi-dam/photography/room-scenes/bedroom/1-2... 0009.jpg: java.net.URISyntaxException: Illegal character in path at index 109: http://10.112.100.240:4502/assetdetails.html/content/dam/msi-dam/photography/room-scenes/bedroom/1-2... 0009.jpg

10.04.2018 15:32:37.715 *ERROR* [sling-default-5637-com.day.cq.rewriter.linkchecker.impl.LinkCheckerTask.2368] com.day.cq.rewriter.linkchecker.impl.LinkCheckerTask Failed to validate URL http://10.112.100.240:4502/assetdetails.html/content/dam/msi-dam/photography/room-scenes/commercial/... 0032.jpg: java.net.URISyntaxException: Illegal character in path at index 116: http://10.112.100.240:4502/assetdetails.html/content/dam/msi-dam/photography/room-scenes/commercial/... 0032.jpg

I'm not sure why only some of them are not being validated. Any help would be appreciated. Thanks a lot!

Bobby

4 Replies
smacdonald2008
Level 10
Level 10

Checking to see if there is a known issue here.

kautuk_sahni
Employee
Employee

Folder name can not have special characters like %/\:*?"[]| . #{}^;+, space [You might have added this folder via WebDev]

Can you please %encode the URL while providing and check?

like ->   b edroom   as   b%20edroom

Some more workaround:-

You can add x-cq-linkchecker="valid" parameter in the <a> tag to make sure that links are always marked as valid by AEM. In this case, link checker will check the link but will mark it valid.

Or

You can disable external link checker entirely by going to felix console

OR

You can ass context and x-cq-linkchecker="skip" to the a tag as below then url would rendered correctly like:

<a href="{url @context='unsafe'}" x-cq-linkchecker="skip"> test </a>

bobbym33667819
Level 3
Level 3

Hi kautuksahni,

Thank you very much for your suggestions. The links are actually to assets that have space in their names, but the folders don't. It has left from being copied to a text file first and then pasted here. The correct error would be:

10.04.2018 15:32:37.715 *ERROR* [sling-default-5637-com.day.cq.rewriter.linkchecker.impl.LinkCheckerTask.2368] com.day.cq.rewriter.linkchecker.impl.LinkCheckerTask Failed to validate URLhttp://10.112.100.240:4502/assetdetails.html/content/dam/msi-dam/photography/room-scenes/bedroom/1-2...0009.jpg: java.net.URISyntaxException: Illegal character in path at index 109:http://10.112.100.240:4502/assetdetails.html/content/dam/msi-dam/photography/room-scenes/bedroom/1-2...0009.jpg

Character 109 would be the space in Bedroom 0009.jpg

Are there any dangers of disabling the link checker?

Thanks again,

Bobby

avinashu3527134
Level 2
Level 2

Hello Bobby,

There should be no whitespaces and special charecters in the Folder name as well.

Thank you

Avinash Udawant