question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

HTTPError - Invalid Input

See original GitHub issue

Hi, I keep getting this error when running this program. Through a Python file and the cli.

noah@Noahs-MBP ~ % python3 -m md2notion "***" "https://www.notion.so/***/Test-***" "/Users/noah/Documents/test.md" 
Initializing Notion.so client...
Getting target PageBlock...
Traceback (most recent call last):
  File "/opt/homebrew/Cellar/python@3.9/3.9.6/Frameworks/Python.framework/Versions/3.9/lib/python3.9/runpy.py", line 197, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "/opt/homebrew/Cellar/python@3.9/3.9.6/Frameworks/Python.framework/Versions/3.9/lib/python3.9/runpy.py", line 87, in _run_code
    exec(code, run_globals)
  File "/opt/homebrew/lib/python3.9/site-packages/md2notion/__main__.py", line 5, in <module>
    cli(sys.argv[1:])
  File "/opt/homebrew/lib/python3.9/site-packages/md2notion/upload.py", line 199, in cli
    page = client.get_block(args.page_url)
  File "/opt/homebrew/lib/python3.9/site-packages/notion/client.py", line 169, in get_block
    block = self.get_record_data("block", block_id, force_refresh=force_refresh)
  File "/opt/homebrew/lib/python3.9/site-packages/notion/client.py", line 162, in get_record_data
    return self._store.get(table, id, force_refresh=force_refresh)
  File "/opt/homebrew/lib/python3.9/site-packages/notion/store.py", line 184, in get
    self.call_load_page_chunk(id)
  File "/opt/homebrew/lib/python3.9/site-packages/notion/store.py", line 286, in call_load_page_chunk
    recordmap = self._client.post("loadPageChunk", data).json()["recordMap"]
  File "/opt/homebrew/lib/python3.9/site-packages/notion/client.py", line 260, in post
    raise HTTPError(
requests.exceptions.HTTPError: Invalid input.

Any reason for this? Thanks 😃

Issue Analytics

  • State:open
  • Created 2 years ago
  • Reactions:9
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

11reactions
laobycommented, Aug 24, 2021

I do like this: pip install notion-cobertos-fork,but had other problem, then do pip uninstall notion-cobertos-fork and then pip install notion-cobertos-fork

2reactions
five-five0909commented, Jun 26, 2022

Hello, I am a novice, now I also encounter this problem, always fail, do you have a complete solution, because I really can not understand what everyone said, sorry for bothering you

Read more comments on GitHub >

github_iconTop Results From Across the Web

For those getting 'HTTPError( requests.exceptions ... - GitHub
For those getting 'HTTPError( requests.exceptions.HTTPError: Invalid input.)' #14 ... I keep getting this error "raise HTTPError( requests.exceptions.
Read more >
python - can't get page title from notion using api
HTTPError : Invalid input. My code is that I'm using is from notion.client import NotionClient import time token_v2 = "my page tocken" client ......
Read more >
HTTP API Errors - commercetools documentation
Common HTTP error codes returned by the commercetools Composable Commerce APIs and their meaning. ... Returned when an invalid JSON input has been...
Read more >
notion-py - Bountysource
requests.exceptions.HTTPError: Invalid input. Someone is getting the same error or there are any updates in the lib? 1
Read more >
400 Bad Request - HTTP - MDN Web Docs
... perceived to be a client error (for example, malformed request syntax, invalid request message framing, or deceptive request routing).
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found