Deleting file issue in Windows, cannot download content after deleting (until restart) #182

Closed
opened 2017-06-02 00:13:46 +02:00 by tzarebczan · 6 comments
tzarebczan commented 2017-06-02 00:13:46 +02:00 (Migrated from github.com)

The Issue

After downloading a file, I clicked Options > Remove. When prompted to delete the file to from my PC, checked Yes. The file does not get deleted, and instead, the permissions on the file get screwed up where I can't delete it normally from my download folder (don't have read access anymore).

This usually happens when you try to download, play and then remove a few times.

Steps to reproduce

  1. Download Video
  2. Remove Video and check remove from PC

Expected behaviour

File should get removed, allow to redownload

Actual behaviour

File does not get removed, permissions are changed, cannot delete manually. Cannot redownload. See below for screenshot

System Configuration

  • LBRY Daemon version:
  • LBRY App version: v0.11.9
  • LBRY Installation ID:
  • Operating system: Windows

Anything Else

Screenshots

lbry permissions

<!-- Thanks for reporting an issue to LBRY and helping us improve! To make it possible for us to help you, please fill out below information carefully. Before reporting any issues, please make sure that you're using the latest version. - App releases: https://github.com/lbryio/lbry-app/releases - Standalone daemon: https://github.com/lbryio/lbry/releases We are also available on Slack at https://slack.lbry.io --> ## The Issue After downloading a file, I clicked Options > Remove. When prompted to delete the file to from my PC, checked Yes. The file does not get deleted, and instead, the permissions on the file get screwed up where I can't delete it normally from my download folder (don't have read access anymore). This usually happens when you try to download, play and then remove a few times. ### Steps to reproduce 1. Download Video 2. Remove Video and check remove from PC 3. ### Expected behaviour File should get removed, allow to redownload ### Actual behaviour File does not get removed, permissions are changed, cannot delete manually. Cannot redownload. See below for screenshot ## System Configuration <!-- For the app, this info is in the About section at the bottom of the Help page. You can include a screenshot instead of typing it out --> <!-- For the daemon, run: curl 'http://localhost:5279/lbryapi' --data '{"method":"version"}' and include the full output --> - LBRY Daemon version: - LBRY App version: v0.11.9 - LBRY Installation ID: - Operating system: Windows ## Anything Else <!-- Include anything else that does not fit into the above sections --> ## Screenshots <!-- If a screenshot would help explain the bug, please include one or two here --> ![lbry permissions](https://cloud.githubusercontent.com/assets/8120721/26702577/9d5eecda-46f3-11e7-9ecf-42f4465b3636.PNG)
kauffj commented 2017-06-16 01:33:58 +02:00 (Migrated from github.com)

Please verify this happens in 0.12.2 or later.

Please verify this happens in 0.12.2 or later.
tzarebczan commented 2017-12-12 15:11:17 +01:00 (Migrated from github.com)

This has been happening recently again to me. The LBRY.exe process (according to process explorer) holds a file handle on the downloaded file. Only way to get rid of the download is to restart LBRY or manually delete the file handle.

This causes issues when users try to delete and re-download content. If a user tries to download content which this happened to, it tells them it can't access the file and does not download.

This has been happening recently again to me. The LBRY.exe process (according to process explorer) holds a file handle on the downloaded file. Only way to get rid of the download is to restart LBRY or manually delete the file handle. This causes issues when users try to delete and re-download content. If a user tries to download content which this happened to, it tells them it can't access the file and does not download.
Grayyyyy commented 2018-06-17 18:59:40 +02:00 (Migrated from github.com)

Can confirm, having the issue on the latest RC.

System Config:
image

Can confirm, having the issue on the latest RC. System Config: ![image](https://user-images.githubusercontent.com/37783688/41510201-db462c94-7225-11e8-83dd-244c5de5aab8.png)
tzarebczan commented 2018-08-23 06:14:02 +02:00 (Migrated from github.com)

Pretty sure something in our code holds a lock on the file. Maybe render media, or Electron, not sure.

Lock:
locked
The daemon wil say:

2018-08-23 00:11:10,947 ERROR    lbrynet.database.storage:34: Traceback (most recent call last):
  File "site-packages\lbrynet\database\storage.py", line 31, in _open_file_for_writing
IOError: [Errno 13] Permission denied: 'D:\\LBRY Downloads Main PC\\zcqZHYo7ONs_2.mp4'
Pretty sure something in our code holds a lock on the file. Maybe render media, or Electron, not sure. Lock: ![locked](https://content.screencast.com/users/thomas.zarebczan/folders/Snagit/media/5f312382-de64-4b6a-9584-28e2f0487824/08.23.2018-00.13.png) The daemon wil say: ``` 2018-08-23 00:11:10,947 ERROR lbrynet.database.storage:34: Traceback (most recent call last): File "site-packages\lbrynet\database\storage.py", line 31, in _open_file_for_writing IOError: [Errno 13] Permission denied: 'D:\\LBRY Downloads Main PC\\zcqZHYo7ONs_2.mp4' ```
kauffj commented 2018-08-23 15:59:43 +02:00 (Migrated from github.com)

@tzarebczan I think better rerpo would aid in resolving this. Can you try to create smallest reproducible case? e.g.

  1. If I simply render a <video> tag, does this lock the file?
  2. If I render a video tag with render-media, does this do it? etc.
@tzarebczan I think better rerpo would aid in resolving this. Can you try to create smallest reproducible case? e.g. 1. If I simply render a `<video>` tag, does this lock the file? 2. If I render a video tag with render-media, does this do it? etc.
alyssaoc commented 2018-12-07 20:22:29 +01:00 (Migrated from github.com)

closing, reopen if this is still an issue

closing, reopen if this is still an issue
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: LBRYCommunity/lbry-desktop#182
No description provided.