Skip to content

Error from atom.xml when no pages have dates #592

@JVimes

Description

@JVimes

System information

If no pages have dates, I get:

Error: Failed to serve the site
Error: Failed to render 'atom.xml'
Error: Reason: Variable last_updated not found in context while rendering 'atom.xml'

Expected behaviour

No error. I'm not familiar enough with Atom to say what should be done, e.g. if it's trying to include a page it should not, or if it should leave out <updated> (which might be required?).

Actual behaviour

An error happens (above).

Steps to reproduce

  1. Set up a new site with tabi
  2. Set generate_feeds = true
  3. Create just one page, _index.md, without a date variable.
  4. Run zola serve.

Additional context

No response

Final checklist

  • I've checked that the issue isn't already reported.
  • I've tested with the latest version of tabi to check if the issue has already been fixed.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions