Does README.md have max characters? #23920
-
In my repo (https://github.com/halfrost/LeetCode-Go) README doesn’t render complete. The last line is incomplete: You can see this problem in this commit: https://github.com/halfrost/LeetCode-Go/tree/7989003450a23bf1c27a34201f124cb2745d7096, the last line of README.md. In my local, it looks correct.
This file has no grammatical errors, but GitHub can not render it complete. Does this README.md trigger max characters? Why GitHub renders it incomplete? It’s a bug or not? |
Beta Was this translation helpful? Give feedback.
Replies: 10 comments 1 reply
-
In my local, it looks correct: |
Beta Was this translation helpful? Give feedback.
-
Hey @halfrost o/ That is strange, and I wish I could say I have a substantial answer for you straight away, but I don’t =( I’ve scoured each our docs, internal ticket history, slack history, and even our own codebase. I’ve been unable to find any documented (or coded) character limits on markdown files; I have seen some internal comments that suggest, no; we do not have a character limit. But because of the experience you see, there very well may be a limit. Since I’ve spent some time on this, I’m hesitant to keep digging before hearing from you. Since that README is so extensive, should we discuss the usability of the page? Is there functionality elsewhere that makes navigating such a large page easy for your users? While I can definitely go back here and ping some folks, I would wonder why we’re not breaking these segments into their own files, or even into gists, to store that information. Rather than having it all live in the README. I can assume that just having that bit of knowledge as an official stance is valuable, but perhaps it may be best in your case to consider organizing the information in another way. Do please let me know what you think, and if any other users have run into this, curious to hear what people think and if I need to go hunt down that person potentially responsible for this unforeseen limit/bug. Cheers 🙇 |
Beta Was this translation helpful? Give feedback.
-
Hi, @nethgato Thanks for your reply. I try some solutions which contain different words in the README. I am sure this behavior, trimming some characters, is made by Github render. However, I support your opinions. If README is too long, this is really unfriendly to the readers. I have split it into different parts. In the latest commit, everything is fine. Finally, thank you for patiently answering this strange question of mine. Maybe I waste your time. 😅 |
Beta Was this translation helpful? Give feedback.
-
Hey @halfrost – absolutely not a waste of time! Thank you for replying back and being willing to rethink your approach to the layout of your README. It really would be great to have an official answer, but it was rather difficult to track down. I had hoped to avoid pinging too many folks in an attempt to find that answer. If there’s any more interest in finding it, I can re-engage with folks that may know better than myself. Surprisingly, it was more difficult than I thought it would be =D |
Beta Was this translation helpful? Give feedback.
-
Hey @nethgato , I also run into some kind of README limitation as well. But it only seems to apply for the Readme displayed on the main repo page, and not if you open the same file directly. The readme rendering here is cut off: GitHub - ml-tooling/best-of-ml-python at 2020.12.27 while the rendering here for the same file is fine: best-of-ml-python/README.md at 2020.12.27 · ml-tooling/best-of-ml-python · GitHub . I did a few experiments and figured out that the limitation seems to be around 500k characters. However, this might be just a coincidence and maybe there is just a rendering timeout for the main repo page. Update: I think I figured out the limit. The readme on the main page only renders the first 512 KB of the README.md file. This is around 500k characters (+/- a few thousand). |
Beta Was this translation helpful? Give feedback.
-
Here is another example with just using lorem ipsum text: The text on the main repo page is cut off |
Beta Was this translation helpful? Give feedback.
-
I experienced the same problem. GitHub - kaiwensun/leetcode at cd1f682e8e8bd17c1bb67ee0c8c260b4d4537d19 is the last healthy version of README. After I insert some more text in the middle of the readme, the tail of the readme is truncated as in GitHub - kaiwensun/leetcode at 6922b8e0521641f5b570fe83a77e2c5243473788 . Same as what @LukasMasuch mentioned,
|
Beta Was this translation helpful? Give feedback.
-
We’ve seen the complaints of this same issue from multiple users. I am new to GitHub community. What is the correct way to get attention from GitHub staff to get this fixed? If here is not the correct channel, can you point me to the correct one? Thank you. |
Beta Was this translation helpful? Give feedback.
-
Hi all, I opened a private support ticket to GitHub support team in Sept 2021. The short answer is "GitHub currently limit blob displaying to around 500 KB of data" when the readme is displayed at the home page of the repo. The following is the full reply from the GitHub support team.
|
Beta Was this translation helpful? Give feedback.
-
Looks like GitHub recently reduced the max limit even more! WITHOUT NOTICE! This is a BREAKING CHANGE! Also, the workaround "However, as you may have noticed, accessing the blob directly works just fine" does not work anymore. Cutting a new private support ticket to GitHub. |
Beta Was this translation helpful? Give feedback.
Hey @halfrost o/
That is strange, and I wish I could say I have a substantial answer for you straight away, but I don’t =(
I’ve scoured each our docs, internal ticket history, slack history, and even our own codebase. I’ve been unable to find any documented (or coded) character limits on markdown files;
README
or otherwise.I have seen some internal comments that suggest, no; we do not have a character limit. But because of the experience you see, there very well may be a limit. Since I’ve spent some time on this, I’m hesitant to keep digging before hearing from you.
Since that README is so extensive, should we discuss the usability of the page? Is there functionality elsewhere that makes…