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

Dead link in the README.md #804

Open
kyanny opened this issue Jan 8, 2025 · 6 comments
Open

Dead link in the README.md #804

kyanny opened this issue Jan 8, 2025 · 6 comments

Comments

@kyanny
Copy link

kyanny commented Jan 8, 2025

Hi,

I found that this link https://ruby-doc.org/stdlib/exts/readline/Readline.html in the README.md is 404 Not Found.

❯ curl -X GET -IL https://ruby-doc.org/stdlib/exts/readline/Readline.html
HTTP/1.1 302 Found
Date: Wed, 08 Jan 2025 16:38:30 GMT
Server: Apache/2.4.29 (Ubuntu)
Location: https://ruby-doc.org/3.4.1/exts/readline/Readline.html
Content-Length: 317
Content-Type: text/html; charset=iso-8859-1

HTTP/1.1 404 Not Found
Date: Wed, 08 Jan 2025 16:38:31 GMT
Server: Apache/2.4.29 (Ubuntu)
Last-Modified: Mon, 03 Jul 2023 00:21:33 GMT
ETag: "1c42-5ff8a261a6507"
Accept-Ranges: bytes
Content-Length: 7234
Content-Type: text/html

/stdlib/exts/readline/Readline.html does not exist in 3.4.1 doc. There are a few pages related to Readline but they appear blank.

Image

3.3.6 has the same issue.

3.2.6 does not have the issue. https://ruby-doc.org/3.2.6/exts/readline/Readline.html exists.

I am not sure what approach is the best:

so just reporting it to the Reline maintainers.

@st0012
Copy link
Member

st0012 commented Jan 8, 2025

ruby-doc.org is NOT the official documentation website, nor is rubydoc.info. The official one is https://docs.ruby-lang.org/en and I don't think it has this problem as the sidebar section you screenshotted seems to be a customization of ruby-doc.org.

So unless there's also a deadlink on the official website, there's nothing we can fix here.

@kyanny
Copy link
Author

kyanny commented Jan 9, 2025

Hi @st0012 thank you for the comment.

https://docs.ruby-lang.org/en/master/Readline.html exists (good news) but it looks less informative than https://ruby-doc.org/3.2.6/exts/readline/Readline.html (bad news)

If you agree with updating the link in README.md to https://docs.ruby-lang.org/en/master/Readline.html I am happy to open a pull request.

(just in case - I am talking about this dead link)
Image

@ima1zumi
Copy link
Member

ima1zumi commented Jan 9, 2025

The page at https://docs.ruby-lang.org/en/master/Readline.html is displaying Reline documentation instead of Readline documentation. We should fix RDoc or RDoc generation process.

@kyanny
Copy link
Author

kyanny commented Jan 9, 2025

readline is no longer a standard library (now it's readline-ext gem) so its documentation never shows up on https://docs.ruby-lang.org/en/, am I correct?

Does it make sense to remove the link from the README.md like below?

diff --git a/before.md b/after.md
index a28588e..02a4e0b 100644
--- a/before.md
+++ b/after.md
@@ -2,4 +2,4 @@
 
 It's compatible with the readline standard library.
 
-See [the document of readline stdlib](https://ruby-doc.org/stdlib/exts/readline/Readline.html) or [bin/example](https://github.com/ruby/reline/blob/master/bin/example).
+See [bin/example](https://github.com/ruby/reline/blob/master/bin/example).

@st0012
Copy link
Member

st0012 commented Jan 9, 2025

If you agree with updating the link in README.md to https://docs.ruby-lang.org/en/master/Readline.html I am happy to open a pull request.

Ah yes, we should fix it. Sorry that I missed that part.

The page at https://docs.ruby-lang.org/en/master/Readline.html is displaying Reline documentation instead of Readline documentation. We should fix RDoc or RDoc generation process.

I believe it comes from: https://github.com/ruby/ruby/blob/master/lib/readline.rb#L6. If you remove this part Readline disappears from the generated documentation.

Since ruby/ruby is aliasing the constants, I think this is a correct behaviour. We can, however, exclude readline.rb from documentation generation by updating ruby/ruby's rdoc config.

@st0012
Copy link
Member

st0012 commented Jan 9, 2025

Ideally, I think reline should have its own documentation for all of its features and stop referencing to readline's docs.

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

No branches or pull requests

3 participants