notional
notional copied to clipboard
Notion Children Length exceeded when parsing large HTML
Notional Version: 0.7.3
Description
On parsing a large HTML document to notion content, I get the following error:
notion_client.errors.APIResponseError: body failed validation: body.children.length should be ≤
100, instead was
123.
A clear and concise description of what the bug is.
Steps To Reproduce
If html
is a reasonably large (eg blog article sized) document, we can reproduce this error like this:
from notional.parser import HtmlParser
parser.parse(html)
Expected Behavior
The html is correctly parsed to notion
@dominiczy Notion doesn't allow you to send >100 children per API request. Use the Append Block Children api and send the content in chunks.