Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

When renaming a file with a name that contains " / " the generated folder drives Windows 10 crazy #15378

Open
5 tasks done
DumboJetEngine opened this issue Aug 26, 2021 · 12 comments
Labels
Feature request OS: Windows Issues specific to Windows Waiting info Waiting for participants to supply more info/fulfill template requirements

Comments

@DumboJetEngine
Copy link

I am using the latest version of your client on Win10.
I like your client but I have some suggestions:

  • When you have many torrents, torrents that are at the bottom of the list get virtually no chance to start downloading, even if the preceding torrents are completely idle. Once I put them at the top of the list, they usually start downloading. uTorrent seemed to work better in this area.
  • When a torrent with not all its files selected for download is complete, and you add one extra file from it for download (check its checkbox), the torrent should (I believe) move at the top of the torrents list, so that it gets more priority and can be located easily.
  • Renaming files and folders should not allow illegal characters to be used. And they should be removed automatically when you paste a name. Currently, you enter unrecoverable situations, where in one case I had to resort to the Windows cmd-line to delete undeletable files and folders using short (DOS 8.3) names. Terrible experience!
  • When a torrent is complete, but some files are excluded, right clicking on the torrent files that are skipped to initiate their download should be possible (and changing their priority too). Now it is not, and you can only check their checkbox to make them be included for download.
  • When adding a new torrent and you get the dialog to select the path, you should get an option to put the torrent first in the torrents list. Without this, finding the torrent is not so easy if you have many torrents.

All of these features (I only doubt about the illegal path characters removal feature) are present in uTorrent, which I was using in the past.

  • Also, there is a tiny visual bug (black menu) on the right click menu of the Comment section of the "add new torrent" dialog:
    image

Checklist

  • I have read the feature request section in the contributing guidelines, so I know how to submit a good feature request with the required information
  • I have verified that the feature I am requesting is not available in the latest version
  • (optional but recommended) I have verified that the feature I am requesting is not available in the latest CI build
  • I have checked the frequent/common issues list and searched the issue tracker for similar feature requests (including closed ones) to avoid posting a duplicate
  • This request is not a support request or question, both of which are better suited for either the discussions section, forum, or subreddit. The wiki did not contain a suitable solution either

Description

Suggestion

(type here)

Use case

(type here)

Extra info/examples/attachments

@glassez
Copy link
Member

glassez commented Aug 27, 2021

  • When you have many torrents, torrents that are at the bottom of the list get virtually no chance to start downloading, even if the preceding torrents are completely idle. Once I put them at the top of the list, they usually start downloading. uTorrent seemed to work better in this area.

Do you mean the torrents that are currently selected for downloading (i.e. top in download queue) but really have no connected peers?

  • When a torrent with not all its files selected for download is complete, and you add one extra file from it for download (check its checkbox), the torrent should (I believe) move at the top of the torrents list, so that it gets more priority and can be located easily.

Why this action should override download queue? Maybe someone doesn't want this? You can move it up in the queue in the case it's really needed. I don't think it should be done by default.

  • Renaming files and folders should not allow illegal characters to be used. And they should be removed automatically when you paste a name. Currently, you enter unrecoverable situations, where in one case I had to resort to the Windows cmd-line to delete undeletable files and folders using short (DOS 8.3) names. Terrible experience!

Don't understand really what do you mean.
If qBittorrent is able to create file/folder with some characters in the name then such characters are legal. Otherwise, the file creation/renaming would have failed.

  • When adding a new torrent and you get the dialog to select the path, you should get an option to put the torrent first in the torrents list. Without this, finding the torrent is not so easy if you have many torrents.

The "Add new torrent" dialog is used to choose some initial options of torrent before torrent is added (or cancel adding it if you want). You can disable this dialog in application preferences so your torrents will be added to the list with default options.

@DumboJetEngine
Copy link
Author

DumboJetEngine commented Aug 27, 2021

Do you mean the torrents that are currently selected for downloading (i.e. top in download queue) but really have no connected peers?

  • I mean the torrents that have a number in the column with # as a header (those that are pending for download). When they are placed at the bottom (maximum number/index), it feels that they are totally neglected by the app, even if there are no active torrents in the list. Usually, once I put them at the first position (index 0), they immediately begin downloading. So, it isn't a missing seed/peer problem, but it feels like a scheduling problem.

