D29782: [StatJob] Make mostLocalUrl ignore remote (ftp, http...etc) URLs

2020-05-23 Thread Ahmad Samir
ahmadsamir added a comment. This wasn't landed on master, but rather phabricator is confused by me pushing to work/ branch on gitlab :) REPOSITORY R241 KIO REVISION DETAIL https://phabricator.kde.org/D29782 To: ahmadsamir, #frameworks, dfaure, sitter Cc: kde-frameworks-devel,

D29782: [StatJob] Make mostLocalUrl ignore remote (ftp, http...etc) URLs

2020-05-23 Thread Ahmad Samir
This revision was not accepted when it landed; it landed in state "Needs Review". This revision was automatically updated to reflect the committed changes. Closed by commit R241:f2984ff28e72: [StatJob] Make mostLocalUrl ignore remote (ftp, http...etc) URLs (authored by ahmadsamir). CHANGED

D29782: [StatJob] Make mostLocalUrl ignore remote (ftp, http...etc) URLs

2020-05-16 Thread David Faure
dfaure added a comment. OK, I picked testtrash because kio_trash *is* a :local protocol. If it doesn't use UDS_LOCAL_PATH, at least it means the job will actually go through (no early filtering out). That's at least interesting to test too. Good that http will give no error. That's

D29782: [StatJob] Make mostLocalUrl ignore remote (ftp, http...etc) URLs

2020-05-16 Thread Ahmad Samir
ahmadsamir added a comment. I've just realised, we won't get an error with an http url; in that case we return the url the statjob was called on as-is and cancel the job. REPOSITORY R241 KIO REVISION DETAIL https://phabricator.kde.org/D29782 To: ahmadsamir, #frameworks, dfaure, sitter

D29782: [StatJob] Make mostLocalUrl ignore remote (ftp, http...etc) URLs

2020-05-16 Thread Ahmad Samir
ahmadsamir added a comment. In D29782#672157 , @dfaure wrote: > Can you add a unittest for a KIO::mostLocalUrl() in testtrash.cpp (which is :local, so it should work) I don't see where the trash ioslave sets UDS_LOCAL_PATH; I think it

D29782: [StatJob] Make mostLocalUrl ignore remote (ftp, http...etc) URLs

2020-05-16 Thread David Faure
dfaure added a comment. Can you add a unittest for a KIO::mostLocalUrl() in testtrash.cpp (which is :local, so it should work) and another one in jobtest.cpp for a http URL (e.g. to test which error code we're getting, if any?) + call mostLocalUrl() on a "normal" StatJob in

D29782: [StatJob] Make mostLocalUrl ignore remote (ftp, http...etc) URLs

2020-05-15 Thread Ahmad Samir
ahmadsamir updated this revision to Diff 82974. ahmadsamir retitled this revision from "[StatJob] Change mostLocalUrl to only handle protocols with Class=:local" to "[StatJob] Make mostLocalUrl ignore remote (ftp, http...etc) URLs". ahmadsamir edited the summary of this revision. ahmadsamir