You didn’t indicate whether you are running any python scripts on your site that use files with a “.py” ending - and I really need to know that to respond to your question completely.
This is because the simplest method of doing what you want to do is to simply use .htaccess to change how the server treats “.py” files. This will, of course, interfere with actually executing any “.py” files that are in, or below, the directory in which you make this fix (unless you reset the handler in the child directory). That said, I’ll bet Google has the answer!
A quick Google search turned up an article called “Stupid htaccess Tricks” from PerishablePress.com, in the section titled "Instruct server to display source code for dynamic file types:
[quote]There are many situations where site owners may wish to display the contents of a dynamic file rather than executing it as a script. To exercise this useful technique, create a directory in which to place dynamic files that should be displayed rather than executed, and add the following line of code to the htaccess file belonging to that directory. This method is known to work for .pl, .py, and .cgi file-types. Here it is:
RemoveHandler cgi-script .pl .py .cgi [/quote]
In your case, since it is only the .py files you are concerned about, don’t include the “.pl” or the “.cgi”.
The main article has a lot of other useful .htaccess information, and you should refer to the beginning of the article if you need help with .htaccess files in general.
The above fix will allow either the display of the code (for subsequent saving or downloading) and allow the old "right-click to “Save target as” download operation. If you don’t want to allow even the display, check the article carefully for a way to force that (it’s in there too - though I’d advise against doing that!).