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

CRITICAL: module 'pelican.contents' has no attribute 'is_valid_content' (Pelican 4.0) #5

Open
fogasl opened this issue Feb 15, 2021 · 0 comments

Comments

@fogasl
Copy link
Contributor

fogasl commented Feb 15, 2021

Using this module with Pelican > 4.0 gives this error message:
CRITICAL: module 'pelican.contents' has no attribute 'is_valid_content'

I identified the error is in the file entities.py in line 419:

if not contents.is_valid_content(entity_or_draft, f):
    self._add_failed_source_path(f)
    continue

My quick & dirty fix for this problem was replacing those lines with this:

if not entity_or_draft.is_valid():
    self._add_failed_source_path(f)
    continue

--

Laszlo

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

No branches or pull requests

1 participant