Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Fixed #114 -- Changed uses of deprecated 'whrandom' module to 'random'

git-svn-id: http://code.djangoproject.com/svn/django/trunk@262 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
commit 8d144dadd8b60a7ce803ebcb235718f06e2d5986 1 parent d330be0
Adrian Holovaty authored July 21, 2005
2  django/core/management.py
@@ -342,7 +342,7 @@ def _start_helper(app_or_project, name, directory, other_name=''):
342 342
 
343 343
 def startproject(project_name, directory):
344 344
     "Creates a Django project for the given project_name in the given directory."
345  
-    from whrandom import choice
  345
+    from random import choice
346 346
     _start_helper('project', project_name, directory)
347 347
     # Populate TEMPLATE_DIRS for the admin templates, based on where Django is
348 348
     # installed.
2  django/models/auth.py
@@ -172,7 +172,7 @@ def _module_make_random_password(length=10, allowed_chars='abcdefghjkmnpqrstuvwx
172 172
         "Generates a random password with the given length and given allowed_chars"
173 173
         # Note that default value of allowed_chars does not have "I" or letters
174 174
         # that look like it -- just to avoid confusion.
175  
-        from whrandom import choice
  175
+        from random import choice
176 176
         return ''.join([choice(allowed_chars) for i in range(length)])
177 177
 
178 178
 class Session(meta.Model):

0 notes on commit 8d144da

Please sign in to comment.
Something went wrong with that request. Please try again.