Files icon indicating copy to clipboard operation
Files copied to clipboard

Convert FileOperationsHandler + FileTagsHandler to helpers

Open itsWindows11 opened this issue 3 years ago • 9 comments

Resolved / Related Issues Items resolved / related issues by this PR.

  • Related #4180.
  • Related #9858

Validation How did you test these changes?

  • [x] Built and ran the app
  • [ ] Tested the changes for accessibility

Screenshots (optional) Add screenshots here.

itsWindows11 avatar Sep 17 '22 18:09 itsWindows11

hmm, I don't think there's another process that's using this file

---> System.IO.IOException: The process cannot access the file 'C:\Users\itswi\AppData\Local\Packages\FilesDev_ykqwq8d6ps0ag\LocalState\filetags.db' because it is being used by another process.

itsWindows11 avatar Sep 18 '22 10:09 itsWindows11

Can you verify is Files still able to launch? I cannot launch Files on my computer with this PR anymore, it hangs in the background constantly.

hez2010 avatar Sep 21 '22 12:09 hez2010

Can you verify is Files still able to launch? I cannot launch Files on my computer with this PR anymore, it hangs in the background constantly.

Works for me, dunno why it shouldn't work for you

itsWindows11 avatar Sep 21 '22 13:09 itsWindows11

Works for me, dunno why it shouldn't work for you

Did you try deploying a Release package and running it?

hez2010 avatar Sep 21 '22 13:09 hez2010

Nope, will try in a few hours

itsWindows11 avatar Sep 21 '22 13:09 itsWindows11

May related: https://github.com/files-community/Files/pull/10031 Will test again after that PR merged.

hez2010 avatar Sep 21 '22 14:09 hez2010

May related: https://github.com/files-community/Files/pull/10031 Will test again after that PR merged.

Can confirm it's #10031.

Other findings:

  • Paste: doesn't work
  • Delete: doesn't work
  • Property-Security: doesn't work
  • Create items: doesn't work

hez2010 avatar Sep 21 '22 14:09 hez2010

hmm, I don't think there's another process that's using this file

---> System.IO.IOException: The process cannot access the file 'C:\Users\itswi\AppData\Local\Packages\FilesDev_ykqwq8d6ps0ag\LocalState\filetags.db' because it is being used by another process.

This is expected becuase now we are trying to open filetags.db across multiple Files instances, which is not supported by LiteDB. You can leave this problem as is and open a new issue for it. We need to use something like mutex to make sure there's only one connection simultaneously, and synchronize the database operations across multiple instances.

hez2010 avatar Sep 21 '22 15:09 hez2010

I see, will do

itsWindows11 avatar Sep 21 '22 15:09 itsWindows11

Properties - Details doesn't work. When paste or delete multiple files, the "ongoing task" doesn't reflect the process properly. Paste and Delete still doesn't work if there're multiple Files instances running simultaneously.

hez2010 avatar Sep 22 '22 16:09 hez2010

Properties - Details doesn't work.

I can reproduce this even when building from the main branch so doesn't seem related to this PR.

When paste or delete multiple files, the "ongoing task" doesn't reflect the process properly. Paste and Delete still doesn't work if there're multiple Files instances running simultaneously.

Will take a look. EDIT: Attempting to fix that issue results in a crash with the same filetags.db problem, I don't really know how to fix it.

itsWindows11 avatar Sep 23 '22 09:09 itsWindows11

Any news? cc. @hez2010 @yaichenbaum

itsWindows11 avatar Sep 29 '22 21:09 itsWindows11

Sorry for the delay. Will take care of this PR in next few days.

hez2010 avatar Sep 30 '22 05:09 hez2010

@itsWindows11 almost ready to look at this, can you resolve the merge conflicts?

yaira2 avatar Oct 12 '22 04:10 yaira2

Sure thing, expect some commits tomorrow.

itsWindows11 avatar Oct 12 '22 09:10 itsWindows11

Doesn't look like a build error I can fix; I can compile the app on my end. image

itsWindows11 avatar Oct 14 '22 14:10 itsWindows11

@itsWindows11 thank you for all you work and keeping up with this PR!

yaira2 avatar Oct 19 '22 00:10 yaira2