"Link Checker Failed to validate URL" on some links with empty space characters | Community
Skip to main content
bobbym33667819
Level 3
April 11, 2018

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

  • April 11, 2018
  • 2 replies
  • 7341 views

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-20/Bedroom 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-20/Bedroom 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-20/Bedroom 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-20/Bedroom 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/21-40/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/21-40/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

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.

2 replies

smacdonald2008
Level 10
April 11, 2018

Checking to see if there is a known issue here.

kautuk_sahni
Adobe Employee
Adobe Employee
April 12, 2018

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>

Kautuk Sahni
bobbym33667819
Level 3
April 12, 2018

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-20/Bedroom0009.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-20/Bedroom0009.jpg

Character 109 would be the space in Bedroom 0009.jpg

Are there any dangers of disabling the link checker?

Thanks again,

Bobby

Level 2
September 23, 2019

Hello Bobby,

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

Thank you

Avinash Udawant