Problem with backup to OneDrive

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Problem with backup to OneDrive

duplicity-talk mailing list
Hi,

When I'm trying to backup to my OneDrive I get the following error (duplicity 0.7.17-1):


Traceback (innermost last):
  File "/usr/bin/duplicity", line 1555, in <module>
    with_tempdir(main)
  File "/usr/bin/duplicity", line 1541, in with_tempdir
    fn()
  File "/usr/bin/duplicity", line 1380, in main
    action = commandline.ProcessCommandLine(sys.argv[1:])
  File "/usr/lib/python2.7/site-packages/duplicity/commandline.py", line 1135, in ProcessCommandLine
    backup, local_pathname = set_backend(args[0], args[1])
  File "/usr/lib/python2.7/site-packages/duplicity/commandline.py", line 1010, in set_backend
    globals.backend = backend.get_backend(bend)
  File "/usr/lib/python2.7/site-packages/duplicity/backend.py", line 223, in get_backend
    obj = get_backend_object(url_string)
  File "/usr/lib/python2.7/site-packages/duplicity/backend.py", line 209, in get_backend_object
    return factory(pu)
  File "/usr/lib/python2.7/site-packages/duplicity/backends/onedrivebackend.py", line 90, in __init__
    self.initialize_oauth2_session()
  File "/usr/lib/python2.7/site-packages/duplicity/backends/onedrivebackend.py", line 127, in initialize_oauth2_session
    self.http_client.refresh_token(self.OAUTH_TOKEN_URI)
  File "/usr/lib/python2.7/site-packages/requests_oauthlib/oauth2_session.py", line 309, in refresh_token
    self.token = self._client.parse_request_body_response(r.text, scope=self.scope)
  File "/usr/lib/python2.7/site-packages/oauthlib/oauth2/rfc6749/clients/base.py", line 409, in parse_request_body_response
    self.token = parse_token_response(body, scope=scope)
  File "/usr/lib/python2.7/site-packages/oauthlib/oauth2/rfc6749/parameters.py", line 376, in parse_token_response
    validate_token_parameters(params)
  File "/usr/lib/python2.7/site-packages/oauthlib/oauth2/rfc6749/parameters.py", line 383, in validate_token_parameters
    raise_from_error(params.get('error'), params)
  File "/usr/lib/python2.7/site-packages/oauthlib/oauth2/rfc6749/errors.py", line 325, in raise_from_error
    raise cls(**kwargs)
 InvalidGrantError: (invalid_grant) The user could not be authenticated or the grant is expired. The user must first sign in and if needed grant the client application access to the requested scope.

10:15:58.159 Task 'BKP' failed with exit code '30'.
--- Finished state FAILED 'code 30' at 10:15:58.159 - Runtime 00:00:01.096 ---

Shouldn't there be a link where I can authenticate myself?

Thanks,
Thomas

_______________________________________________
Duplicity-talk mailing list
[hidden email]
https://lists.nongnu.org/mailman/listinfo/duplicity-talk
Reply | Threaded
Open this post in threaded view
|

Re: Problem with backup to OneDrive

duplicity-talk mailing list
On 28.03.2018 10:26, Thomas via Duplicity-talk wrote:

> Hi,
>
> When I'm trying to backup to my OneDrive I get the following error (duplicity 0.7.17-1):
>
>
> Traceback (innermost last):
>   File "/usr/bin/duplicity", line 1555, in <module>
>     with_tempdir(main)
>   File "/usr/bin/duplicity", line 1541, in with_tempdir
>     fn()
>   File "/usr/bin/duplicity", line 1380, in main
>     action = commandline.ProcessCommandLine(sys.argv[1:])
>   File "/usr/lib/python2.7/site-packages/duplicity/commandline.py", line 1135, in ProcessCommandLine
>     backup, local_pathname = set_backend(args[0], args[1])
>   File "/usr/lib/python2.7/site-packages/duplicity/commandline.py", line 1010, in set_backend
>     globals.backend = backend.get_backend(bend)
>   File "/usr/lib/python2.7/site-packages/duplicity/backend.py", line 223, in get_backend
>     obj = get_backend_object(url_string)
>   File "/usr/lib/python2.7/site-packages/duplicity/backend.py", line 209, in get_backend_object
>     return factory(pu)
>   File "/usr/lib/python2.7/site-packages/duplicity/backends/onedrivebackend.py", line 90, in __init__
>     self.initialize_oauth2_session()
>   File "/usr/lib/python2.7/site-packages/duplicity/backends/onedrivebackend.py", line 127, in initialize_oauth2_session
>     self.http_client.refresh_token(self.OAUTH_TOKEN_URI)
>   File "/usr/lib/python2.7/site-packages/requests_oauthlib/oauth2_session.py", line 309, in refresh_token
>     self.token = self._client.parse_request_body_response(r.text, scope=self.scope)
>   File "/usr/lib/python2.7/site-packages/oauthlib/oauth2/rfc6749/clients/base.py", line 409, in parse_request_body_response
>     self.token = parse_token_response(body, scope=scope)
>   File "/usr/lib/python2.7/site-packages/oauthlib/oauth2/rfc6749/parameters.py", line 376, in parse_token_response
>     validate_token_parameters(params)
>   File "/usr/lib/python2.7/site-packages/oauthlib/oauth2/rfc6749/parameters.py", line 383, in validate_token_parameters
>     raise_from_error(params.get('error'), params)
>   File "/usr/lib/python2.7/site-packages/oauthlib/oauth2/rfc6749/errors.py", line 325, in raise_from_error
>     raise cls(**kwargs)
>  InvalidGrantError: (invalid_grant) The user could not be authenticated or the grant is expired. The user must first sign in and if needed grant the client application access to the requested scope.
>
> 10:15:58.159 Task 'BKP' failed with exit code '30'.
> --- Finished state FAILED 'code 30' at 10:15:58.159 - Runtime 00:00:01.096 ---
>
> Shouldn't there be a link where I can authenticate myself?

