UserCLI reports "Successful" when file does not exist

Request Type:

MCEBuddy Version and Type ( 64bit):
MCEBuddy 2.4 Release 8

Operating System and Type (64bit):
Windows 10 Pro N (with media installed) version 1803

Summary of the problem or suggestion:
The problem I am seeing is the commandline interface reports success (and I believe returns 0) instead of an error when a file is not found. This includes files that do not exist or network paths that cannot be reached.

If it reported an error it would be easier to debug failures from Plex postprocessing, etc.

Steps to replicate the bug:
C:\Users\Owen>“C:\Program Files\MCEBuddy2x\MCEBuddy.UserCLI.exe” --command=addfile --action=“C:\Videos\Test.wtv”

Above command with no file called “Test.wtv” present will return “Success” but really it should be an error.
Full prompt output:

C:\Users\Owen>“C:\Program Files\MCEBuddy2x\MCEBuddy.UserCLI.exe” --command=addfile --action=“C:\Videos\Test.wtv”

MCEBuddy.UserCLI is a Command Line Interface for users to interact with the MCEBuddy engine
Copyright © RBoy, Build Version :
Build Date : 01/24/2018 16:02:42

MCEBuddy.UserCLI trying to connect to Engine localhost on Port 23332

MCEBuddy.UserCLI successfully connected to MCEBuddy engine
MCEBuddy.UserCLI processing command addfile
MCEBuddy.UserCLI adding file C:\Videos\Test.wtv to the conversion queue

MCEBuddy.UserCLI Successful!!

The system cannot find the path specified. (165.3 KB)

UserCLI is working as intended.

The UserCLI’s job is to pass the path of the file to the MCEBuddy engine. It cannot/should not determine if the file exists/is accessible. The engine runs in system space, so what may be accessible to the UserCLI may not be accessible to the engine and vice versa. If the CLI is passing a network path that isn’t mapped in user space the UserCLI will not be able to see or access it, however if the credentials for the network path have been provided to the engine in it’s settings, then the engine will be able to access it. Similarly the UserCLI may not have access to certain local folders, where as the engine, with it’s credentials, may be able to read them.

The CLI just passes the file path, then it’s up to the engine to see if it can access the file or not (depending on how it’s configured, if it’s a network path, are the credentials provided to the engine etc).

Sounds good - thanks for the details.

1 Like