Comments (9)
I guess what @lebensterben meant was that you use .md
as a file extension, where parentheses have a special meaning. If you want to keep Markdown, you can put the link in angular brackets:
<https://raw.githubusercontent.com/ruzickap/ruzickap.github.io/70de7d813c51bbe21762a340c3fa76ced79dedb0/assets/img/posts/2022/2022-09-02-my-sony-a7-iv-settings/Sony_A7_IV_(ILCE-7M4)_-_by_Henry_S%C3%B6derlund_(51739988735).avif>
This works as expected.
Otherwise change the file extension to .txt
and you'll find that it also works and finds the full link.
from lychee.
The same issue can be reproduced with:
$ cat > test.md << \EOF
Test: https://upload.wikimedia.org/wikipedia/commons/8/8b/Sony_A7_IV_%28ILCE-7M4%29_-_by_Henry_S%C3%B6derlund_%2851739988735%29.jpg
EOF
$ lychee -v test.md
from lychee.
this is not found
from lychee.
you used a markdown file so you should use a proper link.
the parentheses have special meaning in markdown syntax and thus the parser treats the input after ( differently.
from lychee.
The full URL is (you need to copy the whole URL to test it):
https://raw.githubusercontent.com/ruzickap/ruzickap.github.io/70de7d813c51bbe21762a340c3fa76ced79dedb0/assets/img/posts/2022/2022-09-02-my-sony-a7-iv-settings/Sony_A7_IV_(ILCE-7M4)_-_by_Henry_S%C3%B6derlund_(51739988735).avif
If we consider, that I do not want to use it as a link, but as "normal" text, then it may be:
- Ignored by lychee and not scan at all
- Recognized as URL and then tested as "full URL" including all the characters which are part of the URL
-> Lychee should not recognize the patter as URL and then checked "malformed URL" + reported as non-working URL (404).
^^^ It is just my humble opinion...
What do you think about it?
from lychee.
Also see https://meta.stackexchange.com/questions/13501/links-to-urls-containing-parentheses.
from lychee.
We need something like https://github.com/rust-lang/rust/blob/a3c9eede5d50be0231f229bf28a271cd509861a3/src/librustdoc/passes/lint/bare_urls.rs#L61-L89
from lychee.
I'm not sure if I understand it properly. The link you mentioned is saying:
There are many ways to format URLs in Markdown. Parentheses work better with some methods than others.
1. Bare - http://example.com/test(1).html
2. Bare, encoded - http://example.com/test%281%29.html
3. Delimited - <http://example.com/test(1).html>
4. Hyperlink - with <a href="http://example.com/test(1).html">parens</a>
5. Markdown Link #1 - with [parens][1]
6. Markdown Link #1 - with [parens at end][2]
7. Markdown Link #2 - with [parens](http://example.com/test(1).html)
8. Markdown Link #2 - with [parens at end](http://example.com/test(1))
In this issue I'm describing (1) - Bare : where I do not want to use the URL as link, but as a standard "non-clickable" pure text.
The question is - if the bare / plain text / clean "URL-text" (including all the characters) in Markdown file should be supported by lychee or not.
Honestly I was not able to find any "official" Markdown standard which is saying - if writing bare URLs is something bad except https://github.com/updownpress/markdown-lint/blob/master/rules/034-no-bare-urls.md.
Anyway - feel free to close this ticket if it is too difficult to support bare URLs in Markdown (containing special characters) by lychee.
Thank you...
from lychee.
https://ikatyang.github.io/tree-sitter-markdown/
you can use this to test what a markdown parser will treat (
in markdown text.
this is the syntax parser for Neovim and Emacs >30.0.
from lychee.
Related Issues (20)
- Issues checking anchors/fragments in markdown files HOT 3
- Response chain
- Missing 0.15.x releases on docker hub HOT 1
- optionally fix document when URL are redirected HOT 6
- Converting Uri to Url string HOT 2
- Feature request: add FlareSolverr solver to bypass CloudFlare protection HOT 5
- custom Header not sent HOT 7
- Consider renaming `--format` to `--report` HOT 5
- Comments to ignore links HOT 1
- Consider renaming `fail_map` to `error_map` HOT 3
- Screencast SVG incurs a rendering burden on the browser HOT 1
- Optionally: Collect all URLs and deduplicate them? HOT 3
- Optionally: retrieve titles of pages and URL fragment targets? HOT 3
- Parameter --base does not work on windows HOT 13
- Archive integration with `lychee_lib` HOT 1
- bug: anchor/fragment detection doesn't appear to work HOT 1
- Windows Filepaths With a Drive Specifier Incorrectly Identified as Urls
- Mastodon link is interpreted as email address HOT 1
- ci: inconsistent naming of gh release assets
- Support URL Encoded Anchors
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from lychee.