This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author ssbarnea
Recipients ssbarnea
Date 2010-08-27.11:42:15
SpamBayes Score 5.515875e-07
Marked as misclassified No
Message-id <1282909340.45.0.225876683414.issue9699@psf.upfronthosting.co.za>
In-reply-to
Content
Behavior: you get "The input line is too long." error message when you try to run an external process by using os.system(), subprocess.Popen() or other similar methods.

The real command line limit is 8192 under Windows and in most cases (if not all) the cause for getting this message is not the length.

The real cause is that if you even have a quote inside your command line you need to include the entire command in quote.

Here are some details:
http://stackoverflow.com/questions/682799/what-to-do-with-the-input-line-is-too-long-error-message/3583282#3583282
http://msdn.microsoft.com/en-us/library/96ayss4b.aspx (see comment)

Even if this is caused by a bug on Windows that is present for more than ten years I think Python needs to workaround it by adding the quotes when they are needed.

This will prevent other developers from writing OS specific code in their Python programs in order to workaround this bug.
History
Date User Action Args
2010-08-27 11:42:20ssbarneasetrecipients: + ssbarnea
2010-08-27 11:42:20ssbarneasetmessageid: <1282909340.45.0.225876683414.issue9699@psf.upfronthosting.co.za>
2010-08-27 11:42:17ssbarnealinkissue9699 messages
2010-08-27 11:42:15ssbarneacreate