maybe it's only implemented if loading the token fails. try renaming/deleting '~/.duplicity_onedrive_oauthtoken.json' ..ede/duply.net

_______________________________________________
Duplicity-talk mailing list
[hidden email]
https://lists.nongnu.org/mailman/listinfo/duplicity-talk
Reply | Threaded
Open this post in threaded view
|

Re: Problem with backup to OneDrive

duplicity-talk mailing list
Hi ede,

Thank you, that solved my problem!

Regards,
Thomas

2018-03-28 11:11 GMT+02:00 edgar.soldin--- via Duplicity-talk <[hidden email]>:
On 28.03.2018 10:26, Thomas via Duplicity-talk wrote:
> Hi,
>
> When I'm trying to backup to my OneDrive I get the following error (duplicity 0.7.17-1):
>
>
> Traceback (innermost last):
>   File "/usr/bin/duplicity", line 1555, in <module>
>     with_tempdir(main)
>   File "/usr/bin/duplicity", line 1541, in with_tempdir
>     fn()
>   File "/usr/bin/duplicity", line 1380, in main
>     action = commandline.ProcessCommandLine(sys.argv[1:])
>   File "/usr/lib/python2.7/site-packages/duplicity/commandline.py", line 1135, in ProcessCommandLine
>     backup, local_pathname = set_backend(args[0], args[1])
>   File "/usr/lib/python2.7/site-packages/duplicity/commandline.py", line 1010, in set_backend
>     globals.backend = backend.get_backend(bend)
>   File "/usr/lib/python2.7/site-packages/duplicity/backend.py", line 223, in get_backend
>     obj = get_backend_object(url_string)
>   File "/usr/lib/python2.7/site-packages/duplicity/backend.py", line 209, in get_backend_object
>     return factory(pu)
>   File "/usr/lib/python2.7/site-packages/duplicity/backends/onedrivebackend.py", line 90, in __init__
>     self.initialize_oauth2_session()
>   File "/usr/lib/python2.7/site-packages/duplicity/backends/onedrivebackend.py", line 127, in initialize_oauth2_session
>     self.http_client.refresh_token(self.OAUTH_TOKEN_URI)
>   File "/usr/lib/python2.7/site-packages/requests_oauthlib/oauth2_session.py", line 309, in refresh_token
>     self.token = self._client.parse_request_body_response(r.text, scope=self.scope)
>   File "/usr/lib/python2.7/site-packages/oauthlib/oauth2/rfc6749/clients/base.py", line 409, in parse_request_body_response
>     self.token = parse_token_response(body, scope=scope)
>   File "/usr/lib/python2.7/site-packages/oauthlib/oauth2/rfc6749/parameters.py", line 376, in parse_token_response
>     validate_token_parameters(params)
>   File "/usr/lib/python2.7/site-packages/oauthlib/oauth2/rfc6749/parameters.py", line 383, in validate_token_parameters
>     raise_from_error(params.get('error'), params)
>   File "/usr/lib/python2.7/site-packages/oauthlib/oauth2/rfc6749/errors.py", line 325, in raise_from_error
>     raise cls(**kwargs)
>  InvalidGrantError: (invalid_grant) The user could not be authenticated or the grant is expired. The user must first sign in and if needed grant the client application access to the requested scope.
>
> 10:15:58.159 Task 'BKP' failed with exit code '30'.
> --- Finished state FAILED 'code 30' at 10:15:58.159 - Runtime 00:00:01.096 ---
>
> Shouldn't there be a link where I can authenticate myself?

maybe it's only implemented if loading the token fails. try renaming/deleting '~/.duplicity_onedrive_oauthtoken.json' ..ede/duply.net

_______________________________________________
Duplicity-talk mailing list
[hidden email]
https://lists.nongnu.org/mailman/listinfo/duplicity-talk


_______________________________________________
Duplicity-talk mailing list
[hidden email]
https://lists.nongnu.org/mailman/listinfo/duplicity-talk