-
-
Notifications
You must be signed in to change notification settings - Fork 38
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
[FR]: config creates full path if it doesn't exist #271
Comments
It's not limited. If you specify full path it should work. Did you test and verify it's not working with the full path? |
Yes, checking a recent log, it matches the code as it's only using the "basename" instead of /full/path/to/basename_bin
|
Looks like orphaned directory also is limited to be Lines 397 to 400 in 30c3bea
|
The code that you shared is only specifying the default recycle path and default orphaned path. Those are being used as default when the user does not specify. I just tested this and it's working correctly with specifying the exact path. It will use the default if the folder you specified does not exist or is not accessible. That's probably why you are seeing it use the default recycle directory. |
Interesting, most likely permission issue on my setup I'll check into. Instead of the original default being used, since it overrides the default to include the basename of what I specified, this wasn't what I expected when the full path is inaccessible and I didn't see any related error. |
yeah I can add additional logs. In case you're wondering, the code that does the check to see if the folder exists is found here: Lines 181 to 183 in 9e621e3
|
I'm also wondering what the reasoning is to override the default ".RecycleBin" to instead point to the Permissions look correct but looking deeper now. |
It's because of #77, Not everyone might want the name What is currently set in your config.yml under directory? |
I was trying to reuse my NAS' recycle bin path. Dug a little deeper and looks like my issue resulted from the difference of how the full path is treated vs. the default: For the full path check, it's never created and only checked for existence, but the basename path is created when it doesn't exist already. I was assuming the full path would be created as well. the basename path being created silently led to my confusion. Lines 181 to 185 in 9e621e3
This warning message used to be silently dropped before your new commit, since one of the branches returned before printing any message. I'd consider this issue resolved with 2 more minor improvements:
706821f#diff-c39b942d8f8620d46d314db8301189b8d6195fc97aedbeb124a33694b738d69cR202-R203 |
Can you test the new develop branch? It should create the Recycle Bin folder now for the path you specified. |
I'm running hotio's container image, I can try the nightly tag but doesn't seem to have a develop tag. |
Yes, hotios nightly tag points to develop branch |
Yep, just verified on :nightly, it created Recycle Bin at the full path specified. |
Is your feature request related to a problem? Please elaborate.
The recycle bin config variable is always treated as a subfolder of
remote_dir
, and when specifying a full path it is stripped to it's basename, which becomes the last folder of a full path:qbit_manage/modules/config.py
Line 412 in 30c3bea
Describe the solution you'd like
The example config and comment indiciate it's used an the full path
# <OPTIONAL> recycle_bin var: </your/path/here/> # Path of the RecycleBin folder. Default location is set to remote_dir/.RecycleBin
Instead of joining paths, just treat it as a full path when specified.
Does your solution involve any of the following?
Describe alternatives you've considered
The default may be a subfolder, but why limit it in this way?
Who will this benefit?
Any custom configurations
Additional Information
No response
The text was updated successfully, but these errors were encountered: