mkb79 / audible-cli

A command line interface for audible package. With the cli you can download your Audible books, cover, chapter files.
GNU Affero General Public License v3.0
453 stars 46 forks source link

Able to download but not export library #115

Closed johnlescault closed 2 years ago

johnlescault commented 2 years ago

Hi, I can download the books successfully, but when I try to export the library as csv I get the following:

$ audible library export
Uncaught Exception
Traceback (most recent call last):
  File "/home/joey/.local/lib/python3.8/site-packages/audible_cli/cli.py", line 69, in main
    sys.exit(cli(*args, **kwargs))
  File "/home/joey/.local/lib/python3.8/site-packages/click/core.py", line 1128, in __call__
    return self.main(*args, **kwargs)
  File "/home/joey/.local/lib/python3.8/site-packages/click/core.py", line 1053, in main
    rv = self.invoke(ctx)
  File "/home/joey/.local/lib/python3.8/site-packages/click/core.py", line 1659, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/home/joey/.local/lib/python3.8/site-packages/click/core.py", line 1659, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/home/joey/.local/lib/python3.8/site-packages/click/core.py", line 1395, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/home/joey/.local/lib/python3.8/site-packages/click/core.py", line 754, in invoke
    return __callback(*args, **kwargs)
  File "/home/joey/.local/lib/python3.8/site-packages/click/decorators.py", line 84, in new_func
    return ctx.invoke(f, obj, *args, **kwargs)
  File "/home/joey/.local/lib/python3.8/site-packages/click/core.py", line 754, in invoke
    return __callback(*args, **kwargs)
  File "/home/joey/.local/lib/python3.8/site-packages/audible_cli/cmds/cmd_library.py", line 186, in export_library
    loop.run_until_complete(_export_library(session.auth, **params))
  File "/home/joey/.local/lib/python3.8/site-packages/audible_cli/config.py", line 216, in auth
    self._set_auth()
  File "/home/joey/.local/lib/python3.8/site-packages/audible_cli/config.py", line 197, in _set_auth
    self._auth = Authenticator.from_file(
  File "/home/joey/.local/lib/python3.8/site-packages/audible/auth.py", line 316, in from_file
    auth._update_attrs(**json_data)
  File "/home/joey/.local/lib/python3.8/site-packages/audible/auth.py", line 254, in _update_attrs
    setattr(self, attr, value)
  File "/home/joey/.local/lib/python3.8/site-packages/audible/auth.py", line 235, in __setattr__
    raise AttributeError(msg)
AttributeError: Authenticator is frozen, can't add attribute: with_username.
mkb79 commented 2 years ago

That sounds great. I will make the AYCL messages as debug messages and merge them later this day.