postlist excerpts ignores post excerpt length of 0
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 45/100
- Issue type
- Bug
- Clarity
- Mostly clear
- Activity status
- Stale
- Tech stack
- python
- Domain
- documentation
Research direction
Start from the postlist directive and its handling of the :excerpts: option, then trace how the post directive's :excerpt: 0 value is passed through. Reproduce the behavior with the provided post and postlist examples using ABlog 0.11.12; done means a post with excerpt length 0 does not display an excerpt in postlist.
Written by the indexing model from the issue text.
Description
Describe the bug
Apparently postlist ignores the length of the except being set to 0 in post.
In my case, this was quite the headscratcher, because the first paragraph was very long, so setting excerpt to 1 didn't make it smaller and setting it to 0 didn't make it smaller either.
I guess this is undefined behaviour? Since We tell postlist to show excerpts, but at the same time the post itself specifies that there should be no excerpt.
I would argue though, that someone disabling excerpts for a single post should take precedence over enabling them for everything.
To Reproduce
Set the excerpt length to 0 in a post:
.. post:: 2025-11-22
:excerpt: 0
Get the post using postlist:
.. postlist:: 5
:list-style: circle
:format: {date} {title}
:date: %Y-%m-%d
:excerpts:
Screenshots
No response
System Details
ABlog version 0.11.12
Installation method
pip
- Dominant language
- Python
- Stars
- 196
- Forks
- 64
- PR merge metrics
- No merged PRs in 30d
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from sunpy/ablog
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
Difficulty 3/5 1-2 days Newbie friendliness 48/100
-
Difficulty 4/5 3-5 days Newbie friendliness 35/100
-
Difficulty 5/5 Over a week Newbie friendliness 25/100
-
Difficulty 5/5 Over a week Newbie friendliness 20/100
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
bancolombia/sentinel#23 ·
-
test md OpenCI
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
-
integration:quickjs org:external priority:backlog topic:code-interpreter topic:middleware type:feature
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
langchain-ai/deepagents#6450 ·
-
bug client
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100