Re: Getting error on first step of tutorial

2013-04-30 Thread millerdl
No, I never figured it out.  I deleted version 1.5 and specified version 
1.4 for the installation.  The same tutorial steps worked ok under version 
1.4 so I gave up on 1.5 and just used 1.4.  Prior to that I had set up a 
virtualenv with a 1.5 installation and that failed the same way, so I 
assume that it wasn't due to any other packages I had installed in my 
system python.  Also, version 1.5 worked ok on my Linux box so maybe it is 
something specific to a Windows installation.

Sorry,
Dennis

On Thursday, April 25, 2013 6:55:33 PM UTC-6, A. Dias wrote:
>
> Hey Dennis! 
>
> Have you figured out an answer for that one yet? cause i'm dealing with 
> the exact same error and it would be great if you had a solution for it!
>
> Cheers,
> Alex
>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: question about django tutorial

2013-04-30 Thread Mark Lybrand
Try:

python manage.py syncdb

If you have set up the rest of your project with the admin stuff, then this
should create the tables for you.

Then run

python manage.py runserver again.

Mark :)


On Tue, Apr 30, 2013 at 1:45 PM, Christopher Spears
wrote:

> Hi!
>
> I am a Django newbie, so please bear with me.  I am working on part 2 of
> the Django tutorial.
>
> I started my server with the following:
>
> python manage.py runserver
>
>
> Then I logged into my admin site.
>
> Earlier in the tutorial, I had created a model called Polls.  I selected
> Polls from the Site administration menu and then selected the 'What's up?'
> version of Polls to change.  However, when I clicked on the 'Save and
> Continue Editing' Button, I got this traceback:
>
> Environment:
>
>
> Request Method: POST
> Request URL: http://127.0.0.1:8000/admin/polls/poll/1/
>
> Django Version: 1.5.1
> Python Version: 2.7.4
> Installed Applications:
> ('django.contrib.auth',
>  'django.contrib.contenttypes',
>  'django.contrib.sessions',
>  'django.contrib.sites',
>  'django.contrib.messages',
>  'django.contrib.staticfiles',
>  'django.contrib.admin',
>  'polls')
> Installed Middleware:
> ('django.middleware.common.CommonMiddleware',
>  'django.contrib.sessions.middleware.SessionMiddleware',
>  'django.middleware.csrf.CsrfViewMiddleware',
>  'django.contrib.auth.middleware.AuthenticationMiddleware',
>  'django.contrib.messages.middleware.MessageMiddleware')
>
>
> Traceback:
> File "C:\Python27\lib\site-packages\django\core\handlers\base.py" in
> get_response
>   115. response = callback(request,
> *callback_args, **callback_kwargs)
> File "C:\Python27\lib\site-packages\django\contrib\admin\options.py" in
> wrapper
>   372. return self.admin_site.admin_view(view)(*args,
> **kwargs)
> File "C:\Python27\lib\site-packages\django\utils\decorators.py" in
> _wrapped_view
>   91. response = view_func(request, *args, **kwargs)
> File "C:\Python27\lib\site-packages\django\views\decorators\cache.py" in
> _wrapped_view_func
>   89. response = view_func(request, *args, **kwargs)
> File "C:\Python27\lib\site-packages\django\contrib\admin\sites.py" in inner
>   202. return view(request, *args, **kwargs)
> File "C:\Python27\lib\site-packages\django\utils\decorators.py" in _wrapper
>   25. return bound_func(*args, **kwargs)
> File "C:\Python27\lib\site-packages\django\utils\decorators.py" in
> _wrapped_view
>   91. response = view_func(request, *args, **kwargs)
> File "C:\Python27\lib\site-packages\django\utils\decorators.py" in
> bound_func
>   21. return func(self, *args2, **kwargs2)
> File "C:\Python27\lib\site-packages\django\db\transaction.py" in inner
>   223. return func(*args, **kwargs)
> File "C:\Python27\lib\site-packages\django\contrib\admin\options.py" in
> change_view
>   1108. self.log_change(request, new_object,
> change_message)
> File "C:\Python27\lib\site-packages\django\contrib\admin\options.py" in
> log_change
>   546. change_message  = message
> File "C:\Python27\lib\site-packages\django\contrib\admin\models.py" in
> log_action
>   19. e.save()
> File "C:\Python27\lib\site-packages\django\db\models\base.py" in save
>   546.force_update=force_update,
> update_fields=update_fields)
> File "C:\Python27\lib\site-packages\django\db\models\base.py" in save_base
>   650. result = manager._insert([self], fields=fields,
> return_id=update_pk, using=using, raw=raw)
> File "C:\Python27\lib\site-packages\django\db\models\manager.py" in _insert
>   215. return insert_query(self.model, objs, fields, **kwargs)
> File "C:\Python27\lib\site-packages\django\db\models\query.py" in
> insert_query
>   1661. return query.get_compiler(using=using).execute_sql(return_id)
> File "C:\Python27\lib\site-packages\django\db\models\sql\compiler.py" in
> execute_sql
>   937. cursor.execute(sql, params)
> File "C:\Python27\lib\site-packages\django\db\backends\util.py" in execute
>   41. return self.cursor.execute(sql, params)
> File "C:\Python27\lib\site-packages\django\db\backends\sqlite3\base.py" in
> execute
>   366. six.reraise(utils.DatabaseError,
> utils.DatabaseError(*tuple(e.args)), sys.exc_info()[2])
> File "C:\Python27\lib\site-packages\django\db\backends\sqlite3\base.py" in
> execute
>   362. return Database.Cursor.execute(self, query, params)
>
> Exception Type: DatabaseError at /admin/polls/poll/1/
> Exception Value: no such table: django_admin_log
>
> Was I supposed to set up this table earlier in the tutorial?  When I went
> back in the tutorial, I didn't see any mention of it.  I am working on a
> Windows laptop.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To unsubscribe from this group 

question about django tutorial

2013-04-30 Thread Christopher Spears
Hi!

I am a Django newbie, so please bear with me.  I am working on part 2 of 
the Django tutorial.

I started my server with the following:

python manage.py runserver


Then I logged into my admin site.

Earlier in the tutorial, I had created a model called Polls.  I selected 
Polls from the Site administration menu and then selected the 'What's up?' 
version of Polls to change.  However, when I clicked on the 'Save and 
Continue Editing' Button, I got this traceback:

Environment:


Request Method: POST
Request URL: http://127.0.0.1:8000/admin/polls/poll/1/

Django Version: 1.5.1
Python Version: 2.7.4
Installed Applications:
('django.contrib.auth',
 'django.contrib.contenttypes',
 'django.contrib.sessions',
 'django.contrib.sites',
 'django.contrib.messages',
 'django.contrib.staticfiles',
 'django.contrib.admin',
 'polls')
Installed Middleware:
('django.middleware.common.CommonMiddleware',
 'django.contrib.sessions.middleware.SessionMiddleware',
 'django.middleware.csrf.CsrfViewMiddleware',
 'django.contrib.auth.middleware.AuthenticationMiddleware',
 'django.contrib.messages.middleware.MessageMiddleware')


Traceback:
File "C:\Python27\lib\site-packages\django\core\handlers\base.py" in 
get_response
  115. response = callback(request, *callback_args, 
**callback_kwargs)
File "C:\Python27\lib\site-packages\django\contrib\admin\options.py" in 
wrapper
  372. return self.admin_site.admin_view(view)(*args, 
**kwargs)
File "C:\Python27\lib\site-packages\django\utils\decorators.py" in 
_wrapped_view
  91. response = view_func(request, *args, **kwargs)
File "C:\Python27\lib\site-packages\django\views\decorators\cache.py" in 
_wrapped_view_func
  89. response = view_func(request, *args, **kwargs)
File "C:\Python27\lib\site-packages\django\contrib\admin\sites.py" in inner
  202. return view(request, *args, **kwargs)
File "C:\Python27\lib\site-packages\django\utils\decorators.py" in _wrapper
  25. return bound_func(*args, **kwargs)
File "C:\Python27\lib\site-packages\django\utils\decorators.py" in 
_wrapped_view
  91. response = view_func(request, *args, **kwargs)
File "C:\Python27\lib\site-packages\django\utils\decorators.py" in 
bound_func
  21. return func(self, *args2, **kwargs2)
File "C:\Python27\lib\site-packages\django\db\transaction.py" in inner
  223. return func(*args, **kwargs)
File "C:\Python27\lib\site-packages\django\contrib\admin\options.py" in 
change_view
  1108. self.log_change(request, new_object, change_message)
File "C:\Python27\lib\site-packages\django\contrib\admin\options.py" in 
log_change
  546. change_message  = message
File "C:\Python27\lib\site-packages\django\contrib\admin\models.py" in 
log_action
  19. e.save()
File "C:\Python27\lib\site-packages\django\db\models\base.py" in save
  546.force_update=force_update, 
update_fields=update_fields)
File "C:\Python27\lib\site-packages\django\db\models\base.py" in save_base
  650. result = manager._insert([self], fields=fields, 
return_id=update_pk, using=using, raw=raw)
File "C:\Python27\lib\site-packages\django\db\models\manager.py" in _insert
  215. return insert_query(self.model, objs, fields, **kwargs)
File "C:\Python27\lib\site-packages\django\db\models\query.py" in 
insert_query
  1661. return query.get_compiler(using=using).execute_sql(return_id)
File "C:\Python27\lib\site-packages\django\db\models\sql\compiler.py" in 
execute_sql
  937. cursor.execute(sql, params)
File "C:\Python27\lib\site-packages\django\db\backends\util.py" in execute
  41. return self.cursor.execute(sql, params)
File "C:\Python27\lib\site-packages\django\db\backends\sqlite3\base.py" in 
execute
  366. six.reraise(utils.DatabaseError, 
utils.DatabaseError(*tuple(e.args)), sys.exc_info()[2])
File "C:\Python27\lib\site-packages\django\db\backends\sqlite3\base.py" in 
execute
  362. return Database.Cursor.execute(self, query, params)

Exception Type: DatabaseError at /admin/polls/poll/1/
Exception Value: no such table: django_admin_log

Was I supposed to set up this table earlier in the tutorial?  When I went 
back in the tutorial, I didn't see any mention of it.  I am working on a 
Windows laptop.

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: noob "hello world" problem with URLconf

2013-04-30 Thread Karl
^ is only start with hello. it may be your issues in urls.py



Karl

Programmer at Olivet Institute of Technology
http://oit.olivetuniversity.edu/

在 2013年4月30日星期二UTC-4下午1时25分41秒,lev...@gmail.com写道:
>
> what´s up everyone. I just installed Django for the first time, leaving 
> php in the closet for a while. 
>
> My problem is concerning the url patterns. I´ve pasted the example "Hello 
> world" code directly from the django book to urls.py and views.py so I´ll 
> leave out all extra code since it has something to do with my configuration.
>
>
> http://www.djangobook.com/en/2.0/chapter03.html
>
> This works:
> url(r'hello/$', hello),
>
> This doesn´t:
> url(r'^hello/$', hello),
>
> Hopefully someone can help.
>
> N
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: Using Django and R in a production environment?

2013-04-30 Thread Derek
Thanks Nick; RStudio looks like a really good tool for development work.

The impression I get though, is that the server is designed for allowing 
interactive R sessions over the web; whereas for us Django is the primary 
requirement and calls to R should happen "behind the scenes".  

On Tuesday, 30 April 2013 15:43:01 UTC+2, Nick Santos wrote:
>
> Is Django a hard and fast requirement? If so, is it just about integrating 
> the routines? I think otherwise something like RStudio Server would work 
> for you. I've deployed it previously and it was a pretty nice setup. It's 
> based on Unix user accounts, so R processes run as if users were running 
> them on a desktop, except not. You may be able to share code in this 
> environment too, but I haven't played with it a ton.
>
> http://www.rstudio.com/ide/docs/server/getting_started
>
> -Nick
>
> On Tue, Apr 30, 2013 at 12:06 AM, Derek  >wrote:
>
>> " if you write your own R  analysis routines, why have them run in a web 
>> system"
>>
>> Two issues here:
>>
>> 1. We are writing R routines for someone else; who needs 'analysis on 
>> demand'
>> 2. A web system means that multiple users in multiple locations can all 
>> readily access the same analysis routines (but with different data sets)
>>
>> I agree that if you work on a desktop, with no need to access shared data 
>> or use the same analysis routines as anyone else, then a web interface 
>> makes no sense.
>>
>> Basically we are trying to harness two disparate systems; each of which 
>> is very powerful in their own sphere, to create an application that is 
>> really useful for better and more efficient science.
>>
>>
>> On 29 April 2013 16:59, Javier Guerra Giraldez 
>> > > wrote:
>>
>>> On Mon, Apr 29, 2013 at 2:13 AM, Derek  
>>> wrote:
>>> > hat no one is actually using R in a production environment themselves 
>>> (which
>>> > is a little surprising to me).
>>>
>>>
>>> well R itself is widely used in production... but the intersection
>>> with Django is very small.  (after all, if you write your own R
>>> analysis routines, why have them run in a web system)
>>>
>>> --
>>> Javier
>>>
>>
>>  -- 
>> You received this message because you are subscribed to the Google Groups 
>> "Django users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to django-users...@googlegroups.com .
>> To post to this group, send email to django...@googlegroups.com
>> .
>> Visit this group at http://groups.google.com/group/django-users?hl=en.
>> For more options, visit https://groups.google.com/groups/opt_out.
>>  
>>  
>>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: Need explanation of the flow of info between my javascript, my View, and my template, trying to diagnose my current roadblock.

2013-04-30 Thread Shawn Milochik
You're welcome. You may be new to it, but you ask better questions than
most I see. When I see "How do I do X?" I usually ignore it. When I see
"Here's what I did. It's not working for some reason" then I try to help if
I can. Keep up the good work.

Shawn

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: Need explanation of the flow of info between my javascript, my View, and my template, trying to diagnose my current roadblock.

2013-04-30 Thread Javier Guerra Giraldez
On Tue, Apr 30, 2013 at 2:22 PM,  <7equivale...@gmail.com> wrote:
> "Redirect" Is that what you kids are calling it nowdays..


i found that word in RFC 1945, by Tim Berners-Lee and others, May
1996, where HTTP/1.0 was defined.

hardly a new term in web lingo.

--
Javier

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: Need explanation of the flow of info between my javascript, my View, and my template, trying to diagnose my current roadblock.

2013-04-30 Thread 7equivalents
"Redirect" Is that what you kids are calling it nowdays.. Thanks, that was 
the terminology I was lacking. That works I'm learning html, 
javascript, and Django all together on the fly so I'm not well versed in 
basics. Thankyou for your help! It helped clear up the puzzle a bit.


-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Admin shows all users as staff and super user

2013-04-30 Thread Thomas De Reyck
Hi everyone,

My very first question here. I hope anyone can help me out with this...

I have created a Django powered site for my company. Everything works 
perfectly, except in our production environment,
where I have one bug in the admin that is quite annoying:

When I click a user to edit it, the "Staff" and "SuperUser" checkboxes are 
always checked for every user, even when they
shouldn't be. The database however does record these properties properly, 
and they work correctly in the application. Only
the admin is displaying them incorrectly in the "edit" page for a user. 
When looking at the user overview in the admin, the
"staff" property is correctly displayed.

Because of this error we need to be extra cautious when editing users, 
because we don't accidentally want to make anyone
a staff or superuser.

Does anyone know how I can attempt to debug this? Where should I start?

I am running:
Django 1.5.1 on Ubuntu 12.04 with SQL Server 2008R2 as my database (via 
pyodbc->UnixODBC->FreeTDS).

Thanks in advance for any hints you can provide!

Kind regards,
Thomas

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: noob "hello world" problem with URLconf

2013-04-30 Thread Andrew Boltachev
Hi. Can you please post your full urls.py?


2013/4/30 

> what´s up everyone. I just installed Django for the first time, leaving
> php in the closet for a while.
>
> My problem is concerning the url patterns. I´ve pasted the example "Hello
> world" code directly from the django book to urls.py and views.py so I´ll
> leave out all extra code since it has something to do with my configuration.
>
>
> http://www.djangobook.com/en/2.0/chapter03.html
>
> This works:
> url(r'hello/$', hello),
>
> This doesn´t:
> url(r'^hello/$', hello),
>
> Hopefully someone can help.
>
> N
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-users+unsubscr...@googlegroups.com.
> To post to this group, send email to django-users@googlegroups.com.
> Visit this group at http://groups.google.com/group/django-users?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Multi-tenant database model with new user model?

2013-04-30 Thread Subodh Nijsure
Hi,

We have old model for one of my django application that requires
multi-tenant deployment. The database model I came up with is kind of
_ugly_ to support the multi-tenancy.

Are there any good examples of how one can write multi-tenant django
application using the new AbstractUser classes?

-Subodh

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




noob "hello world" problem with URLconf

2013-04-30 Thread levito
what´s up everyone. I just installed Django for the first time, leaving php 
in the closet for a while. 

My problem is concerning the url patterns. I´ve pasted the example "Hello 
world" code directly from the django book to urls.py and views.py so I´ll 
leave out all extra code since it has something to do with my configuration.


http://www.djangobook.com/en/2.0/chapter03.html

This works:
url(r'hello/$', hello),

This doesn´t:
url(r'^hello/$', hello),

Hopefully someone can help.

N

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: Need explanation of the flow of info between my javascript, my View, and my template, trying to diagnose my current roadblock.

2013-04-30 Thread Shawn Milochik
If I understand your question and your code properly, the problem is that
you are expecting a redirect, but what's happening is that the raw HTML
from the view is being returned to your JavaScript function, which does
nothing with it.

It seems like what you should do is just do a normal HTML form with an
"action" tag that just redirects to your view. Since you're not accepting
any return values in your JavaScript, you're not doing any "AJAX," so the
JavaScript is an unnecessary complication. If you cut out the JavaScript
entirely and make your button a normal "submit" button it will have the
desired behavior.

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Need explanation of the flow of info between my javascript, my View, and my template, trying to diagnose my current roadblock.

2013-04-30 Thread 7equivalents
Hey guys, I need a little help. Here is what I'm trying to do.
I would like to have a html button execute a javascript on click, and the 
javascript should send an GET reguest to the server which should execute 
the View for the page requested. For some reason I can't get it to work...

here is what I've done
(1) I have a working View that executes successfully when the main page is 
requested.
(2) The View loads the template that has the html button and javascript.
(3) I have confirmed the when the button is clicked the javascript executes.

However the page doesn't change to the new page requested, and I get a 404 
error however, the page is there and I link to it from other places in 
the code.

Maybe I misunderstand something in the way the request and load and ajax 
stuff works, I'm still a novice.

Here is my code...

 html & javascript 

 
$(function (){
  $("#blog1").click(function (){
var id =  $( "#blog1" ).val();
var data = { id:id };
$("#blog1").prop('value', 'works');
$.get({ 
  url:"/control/"
});
  });
  return false;
});

//

/// View 
/
def control_page(request):

  sliderB = Slider.objects.get(sliderID=1)
  sliderR = Slider.objects.get(sliderID=2)
  sliderG = Slider.objects.get(sliderID=3)
  sliderP = Slider.objects.get(sliderID=4)
  preprogram1 = Preprogram.objects.get(preprogramID=1)
  preprogram2 = Preprogram.objects.get(preprogramID=2)
  preprogram3 = Preprogram.objects.get(preprogramID=3)
  pin1 = Pin.objects.get(pinID=1)
  variables = RequestContext(request, {'pin1': pin1, 'preprogram1': 
preprogram1, 'preprogram2': preprogram2, 'preprogram3': preprogram3, 
'sliderB':sliderB, 'sliderR':sliderR, 'sliderG':sliderG, 'sliderP':sliderP})
  return render_to_response('control_page.html', variables) 
/

/// urls 
///
urlpatterns = patterns('',
  (r'^$', main_page),
  (r'^media/(?P.*)$', 'django.views.static.serve', {'document_root': 
settings.MEDIA_ROOT}),
  (r'^login/$', 'django.contrib.auth.views.login'),
  (r'^logout/$', logout_page),
  (r'^user/(\w+)/$', user_page),
  (r'^control/$', control_page),
  (r'^gpio_control/$', gpio_control_page),
  (r'^slider/$', slider_page),
  (r'^read_more/$', read_more_page),
  (r'^admin/', include(admin.site.urls)),

)///

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: Blog writen by django?

2013-04-30 Thread Alex Chiaranda
don't forget the django-cms project

https://www.django-cms.org/https://www.django-cms.org/

On Monday, April 29, 2013 5:05:00 PM UTC-3, gilberto dos santos alves wrote:
>
> mezzanine is spetacular. thanks! ;>). and plug and run.
>
> Em segunda-feira, 29 de abril de 2013 00h50min42s UTC-3, Russell 
> Keith-Magee escreveu:
>>
>>
>> Here's a site that lists a whole lot of options:
>>
>> https://www.djangopackages.com/grids/g/blogs/
>>
>> DjangoPackages is well worth bookmarking -- it's a good archive of Django 
>> packages for a wide range of website features, not just blogs.
>>
>> Yours,
>> Russ Magee %-)
>>
>> On Mon, Apr 29, 2013 at 11:22 AM, gilberto dos santos alves <
>> gsa...@gmail.com> wrote:
>>
>>> please could you point some one because this url [1], and this url [2] 
>>> have conceptual problems and not only mistype error.
>>> while this i am update docs for url [1], but it shows very poor html 
>>> display and models.
>>>
>>> url:: [1] 
>>> http://www.djangorocks.com/tutorials/how-to-create-a-basic-blog-in-django/
>>> url:: [2] http://lightbird.net/dbe/blog.html
>>>
>>> For all of us following tutorials on django home this sounds like people 
>>> have others important things to do. but we need tutorials for all people 
>>> that have method of learning things follow tutorials not guess tutorial!
>>>
>>> thanks for your time.
>>>
>>> Em sábado, 27 de abril de 2013 22h54min56s UTC-3, Shawn Milochik 
>>> escreveu:
>>>
 Do a Google search. There are thousands. 

>>>  -- 
>>> You received this message because you are subscribed to the Google 
>>> Groups "Django users" group.
>>> To unsubscribe from this group and stop receiving emails from it, send 
>>> an email to django-users...@googlegroups.com.
>>> To post to this group, send email to django...@googlegroups.com.
>>> Visit this group at http://groups.google.com/group/django-users?hl=en.
>>> For more options, visit https://groups.google.com/groups/opt_out.
>>>  
>>>  
>>>
>>
>>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Problem enconding

2013-04-30 Thread Hélio Miranda
I have a problem in my application that I am not able to solve, which is as 
follows:
In my application I have the option of entering the bd data from a csv 
file, is part is ok, the problem is that the data come in csv utf-8 and I 
compare with data that will seek to mongodb that come in latin iso or do 
not know well.

I'll fetch the genres of movies and save it for later if there is already 
comparing the genre of the movie or not and then insert.
But when you'll get the mongo station like this: Com \ \ xe9dia
And those who come in csv station like this: Com \ \ xc3 \ \ xa9dia
This for the Comedy genre.

How can I solve this problem?
My code is here:
Código (Python):
def csv_upload(request):
if request.method == 'POST':
gen = Genre.objects.all()
genres = dict(Genre.objects.all().values_list('GenreType', 
'id'))
print genres
for obj in gen:
genres[obj.GenreType] = obj.id
  
file = request.FILES['file']  
dialect = csv_mod.Sniffer().sniff(codecs.EncodedFile(file,
"utf-8").read(1024))
file.open()
csv = csv_mod.DictReader( codecs.EncodedFile(file,"utf-8"),
 dialect=dialect )
for line in csv:  
report = Movie()
  
genall = line["IdGenre"].split(',')
print genall
movieGenres = []
  
for cc in genall:
if not cc in genres:
rep = Genre()
rep.GenreType = cc
rep.save()
  
genres[rep.GenreType] = rep.id;
movieGenres.append(genres[cc])
  
report.MovieTitle = line["MovieTitle"]
report.IdGenre = movieGenres
report.MovieYear = line["MovieYear"]
report.MovieDuration = line["MovieDuration"]
report.save()
return render_to_response('index.html', {},
  context_instance=
RequestContext(request))

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Need to hire a Senior Django Web Architect

2013-04-30 Thread Andy
All,

We have a great client in downtown DC.  They need a Django architect to 
help them.

Our client is a well known brand name company in the consumer media 
industry.  The ideal candidate will have experience working with consumer 
facing websites, would not be afraid of Web Services, and has experience 
with CMS’s. The ideal candidate should be comfortable working within a 
team, as well as working independently to develop a solution.

This would be a full time employee position working directly for our 
client.  The salary level is $120,000 - $140,000/yr.
Please let me know if you're interested, and we can chat.  

Sincerely,
Andy Nussbaum


Our client is looking for qualified candidates for a Web Architect 
position. The successful candidate will be a charismatic leader and 
passionate web architect with a proven track record building highly 
scalable Internet-based products. You will be responsible for driving the 
rapid evolution of our clients' software architecture for Search, Video, 
Content Management and Registration.  The position is part of a proven team 
of architects  that is looking to increase its depth.  Please consider 
applying even if you are not knowledgeable in all areas mentioned below.

 

*Responsibilities:*

 

   - Define architecture for web enabled systems including CMS, Search, 
   Streaming Video, Identity Management and Community.

 

   - Integrate internal and external systems.  Provide leadership on cloud 
   based strategy.  

 

   - Define Service Oriented Architecture (SOA) and RESTful APIs to expose 
   content, authentication, community, and messaging services for internal and 
   3rd party developers.

 

   - Working with the development team,  the hire will develop and maintain 
   a roadmap of architectural improvements and API rollouts.

 

   - Evaluate and work closely with 3rd party development companies.

 

*Experience:*

 

Undergraduate degree in Computer Science, Information Technology, Software 
Engineering or similar field desired.

- 8 years work experience in progressively responsible technical role.

- Extensive experience with service oriented architectures.

- Experience supporting a media business is a plus

 

*Knowledge and Skill Requirements:*

 

8+ years total relevant experience

  Defining systems architecture with emphasis on integrating existing 
systems and web-based services

  Building products that get deployed and scale

  Recognized as an expert practitioner

  3+ years of hands-on experience as an system architect

Experience with:

   - Building software development environments that work
   - Python and Django experience 
   - API Definition and deployment
   - Experience with Registration , SAML, oAuth and Active Directory.
   - Experience with CMS systems
   - Search, including Elastic Search 
   - Streaming video experience a plus
   - Partner integration through open and proprietary Internet interfaces
   - Content and data migration
   - Ability to instill a culture of friendly competitiveness that drives 
   high quality and few software defects
   - Excellent communication and writing skills
   - Understandable by non-technology staff
   - Presentable to partners and clients

 

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: Using Django and R in a production environment?

2013-04-30 Thread Nick Santos
Is Django a hard and fast requirement? If so, is it just about integrating
the routines? I think otherwise something like RStudio Server would work
for you. I've deployed it previously and it was a pretty nice setup. It's
based on Unix user accounts, so R processes run as if users were running
them on a desktop, except not. You may be able to share code in this
environment too, but I haven't played with it a ton.

http://www.rstudio.com/ide/docs/server/getting_started

-Nick

On Tue, Apr 30, 2013 at 12:06 AM, Derek  wrote:

> " if you write your own R  analysis routines, why have them run in a web
> system"
>
> Two issues here:
>
> 1. We are writing R routines for someone else; who needs 'analysis on
> demand'
> 2. A web system means that multiple users in multiple locations can all
> readily access the same analysis routines (but with different data sets)
>
> I agree that if you work on a desktop, with no need to access shared data
> or use the same analysis routines as anyone else, then a web interface
> makes no sense.
>
> Basically we are trying to harness two disparate systems; each of which is
> very powerful in their own sphere, to create an application that is really
> useful for better and more efficient science.
>
>
> On 29 April 2013 16:59, Javier Guerra Giraldez  wrote:
>
>> On Mon, Apr 29, 2013 at 2:13 AM, Derek  wrote:
>> > hat no one is actually using R in a production environment themselves
>> (which
>> > is a little surprising to me).
>>
>>
>> well R itself is widely used in production... but the intersection
>> with Django is very small.  (after all, if you write your own R
>> analysis routines, why have them run in a web system)
>>
>> --
>> Javier
>>
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-users+unsubscr...@googlegroups.com.
> To post to this group, send email to django-users@googlegroups.com.
> Visit this group at http://groups.google.com/group/django-users?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: Using Django and R in a production environment?

2013-04-30 Thread Derek
" if you write your own R  analysis routines, why have them run in a web
system"

Two issues here:

1. We are writing R routines for someone else; who needs 'analysis on
demand'
2. A web system means that multiple users in multiple locations can all
readily access the same analysis routines (but with different data sets)

I agree that if you work on a desktop, with no need to access shared data
or use the same analysis routines as anyone else, then a web interface
makes no sense.

Basically we are trying to harness two disparate systems; each of which is
very powerful in their own sphere, to create an application that is really
useful for better and more efficient science.

On 29 April 2013 16:59, Javier Guerra Giraldez  wrote:

> On Mon, Apr 29, 2013 at 2:13 AM, Derek  wrote:
> > hat no one is actually using R in a production environment themselves
> (which
> > is a little surprising to me).
>
>
> well R itself is widely used in production... but the intersection
> with Django is very small.  (after all, if you write your own R
> analysis routines, why have them run in a web system)
>
> --
> Javier
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.