render-engine / render-engine/render-engine
check for required values
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 61
- Forks
- 40
- Avg merge
- 4h 29m
- Merged PRs (30d)
- 10
Description
Happy to move this over to a discussion if necessary until we have a solid plan but based on #236, each object has required items that need to be defined on initialization.
This varies based on the object (not the object type).
Perhaps it would be good to create a validation step in there that checks for all of the required attributes.
To Implement
BaseObject would need a method validates that would be used to raise an AttributeError (?).
Since Page and Collection objects inherit from BaseObject then custom parsers can override it.
We can also apply the following validations.
Page - No validation
BlogPost - requires both date and content_path attributes.
Contributor guide
No contributing guide indexed for this repository
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.
Research direction
Start by reading the BaseObject, Page, Collection, and BlogPost definitions and review issue #236 for the existing required-item behavior. Determine a validation contract and exception choice before implementing it, including BlogPost requirements for date and content_path and no validation for Page. Done means initialization consistently rejects missing required attributes and the behavior is covered by tests.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- backend
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100