Code

Opened 4 years ago

Closed 4 years ago

#14314 closed (worksforme)

Import error on installation of Django 1.2.3

Reported by: gefisher Owned by: nobody
Component: Uncategorized Version: 1.2
Severity: Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

Hi,
I have Windows 2000 pro. and Python 2.5.2 which I've been working with for over a year.
Today I unzipped the tar ball into Program Files\DJANGO\Django-1.2.3, started up a DOS
window and issued the command "setup.py install". I immediately got the error:

Import error: no module named utils.version.

This came from the file Django-1.2.3\django\init.py where it was trying to execute
the code:

from django.utils.version import get_svn_revision.

I tried a couple of variations of the "from" relative path variable such as:

from utils.version import ...
from .django.utils.version import ...
from .utils.version import ...

to no avail. Any ideas ??

thanks in advance,

Gary -

Attachments (0)

Change History (5)

comment:1 Changed 4 years ago by ramiro

  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset
  • Resolution set to worksforme
  • Status changed from new to closed

Tried this with:

  • Windows XP 32 bits
  • Python 2.5.2
  • Django 1.2.3

and coudn't reproduce the issue.

Make sure you don't have any [incomplete] older version of Django installed.

comment:2 Changed 4 years ago by gefisher

  • Resolution worksforme deleted
  • Status changed from closed to reopened

I've never installed Django before...this is a first for me.

No ideas as to why a Python import statement would fail in your code ??

comment:3 follow-up: Changed 4 years ago by ramiro

With the steps I took to reproduce this we've discovered that the official tarball isn't the problem and so, this bug tracker isn't the right channel and the django-users mailing or the #django IRC channel list would be a better place for this.

Some things to check: Could be that the tarball you downloaded has been corrupt in any way?. Can you verify its SHA1 or MD5 checksum?. How are you unpacking it?. What tool are you using for that?. Do the 0-byte sized django\utils\__init__.py file exist?. Do the django\utils\version.py file exist?. They certainly exist in the official tarball.

comment:4 in reply to: ↑ 3 Changed 4 years ago by gefisher

Replying to ramiro:

Some things to check: Could be that the tarball you downloaded has been corrupt in any way?. Can you verify its SHA1 or MD5 checksum?.

Probably not. I just grabbed the file without bothering to do any checksum stuff.

How are you unpacking it?. What tool are you using for that?.

I'm using an older version of winzip...probably around version 6.3 or some such.

Do the 0-byte sized django\utils\__init__.py file exist?.
Do the django\utils\version.py file exist?. They certainly exist in the official tarball.

I think we're onto something here. When I use winzip to look at the tarball I see bunches of init.py files...and a lot of them are of size 0. However when I look in Django-1.2.3\django\utils there is no init.py file...perhaps because winzip didn't load it 'cause it's zero length. In the tarball it's listed to go in there but it's size is zero. Do you have an init.py file in there? I'd try this now but I'm not at home where my development system is. Thanks.

comment:5 Changed 4 years ago by ramiro

  • Resolution set to worksforme
  • Status changed from reopened to closed

Most surely that's the reason of the failures you are seeing. WinZip 6.3 is twelve years old (!).

Quoting the Django installation docs: Untar the downloaded file (e.g. tar xzvf Django-NNN.tar.gz, where NNN is the version number of the latest release). If you're using Windows, you can download the command-line tool bsdtar to do this, or you can use a GUI-based tool such as 7-zip.

Please ask further user support questions like this in the appropriate channels as suggested in a previous comment.

Add Comment

Modify Ticket

Change Properties
<Author field>
Action
as closed
as The resolution will be set. Next status will be 'closed'
The resolution will be deleted. Next status will be 'new'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.