title: Why is %1 rarely substituted in "%1 is not a valid Win32 application."
body: <p>I'm sure most Windows developers are familiar with this error message, usually when trying to mix 32- and 64-bit executables. In particular Python and Java can both get it.</p>
  
  <blockquote>
    <p><a href="https://stackoverflow.com/search?q=%22%251%20is%20not%20a%20valid%20Win32%20application%22%20is%3Aquestion">%1 is not a valid Win32 application.</a></p>
  </blockquote>
  
  <p>It's clear that <code>%1</code> represents the first argument to the failing command - i.e. the executable that is trying to be loaded - but why does it not get filled in with the actual path?</p>
  
  <p>Is it something that the caller is doing wrong, or is it a basic failing of some Windows subsystem that cannot be fixed for compatibility reasons?</p>