Bug 367988 - kio-gdrive requires re-OAUTH if don't wait for for a folder to completely load.
Summary: kio-gdrive requires re-OAUTH if don't wait for for a folder to completely load.
Status: RESOLVED FIXED
Alias: None
Product: kio-gdrive
Classification: Frameworks and Libraries
Component: general (show other bugs)
Version: unspecified
Platform: Other Linux
: NOR major
Target Milestone: ---
Assignee: Elvis Angelaccio
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-08-30 07:02 UTC by zellox
Modified: 2016-10-01 22:28 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In: 1.0.1


Attachments
Possible fix (887 bytes, patch)
2016-10-01 11:09 UTC, Elvis Angelaccio
Details

Note You need to log in before you can comment on or make changes to this bug.
Description zellox 2016-08-30 07:02:34 UTC
Revision 8231017 (last one to support KF5GAPI < 5.3.0)

When opening a folder with this, If I don't wait for the folder to completely load (i.e. sizes have gone from *blank* to "Unknown") before I open one of its subfolders, I get prompted to reauthenticate via OAUTH. This occurs every time and makes this fairly unusuable.
Comment 1 Elvis Angelaccio 2016-09-19 17:58:09 UTC
Hi, I've not tried to reproduce yet, because my test gdrive account is not that big.
Anyway, can you try again with the beta (v0.9.81)?
Comment 2 zellox 2016-09-19 22:57:09 UTC
Still occuring with the latest git master.

I should also clarify that the issue doesn't occur in the main folder, but it does with any subfolder below the root.
Comment 3 Elvis Angelaccio 2016-09-30 19:32:02 UTC
I finally managed to reproduce by creating a deep nesting of folders. It seems random though.
Comment 4 zellox 2016-10-01 09:32:37 UTC
Strange, it occurs every time in any subfolder of the main folder for me.

Is there a debug log that might help?
Comment 5 Elvis Angelaccio 2016-10-01 11:09:50 UTC
Created attachment 101367 [details]
Possible fix

This patch should fix the bug, please test.
Comment 6 Elvis Angelaccio 2016-10-01 14:38:12 UTC
Git commit beb01773c0d297e59717f8c060866e07db09a265 by Elvis Angelaccio.
Committed on 01/10/2016 at 14:32.
Pushed by elvisangelaccio into branch '1.0'.

Fix broken QUrl construction

This fixes a regression caused by the KUrl -> QUrl port.
QUrl::fromUserInput results in an URL with the http:// scheme,
while we need to gdrive:// one.
Related: bug 369581
FIXED-IN: 1.0.1

M  +4    -2    src/kio_gdrive.cpp

http://commits.kde.org/kio-gdrive/beb01773c0d297e59717f8c060866e07db09a265
Comment 7 Elvis Angelaccio 2016-10-01 14:42:20 UTC
(In reply to Elvis Angelaccio from comment #5)
> Created attachment 101367 [details]
> Possible fix
> 
> This patch should fix the bug, please test.

Got confirmation that the patch works, so I pushed it.
Comment 8 zellox 2016-10-01 22:28:14 UTC
I had some issues building it, but yep, can confirm it works, making it usable now. Thanks!