#Plex-Image-Cleanup FileNotFoundError: [Errno 2] No such file or directory: '/plex/PIC Restore/
1 messages · Page 1 of 1 (latest)
Welcome @south torrent!
Someone from <@&938443185347244033> will assist when they're available.
Including the meta.log from the beginning is a huge help, type !logs for more information.
You can press the "Close Post" button above or type /close at any time to close this post.
What platform is this?
@manic reef docker on unraid.
@stray light :
- MODE=move
- plex pointing to the plex directory (which is correct as "remove" and "report" works)
- config pointing to a config volume
- PLEX_URL and PLEX_TOKEN set (again correct since remove and report work)
- PLEX_PATH=/plex
That's all that is configured
Seems like you have the PIC Restore folder there
Pretty sure you might need to run mode: clear between mode: move
Will try. Indeed I created it manually since when it was not there it also nagged. But I never ran mode:clear! Will try!
First ran clear without erros. Then move
| Moving Bloat Images |
| Moving Bloat Images: 0%| | 0/5718 [00:00<?, ? moved/s]
| MOVE: /plex/Metadata/TV Shows/1/e78a80970a9ac5bd74bc94a9bb82c193235f631.bundle/Uploads/posters/seasons/2/32527605db67646a3c9f9c341725d63f789a8053 --> /plex/PIC Restore/TV Shows/1/e78a80970a9ac5bd74bc94a9bb82c193235f631.bundle/Uploads/posters/seasons/2/32527605db67646a3c9f9c341725d63f789a8053.jpg |
| Traceback (most recent call last): |
| File "//plex_image_cleanup.py", line 321, in run_plex_image_cleanup |
| util.move_path(path, meta_dir, restore_dir, suffix=".jpg") |
| File "/usr/local/lib/python3.11/site-packages/pmmutils/util.py", line 60, in move_path |
| final_path.parent.mkdir(exist_ok=True) |
| File "/usr/local/lib/python3.11/pathlib.py", line 1116, in mkdir |
| os.mkdir(self, mode) |
| FileNotFoundError: [Errno 2] No such file or directory: '/plex/PIC Restore/TV Shows/1/e78a80970a9ac5bd74bc94a9bb82c193235f631.bundle/Uploads/posters/seasons/2' |
| |
| [Errno 2] No such file or directory: '/plex/PIC Restore/TV Shows/1/e78a80970a9ac5bd74bc94a9bb82c193235f631.bundle/Uploads/posters/seasons/2' |
[Errno 2] No such file or directory
Plex Meta Manager has been instructed to look at a file or directory that does not exist on the host system.
Ensure that the file/folder exists, or change the source file that is specifying the invalid location.
So same result....
are you able to navigate to this directory?
/plex/Metadata/TV Shows/1/e78a80970a9ac5bd74bc94a9bb82c193235f631.bundle/Uploads/posters/seasons/2/32527605db67646a3c9f9c341725d63f789a8053
is Plex running on WIndows, Docker, Unix>>
I am suspecting that this might be hitting some strange character length limit
and can you look at the PIC Restore folder and see if anything is in there or is it a completely empty directory?
I have the same error:
PLEX_PATH=/plex
MODE=move
#SCHEDULE=08:00|weekly(sunday)|mode=clear,09:00|weekly(sunday)|mode=move
PLEX_URL=http://192.168.2.242:32400
PLEX_TOKEN=(redacted)
DISCORD=(redacted)
TIMEOUT=600
SLEEP=60
IGNORE_RUNNING=True
LOCAL_DB=False
USE_EXISTING=False
PHOTO_TRANSCODER=True
EMPTY_TRASH=True
CLEAN_BUNDLES=True
OPTIMIZE_DB=True
TRACE=False
latest and develop have the same errors
trying something now
I think its a security issue
well... what I tried did not work...
@manic reef any ideas? I have tried to run locally with python on my windows machine, but having no luck either... all I get is the following:
and getting the same errors as the OP when running with latest and develop tag
My last experiments with PIC are here:
https://docs.google.com/document/d/10K5dpN5iwKv1eNrk2T4SSlqDk1X7DdUyOsAmLe5LScI/edit?usp=sharing
I haven't tried it with Windows as I have no Windows machines available.
well.. the container is failing so I thought I might try it locally and that failing
failing in that it has issues with the mkdir PIC Restore
so mode=move is not working
using the pycharm debugger, it exits at line 91
local run on linux working fine:
python plex_image_cleanup.py -u https://SOME_URL -t SOME_TOKEN -p /mnt/PIC-sftp -m report
|====================================================================================================|
| ____ _ __ __ _ __ __ |
| | _ \| | _____ __ | \/ | ___| |_ __ _ | \/ | __ _ _ __ __ _ __ _ ___ _ __ |
| | |_) | |/ _ \ \/ / | |\/| |/ _ \ __/ _` | | |\/| |/ _` | '_ \ / _` |/ _` |/ _ \ '__| |
| | __/| | __/> < | | | | __/ || (_| | | | | | (_| | | | | (_| | (_| | __/ | |
| |_| |_|\___/_/\_\ |_| |_|\___|\__\__,_| |_| |_|\__,_|_| |_|\__,_|\__, |\___|_| |
| |___/ |
| Plex Image Cleanup |
| |
| Version: 1.0.2 (Python 3.11.6) (Git: master) |
| Platform: Linux-6.5.0-14-generic-x86_64-with-glibc2.35 |
| Memory: 15 GB |
|====================================================================================================|
| Run Command: plex_image_cleanup.py -u (redacted) -t (redacted) -p /mnt/PIC-sftp -m report |
| --plex (PLEX_PATH): /mnt/PIC-sftp |
| --mode (MODE): report |
...
| Reporting Complete: Reported 1356 Bloat Images |
| Potential Recovery: 262.63 MBs |
| Runtime: 0:00:00 |
|====================================================================================================|
| Plex Image Cleanup Summary |
|====================================================================================================|
| Running in Report Mode |
|============================================= Database =============================================|
| Downloaded New Database |
| Downloaded | 0:00:01 |
| Query | 0:00:00 |
|====================================== Reporting Bloat Images ======================================|
| 262.63 MBs of Potential Recovery Reporting 1356 Files |
| Scan Time | 0:04:37 |
| Report Time | 0:00:00 |
|=================================== Plex Image Cleanup Finished ====================================|
| Total Runtime | 0:04:41 |
|====================================================================================================|
k... not using a .env
I also have an env in place, which it is reading from
oh
i do have a couple of rpi devices that I guess I could try... they are running ubuntu
well... let me stop for a second... let me try the container in report mode
works the same using only .env:
python plex_image_cleanup.py
|====================================================================================================|
| ____ _ __ __ _ __ __ |
| | _ \| | _____ __ | \/ | ___| |_ __ _ | \/ | __ _ _ __ __ _ __ _ ___ _ __ |
| | |_) | |/ _ \ \/ / | |\/| |/ _ \ __/ _` | | |\/| |/ _` | '_ \ / _` |/ _` |/ _ \ '__| |
| | __/| | __/> < | | | | __/ || (_| | | | | | (_| | | | | (_| | (_| | __/ | |
| |_| |_|\___/_/\_\ |_| |_|\___|\__\__,_| |_| |_|\__,_|_| |_|\__,_|\__, |\___|_| |
| |___/ |
| Plex Image Cleanup |
| |
| Version: 1.0.2 (Python 3.11.6) (Git: master) |
| Platform: Linux-6.5.0-14-generic-x86_64-with-glibc2.35 |
| Memory: 15 GB |
|====================================================================================================|
| Run Command: plex_image_cleanup.py |
| --plex (PLEX_PATH): /mnt/PIC-sftp |
| --mode (MODE): report |
| --schedule (SCHEDULE): |
| --url (PLEX_URL): (redacted) |
...
so I am running the container with .env ala report mode
so report mode is working fine
MODE=move is the issue that both OP and I are now having
its just finishing up the last 3 plex operations thatI set to true... so report mode is looking good
here is move mode:
only thing I changed between the two is MODE=report to MODE=move
attempting the MODE=remove now
looks good:
I suspect the script is not building out all those directories before trying the move.
I let Sohjiro know and labelled this thread for Sohjiro to review