Pymavlink, error

hi guys, so I tried installing mavproxy, followed all the steps (using pip3)

but I still cannot run I got :command not found.
and so I tried and my bin file, and it requested me to also install python3-pymavlink.

installed pymavlink, ran mavtogpx and got success. tried running still got me to command not found. (but it is there in home/.local/bin and also added to PATH). anyway it might say that because I dont input the argument? however turned green (runable command in my szh) after space, but not
decided to skip this all because my current priority is so I installed pip simplekml and ran and now I got this error :

Processing 00000001.BIN
Traceback (most recent call last):
  File "/home/stoneddawg/.local/lib/python3.9/site-packages/pymavlink/", line 190, in __getattr__
    i = self.fmt.colhash[field]
KeyError: 'MainState'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/local/bin/", line 201, in <module>
    process_file(f, args.source)
  File "/usr/local/bin/", line 154, in process_file
    add_data(tdays, msg, msg_types, mlog.messages, fields, field_types, position_field_type)
  File "/usr/local/bin/", line 61, in add_data
    v = mavutil.evaluate_expression(f, vars)
  File "/home/stoneddawg/.local/lib/python3.9/site-packages/pymavlink/", line 59, in evaluate_expression
    return mavexpression.evaluate_expression(expression, vars, nocondition)
  File "/home/stoneddawg/.local/lib/python3.9/site-packages/pymavlink/", line 42, in evaluate_expression
    v = eval(expression, globals(), vars)
  File "<string>", line 1, in <module>
  File "/home/stoneddawg/.local/lib/python3.9/site-packages/pymavlink/", line 192, in __getattr__
    raise AttributeError(field)
AttributeError: MainState

im not gonna use APM Planner 2, because the “convert to KML” is also producing bad KML even though it was successful. also I tried mission planner in mono but it crashes when converting .bin to KML or KMZ.

I don’t mind with using command line tools to set my params and post flight tools, but im so confuse which is to install? mavproxy or pymavlink? or both? and how is the complete setup should be?

edit : solved the command not found issue(its path is in bashrc not zshsrc…) but not the mavkml issue…

additional question too, pip/pip3 installed mavproxy and pymavlink to /usr/.local, but the mavproxy guide in was pointing to $Home/.local, and i have and all the other script in both directory now, which one is the correct one?