clairvoyance icon indicating copy to clipboard operation
clairvoyance copied to clipboard

TypeError: 'NoneType' object is not subscriptable

Open skroggur opened this issue 2 years ago • 3 comments

Traceback (most recent call last):
  File "/usr/lib/python3.8/runpy.py", line 194, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "/usr/lib/python3.8/runpy.py", line 87, in _run_code
    exec(code, run_globals)
  File "/home/skroggur/clairvoyance/clairvoyance/__main__.py", line 111, in <module>
    input_document = s.convert_path_to_document(s.get_path_from_root(next))
  File "/home/skroggur/clairvoyance/clairvoyance/graphql.py", line 148, in convert_path_to_document
    elif path[0] == self._schema["mutationType"]["name"]:
TypeError: 'NoneType' object is not subscriptable

What is causing this?

skroggur avatar Jun 17 '22 20:06 skroggur

Hey @skroggur,

My best guess is that the GraphQL endpoint you're testing is either (1) doesn't have mutations or (2) returns response in a format that Clairvoyance can't parse.

nikitastupin avatar Jun 18 '22 06:06 nikitastupin

Hey @skroggur! Could you check this with the latest (2.5.1) version of Clairvoyance and see whether it solved the problem? Thanks!

nikitastupin avatar Mar 18 '23 13:03 nikitastupin

We worked in this one too and in our case it has been fixed by the latest PR we made :)

iCarossio avatar Mar 18 '23 15:03 iCarossio