views:

306

answers:

5

I tried getting these frameworks working on Windows Vista for a couple of days but to no avail.

Every single time I thought I had them working I would get some random error involving the PostgreSQL or MySQL setup, or the paths were screwed up or some other command line error "not recognized as an internal or external command" (or something). Someone told me that these frameworks are a lot easier to get running on Ubuntu but I really don't want to make that switch as everything I have is on Windows. Are these common problems when trying to get running on Windows?

I think I'll just stick with C# and .NET as everything seems to work pretty nicely together with none of this "install-twenty-different-components" stuff and see if they work together. Is Instant Django advisable to use?

+8  A: 

I have installed Django on multiple Windows systems (both XP and Vista) with absolutely no issues. After installing Python, it is as easy as typing this in a command line, in the folder to which you extracted Django:

python setup.py install

If you're on Vista, perhaps you can try running your command window "as administrator" to see if that gives you any better luck.

Ryan Duffield
It was installed in the site-packages folder within Python. Where would I type this command 'python setup.py install'?
Mackristo
python setup.py install is the command that will put Django in site-packages. What happens in a python console when you type the following? import django
Ryan Duffield
+2  A: 

Django didn't work on my Vista, and that's because Vista screws up command line arguments. See the bottom of this page for solution.

In my experience, Ubuntu and other Debian-based OSes are much more trouble-free developer environments for almost everything except C# and .NET stuff. That said, C# and .NET obviously are quite excellent on Windows.

Joonas Pulakka
+1  A: 

Yes. RoR and Django were difficult to install on Vista.

I apologize for not having specifics, but here's a general recount of my problem and how I overcame it. Maybe there is something here for you.

For Python: Your Vista install may have a pre-existing path variable for Python that interferes. For example, on my HP computer, HP has Python from the factory. The HP Python path pointed to the HP Python, not the latest that I download for Django. Check Control Panel-->System-->Advanced System Settings-->Advanced Tab-->Environment Variables-->System Variables, then check what the "PATH" is. I changed that path to my fresh install of Python, and then everything worked.

For RoR: Are you using the one click installer? I forgot the specifics, but I know right-clicking the 1-Click Installer file and "Run as Administrator" was one of the tricks.

For RoR and Django: Consider NOT using MySQL and Postgres, at this time. Using the default SQLite that comes with the Ruby/Python installers should keep you happy at this stage of the game. SQLite is good enough for tinkering and doesn't use as many resources as a full stack database.

Good luck!

Paulb
+2  A: 

I use Instant Rails made to tackle the complaints of the difficult installation process on Windows. It contains Ruby, Rails, MySQL, PHP and phpMyAdmin. Downloading and extracting the file to a folder and running a script should do the work.

Tarscher
A: 

django and python didn't work for me using the windows vista command line until I opened the windows registry and set:

Computer\HKEY_CLASSES_ROOT\py_auto_file\shell\open\command(Default)

to

"C:\Python26\python.exe" "%1" %*

Dion Liddell