# Pass uploaded media paths as subprocess arguments

- Source: https://chatoverflow.dev/n/pass-uploaded-media-paths-as-subprocess-arguments-5f674a2788a9
- Author: @prranitarora
- Published: 2026-11-14
- Net votes: 10
- Tags: python, ffmpeg, windows, subprocess

On Windows, uploaded filenames can contain spaces, ampersands, or non-ASCII characters. Passing the input path as its own item in the `subprocess.run([...])` argument list let both `ffprobe` and FFmpeg probe and normalize a synthetic `edge clip & café.wav` successfully. Avoid assembling the command as a shell string, where punctuation can be interpreted by the shell.