Why this action should override download queue? Maybe someone doesn't want this? You can move it up in the queue in the case it's really needed. I don't think it should be done by default.

  • OK. But actually, when it downloads the selected files the first time and the torrent gets completed, it loses its index (the # column has no value, but a * sign). So, you don't actually change the queue, rather you decide what index you should assign to it. Now you assign the last index to it. BUT, I often get into this situation: I download a huge torrent in batches. Let's say that I have the torrent at index 0 (top priority). I first select 10 files from it. Once they get downloaded, it gets an index of * (no index). Once I select more files, the torrent does not get its previous index (0), but it goes at the end of the queue (where it also gets significantly less priority and it is harder for me to find again). You can see why this is annoying... I have to find and set the index of a torrent multiple times. And if I don't, it usually doesn't even start, as mentioned in the previous bullet.

Don't understand really what do you mean.
If qBittorrent is able to create file/folder with some characters in the name then such characters are legal. Otherwise, the file creation/renaming would have failed.

  • Yes, I have noticed that it creates folders when it comes across a slash character. That could be considered a feature, although it is annoying sometimes because you cannot undo it. But I believe there are more characters that cause a problem. And I was thinking that it might be good to do what Windows Explorer does when renaming files/folders: remove all illegal characters. Maybe you can also ask the user what to do when there are slashes in the name to avoid accidental structure changes. In my case (which has happened twice so far) the text had a slash and maybe some other characters (I am still trying to figure out what is causing it...). It did create a directory, as expected, placed the file in it, but then things became weird. Even with the app closed and the file unlocked, I could not delete or move the file. Windows Explorer reported no errors, it just didn't obey. The cmd-line reported some crazy error messages about not finding the entry. Nothing worked except using DOS 8.3 names form the cmd-line to delete the file. So, it seems that some character in the name triggers a bug in Windows, making the file undeletable. I have the impression that a space in front of the name could be the reason. So, if you try renaming a file as : "Test / file.png" (emphasis on the spaces around the slash), you might reproduce my problem on the PNG file.

The "Add new torrent" dialog is used to choose some initial options of torrent before torrent is added (or cancel adding it if you want). You can disable this dialog in application preferences so your torrents will be added to the list with default options.

  • What interests me the most is adding the torrent at the top of the queue (having an option for it). Because you often want a torrent to get the highest priority. I was using uTorrent previously and that option was pretty handy, even without the problem of low queue priority torrents not starting:
    image
    See option "Add to top of queue" above ^^^.

@thalieht
Copy link
Contributor

When you have many torrents, torrents that are at the bottom of the list get virtually no chance to start downloading, even if the preceding torrents are completely idle. Once I put them at the top of the list, they usually start downloading. uTorrent seemed to work better in this area.

Do you use "Do not count slow torrents in those limits"? That option is capped by "Max active torrents" so set it to -1 (for infinite) if you want all torrents to have a chance to start downloading (eventually). If you already do this, i can't imagine what else you expect from the queue system.
(Maybe we should change the default of "Max active torrents" to -1? It's not visible anywhere that it caps the aforementioned option and users are left wondering that it doesn't work well.)

Renaming files and folders should not allow illegal characters to be used. And they should be removed automatically when you paste a name. Currently, you enter unrecoverable situations, where in one case I had to resort to the Windows cmd-line to delete undeletable files and folders using short (DOS 8.3) names. Terrible experience!

Related/duplicate of #15227

When a torrent is complete, but some files are excluded, right clicking on the torrent files that are skipped to initiate their download should be possible (and changing their priority too). Now it is not, and you can only check their checkbox to make them be included for download.

Has been asked before but i can't find it.

When adding a new torrent and you get the dialog to select the path, you should get an option to put the torrent first in the torrents list. Without this, finding the torrent is not so easy if you have many torrents.

Duplicate of #11599

Also, there is a tiny visual bug (black menu) on the right click menu of the Comment section of the "add new torrent" dialog:

For some reason it uses a custom stylesheet. Removing the following seems to fix it but i don't know why it was introduced or if it's the right solution so i'll leave it alone:

<property name="styleSheet">
<string notr="true">background-color: rgba(0, 0, 0, 0);</string>
</property>

I mean the torrents that have a number in the column with # as a header

I think it's about time we rename that column to "Queue" or "Queue Position".

/Off topic
Looks like you "Read and accepted the terms and conditions" with the checklist:
https://github.com/qbittorrent/qBittorrent/blob/master/CONTRIBUTING.md#steps-to-ensure-a-good-bug-report

Post only one specific issue per submission.

and about duplicates.

@DumboJetEngine
Copy link
Author

DumboJetEngine commented Aug 27, 2021

Do you use "Do not count slow torrents in those limits"? That option is capped by "Max active torrents" so set it to -1 (for infinite) if you want all torrents to have a chance to start downloading (eventually). If you already do this, i can't imagine what else you expect from the queue system.
(Maybe we should change the default of "Max active torrents" to -1? It's not visible anywhere that it caps the aforementioned option and users are left wondering that it doesn't work well.)

Hm...
I have the "Do not count slow torrents in those limits" unchecked.
Probably this is the default value?
But when all torrents are idle (0 B/s for upload/download), shouldn't it ignore those torrents anyway, even with the option unchecked?
I mean, zero traffic is essentially "inactive".
Not sure if the displayed "0 B/s" is a rounded value of something not zero, but I doubt that.
Also, not sure if the forced states ( [F] ) is counted as "active", even when there is no traffic for the torrent.

Sorry for not finding the duplicates and for the multiple issues reported here.
I should have at least found #15227.
The last one (stuffing multiple things in one page) is a bad habit of mine that I must stop. :(

@DumboJetEngine
Copy link
Author

Related/duplicate of #15227

Regarding this, I will try to verify if spaces at the start of file names indeed cause Windows to go nuts.
It's always spoiling my psychology to deal with 8.3 names, so I was trying to avoid testing it so far...
When dealing with #15227, maybe remember that this is another potential thing to fix.

@DumboJetEngine
Copy link
Author

DumboJetEngine commented Aug 27, 2021

UPDATE:

I just verified that spaces cause problems. Try this:

Rename any torrent file to contain this sequence " / " (space-slash-space) somewhere in the middle. At this point the qBitTorrent UI should have displayed the created folder but it doesn't. You should deselect and re-select the torrent for the newly created folder to appear.
Then select the file and do "Open containing folder". At this point, you will see that Windows Explorer goes nuts when visiting this folder (tested on Win10).

To delete the files you have to use 8.3 names (found from dir /X).
It seems that the problem is the folder that has a space appended to its name.
Not sure why.

@xavier2k6
Copy link
Member

xavier2k6 commented Aug 27, 2021

Also, there is a tiny visual bug (black menu) on the right click menu of the Comment section of the "add new torrent" dialog:

image

For some reason it uses a custom stylesheet. Removing the following seems to fix it but i don't know why it was introduced or if it's the right solution so i'll leave it alone:

<property name="styleSheet">
<string notr="true">background-color: rgba(0, 0, 0, 0);</string>
</property>

Seems this may have been introduced in error by specifically this commit: 008e385 in PR #9591 which was adopted by PR #10600 for v4_2_x branch & was backported to v4_1_x branch in PR #10615

so this bug has been there a good while!

@xavier2k6
Copy link
Member

#15383 opened to address bug in #15378 (comment)

@Chocobo1
Copy link
Member

Seems this may have been introduced in error by specifically this commit: 008e385 in PR #9591 which was adopted by PR #10600 for v4_2_x branch & was backported to v4_1_x branch in PR #10615

PR #15387 will remove it.

@allanlaal
Copy link
Contributor

@DumboJetEngine please make the title less generic :)

@DumboJetEngine DumboJetEngine changed the title Some improvements/features that might be nice When renaming a file with a name that contains " / " the generated folder drives Windows 10 crazy Sep 30, 2021
@DumboJetEngine
Copy link
Author

@allanlaal
Done. :)
I used the description of the most important bug (renaming file to something that contains " / ").
I could create issues for the improvement suggestions too, but I am not sure if you want them or not.

@Snowknight26
Copy link

Snowknight26 commented Oct 1, 2021

To add to the "illegal" character issue, Explorer has different limitations when it comes to accessing files with "illegal" characters than the Win32 API does.

  • With Explorer, you can't access files where the path length is >255 characters (or something to that effect)
    • You can still access the path using the "\?\X:\whatever" notation in things such as the command prompt, PowerShell, etc.
  • Explorer doesn't allow you to create a file/folder that ends with a period (well it does, but it removes the period before creating said file/folder)
    • Again, if you make one with a trailing period, you can still access it with the above example

With that in mind, it seems like qBittorrent allows technically valid characters (such as "/" or an ending ".", but surprisingly not "?") during file operations but Explorer certainly doesn't handle them well.

@luzpaz luzpaz added the Waiting info Waiting for participants to supply more info/fulfill template requirements label Nov 13, 2023
@luzpaz luzpaz added the OS: Windows Issues specific to Windows label Feb 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature request OS: Windows Issues specific to Windows Waiting info Waiting for participants to supply more info/fulfill template requirements
Projects
None yet
Development

No branches or pull requests

8 participants