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

fix(@astrojs/rss): prevent an error when pubDate is missing #12137

Merged
merged 2 commits into from
Oct 7, 2024

Conversation

ArmandPhilippot
Copy link
Contributor

@ArmandPhilippot ArmandPhilippot commented Oct 6, 2024

This PR fixes an issue reported in Doc repository: pubDate is optional when generating RSS items since #9610 but if not provided an error is thrown (Invalid input (items.0.pubDate)).

I have not created a ticket, but I have a minimal reproduction (just delete one of the pubDate).

Changes

Testing

  • I added a test and an item without date: it was failing before, now it passes.
  • I tested manually with pnpm link with the minimal reproduction and the feed is now correctly generated

All previous tests still work!

Docs

I added two different changesets since there was two issues (the doc + the bug). Otherwise, I don't think we need more documentation, the current one is already up to date.

/cc @withastro/maintainers-docs for feedback!

Copy link

changeset-bot bot commented Oct 6, 2024

🦋 Changeset detected

Latest commit: 523c1c7

The changes in this PR will be included in the next version bump.

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Copy link
Member

@bluwy bluwy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great!

@matthewp matthewp merged commit 50dd88b into withastro:main Oct 7, 2024
13 checks passed
@astrobot-houston astrobot-houston mentioned this pull request Oct 7, 2024
@ArmandPhilippot ArmandPhilippot deleted the fix/astro-rss-pubdate branch October 7, 2024 15:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants