Re: Django Deployment.

2023-06-24 Thread Steve Liu
Hey

Maybe you can use Docker for it?



On Sat, Jun 24, 2023 at 6:44 PM Thomas Mutavi 
wrote:

> Hello team,
>
> Please recommend an article or a tutorial on Django deployment on windows
> server 2016 using either IIS or Apache. If you know the whole process you
> can also share.
>
> Thanks
>
> --
> 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 view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/8aa3132f-cb70-46fa-bd35-36339330ab88n%40googlegroups.com
> 
> .
>

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAO_rqR4Huaor0-snXySycb8O64Q_NXaoEQ0t3SKtxCi073picQ%40mail.gmail.com.


Re: migrations problem in django

2022-06-02 Thread Steve Smith
Looks like a spelling error at first glancemax_length...not max_lenght

That's my first guess...

From: django-users@googlegroups.com  on behalf 
of Paras Kashyap 
Sent: Wednesday, June 1, 2022 12:00 PM
To: Django users 
Subject: migrations problem in django

TypeError: Field.__init__() got an unexpected keyword argument 'max_lenght'
Please someone tell me how to fix this error, this error occurs when i try to 
make migrations

--
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/81c3da4c-5607-47e9-9fb1-458fa936afc1n%40googlegroups.com.

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CH0PR18MB4292EEADED29823A09D6B9A2D2DE9%40CH0PR18MB4292.namprd18.prod.outlook.com.


Re: GEODJANGO Problem/Question

2022-05-11 Thread Steve Watts
Update - I did manage to get the vast majority of the features to load - 
still missing 7,000/1,462,918 that showed errors during the LayerMapping 
process. I see a lot of "An error occurred in the current transaction. You 
can't execute queries until the end of the 'atomic' block." so I suspect 
there are fewer than 7,000 errors. I had "Step" set to 1,000. I imagine I 
can figure out how many errors there really are by setting "Step" to 1, 
This will get me started, but I am still very interested in further insight 
regarding my original question.

Thanks,

Steve Watts
On Wednesday, May 11, 2022 at 12:49:35 AM UTC-5 Steve Watts wrote:

> I am running a LayerMapping on a set of ShapeFiles acquired from a County 
> GIS Department. I've done a quite a bit of this, and this is the first time 
> I"ve seen such an issue. As LayerMapping is proceeding through the file 
> saving model instances, it encounters one that it can't handle:
>
> "GDAL_ERROR 1: b'Geometry of polygon of fid 5572 cannot be translated to 
> Simple Geometry. All polygons will be contained in a multipolygon.'"
> "GDAL_ERROR 1: b'organizePolygons() received an unexpected geometry. 
>  Either a polygon with interior rings, or a polygon with less than 4 
> points, or a non-Polygon geometry.  Return arguments as a collection.'"
> "GEOS_ERROR: IllegalArgumentException: Invalid number of points in 
> LinearRing found 3 - must be 0 or >= 4"
> "Failed to save the feature (id: 5572) into the model with the keyword 
> arguments:"
> And the final Exception:
> "GEOSException: Error encountered checking Geometry returned from GEOS C 
> function "GEOSWKTReader_read_r"."
>
> The best description of the issue I can find is 
> https://github.com/r-spatial/sf/issues/1589. In this help thread, and a 
> related one, they talk about a utility called "MakeValid" to resolve this 
> LinearRing issue.
>
> It appears I need to either add a point to any of these "LinearRing" 
> instances, or somehow otherwise fix these items.
>
> I'm not sure that sending the ShapeFiles back to the County to "fix" would 
> be productive.
>
> Does anyone have anything to contribute as far as how I might best move 
> forward with this set of ShapeFiles?
>
> Is there another forum where I should be addressing this issue? Need more 
> information?
>
> Thanks!
>
> Steve Watts
>

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/685ea3af-30dc-46d3-a7db-b25cb93f2b1cn%40googlegroups.com.


GEODJANGO Problem/Question

2022-05-10 Thread Steve Watts
I am running a LayerMapping on a set of ShapeFiles acquired from a County 
GIS Department. I've done a quite a bit of this, and this is the first time 
I"ve seen such an issue. As LayerMapping is proceeding through the file 
saving model instances, it encounters one that it can't handle:

"GDAL_ERROR 1: b'Geometry of polygon of fid 5572 cannot be translated to 
Simple Geometry. All polygons will be contained in a multipolygon.'"
"GDAL_ERROR 1: b'organizePolygons() received an unexpected geometry. 
 Either a polygon with interior rings, or a polygon with less than 4 
points, or a non-Polygon geometry.  Return arguments as a collection.'"
"GEOS_ERROR: IllegalArgumentException: Invalid number of points in 
LinearRing found 3 - must be 0 or >= 4"
"Failed to save the feature (id: 5572) into the model with the keyword 
arguments:"
And the final Exception:
"GEOSException: Error encountered checking Geometry returned from GEOS C 
function "GEOSWKTReader_read_r"."

The best description of the issue I can find is 
https://github.com/r-spatial/sf/issues/1589. In this help thread, and a 
related one, they talk about a utility called "MakeValid" to resolve this 
LinearRing issue.

It appears I need to either add a point to any of these "LinearRing" 
instances, or somehow otherwise fix these items.

I'm not sure that sending the ShapeFiles back to the County to "fix" would 
be productive.

Does anyone have anything to contribute as far as how I might best move 
forward with this set of ShapeFiles?

Is there another forum where I should be addressing this issue? Need more 
information?

Thanks!

Steve Watts

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/82fe8d9e-e83a-4e6c-bde1-1665ddd45670n%40googlegroups.com.


Re: How to create dynamic models in django??

2022-02-27 Thread Steve Smith
My two cents.  I've been trying to do a very similar thing...I've accomplished 
it in Djangousing FormsetsIt was painfulthe documentation on 
Formsets is scarce in my opinion and to get them to work is a lot of trial and 
error, not to mention complexity with corresponding Javascript.  At least for 
me it was.  I'm not using the rest framework as it relates to a table and rows 
but I am using them with a server based Django installationso I'm not sure 
how this applies to your use case.  I have recently started experimenting with 
HTMXto ultimately replace formsets and I'm pretty close to having it 
figured out.  Again with HTMX, there's not a lot of documentation so it's been 
a ton of trial and errorIf any of this resonates with you...let me know and 
I can provide some more specifics.

Steve


From: django-users@googlegroups.com  on behalf 
of Antonis Christofides 
Sent: Sunday, February 27, 2022 12:58 AM
To: django-users@googlegroups.com 
Subject: Re: How to create dynamic models in django??


Short answer: I don't know. It probably isn't straightforward, but it's doable 
in principle.

Longer answer: Django hasn't been designed with this case in mind. It's 
possible it's not the appropriate tool for the job (but again it might be, I 
don't know). In my experience you should avoid doing such things—it's likely to 
lead to an unmanageable code mess. Keep it simple. Consider working without a 
relational database.

Regards,

Antonis

Antonis Christofides
+30-6979924665 (mobile)

On 27/02/2022 05.40, Prashanth Patelc wrote:
How to create dynamic models in django rest framework?
Is there any chance to create dynamic models with APIs

Any examples please send me thanks in advance..

1) Requirement is need create table name and fields in frontend
2) we are  getting the data and store in to the db create db structure
3) get the table name and fields create table in backend  store to
4)this code don't update or add into the models
5)store the data into the tables
4)get the data into the tables using orm or any raw queries

--
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<mailto:django-users+unsubscr...@googlegroups.com>.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAMCU6Coop%3DVU67%2B1Ui%2BswvA2xijUYcre%2B%3D-Z_CzLnf-1pRRXUw%40mail.gmail.com<https://groups.google.com/d/msgid/django-users/CAMCU6Coop%3DVU67%2B1Ui%2BswvA2xijUYcre%2B%3D-Z_CzLnf-1pRRXUw%40mail.gmail.com?utm_medium=email_source=footer>.

--
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<mailto:django-users+unsubscr...@googlegroups.com>.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/86427c17-5103-2370-2bf4-c951c77b288e%40antonischristofides.com<https://groups.google.com/d/msgid/django-users/86427c17-5103-2370-2bf4-c951c77b288e%40antonischristofides.com?utm_medium=email_source=footer>.

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CH0PR18MB429283E111DA0882F61FD029D2009%40CH0PR18MB4292.namprd18.prod.outlook.com.


Re: Slow page load performance with a large number of formsets (over 25)

2022-02-25 Thread Steve Smith
Thanks for the suggestion.  I really appreciate it.

Steve

From: django-users@googlegroups.com  on behalf 
of Jacob Greene 
Sent: Friday, February 25, 2022 9:43 PM
To: django-users@googlegroups.com 
Subject: Re: Slow page load performance with a large number of formsets (over 
25)

You would need to cache the queryset and pass it to each form instance that the 
formset creates. I've done this a few different ways in the past. I've never 
understood why there isn't a more straight forward way to do this. Here's a 
post with a few legit options depending on your use case:

https://stackoverflow.com/questions/8176200/caching-queryset-choices-for-modelchoicefield-or-modelmultiplechoicefield-in-a-d

Hard to be more specific without knowing anything about your code.

On Fri, Feb 25, 2022, 8:53 PM Steve Smith 
mailto:stevesmith0...@hotmail.com>> wrote:

If in fact I am….how do I avoid this?  I have been playing with alternatives 
for a week and I’m starting to lose it…lol



Sent from Mail<https://go.microsoft.com/fwlink/?LinkId=550986> for Windows



From: Jacob Greene<mailto:jacobgreene1...@gmail.com>
Sent: Friday, February 25, 2022 5:58 PM
To: django-users@googlegroups.com<mailto:django-users@googlegroups.com>
Subject: Re: Slow page load performance with a large number of formsets (over 
25)



If you're using model choice fields, it's very likely you are making an SQL 
query for each form set. It should be pretty obvious in the log with debug 
turned on.



On Fri, Feb 25, 2022, 4:31 PM Ryan Nowakowski 
mailto:tuba...@fattuba.com>> wrote:

Steven, are you using ModelFormSet?  If so, Is it the initial query
that's slow?  The form rendering?  Or is it the POST back to the server
that's slow?  You can use django-debug-toolbar[1] to profile your page
and get these metrics.

Once you figure out what part is slowest, then you can optimize.

Hope this helps!

Ryan N

[1] https://django-debug-toolbar.readthedocs.io/en/latest/

On Mon, Feb 07, 2022 at 09:12:48AM -0800, Steven Smith wrote:
> Did this issue ever get resolved?  I'm experiencing the same thing.  Once
> it hits 100 forms or so it gets pretty slow.
>
> On Monday, September 22, 2014 at 10:48:52 AM UTC-5 Collin Anderson wrote:
>
> > Yes, if you want speed, using javascript and ajax is probably your best
> > bet. It will probably also reduce merge-conflicts.
> >

--
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<mailto:django-users%2bunsubscr...@googlegroups.com>.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/20220225222926.GH11627%40fattuba.com.

--
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<mailto:django-users+unsubscr...@googlegroups.com>.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAF-Y%3De5Fp7kDtLq47Z3Y4GEjXMne2PcTLYxOJ8St5gkKCkpUpw%40mail.gmail.com<https://groups.google.com/d/msgid/django-users/CAF-Y%3De5Fp7kDtLq47Z3Y4GEjXMne2PcTLYxOJ8St5gkKCkpUpw%40mail.gmail.com?utm_medium=email_source=footer>.



--
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<mailto:django-users+unsubscr...@googlegroups.com>.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CH0PR18MB42923C9432F56E071FA9716CD23F9%40CH0PR18MB4292.namprd18.prod.outlook.com<https://groups.google.com/d/msgid/django-users/CH0PR18MB42923C9432F56E071FA9716CD23F9%40CH0PR18MB4292.namprd18.prod.outlook.com?utm_medium=email_source=footer>.

--
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<mailto:django-users+unsubscr...@googlegroups.com>.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAF-Y%3De4E3zFuzmK_UOf9exaEc5pM5FNun7xJXhn_yVbHyWqiWg%40mail.gmail.com<https://groups.google.com/d/msgid/django-users/CAF-Y%3De4E3zFuzmK_UOf9exaEc5pM5FNun7xJXhn_yVbHyWqiWg%40mail.gmail.com?utm_medium=email_source=footer>.

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CH0PR18MB429297C1C7D04F4094D10D8CD23F9%40CH0PR18MB4292.namprd18.prod.outlook.com.


RE: Slow page load performance with a large number of formsets (over 25)

2022-02-25 Thread Steve Smith
If in fact I am….how do I avoid this?  I have been playing with alternatives 
for a week and I’m starting to lose it…lol

Sent from Mail for Windows

From: Jacob Greene
Sent: Friday, February 25, 2022 5:58 PM
To: django-users@googlegroups.com
Subject: Re: Slow page load performance with a large number of formsets (over 
25)

If you're using model choice fields, it's very likely you are making an SQL 
query for each form set. It should be pretty obvious in the log with debug 
turned on.

On Fri, Feb 25, 2022, 4:31 PM Ryan Nowakowski 
mailto:tuba...@fattuba.com>> wrote:
Steven, are you using ModelFormSet?  If so, Is it the initial query
that's slow?  The form rendering?  Or is it the POST back to the server
that's slow?  You can use django-debug-toolbar[1] to profile your page
and get these metrics.

Once you figure out what part is slowest, then you can optimize.

Hope this helps!

Ryan N

[1] https://django-debug-toolbar.readthedocs.io/en/latest/

On Mon, Feb 07, 2022 at 09:12:48AM -0800, Steven Smith wrote:
> Did this issue ever get resolved?  I'm experiencing the same thing.  Once
> it hits 100 forms or so it gets pretty slow.
>
> On Monday, September 22, 2014 at 10:48:52 AM UTC-5 Collin Anderson wrote:
>
> > Yes, if you want speed, using javascript and ajax is probably your best
> > bet. It will probably also reduce merge-conflicts.
> >

--
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/20220225222926.GH11627%40fattuba.com.
--
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAF-Y%3De5Fp7kDtLq47Z3Y4GEjXMne2PcTLYxOJ8St5gkKCkpUpw%40mail.gmail.com.

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CH0PR18MB42923C9432F56E071FA9716CD23F9%40CH0PR18MB4292.namprd18.prod.outlook.com.


Formsets?!?!?!?!?!?!?!?!?!?

2022-02-11 Thread Steve Smith
Hello all

I have formsets workingbut I seem to be encountering some performance 
issues if I have more than 25 rows.  I've looked at my database 
callsselect_related...prefetch_related...and I've polled several 
audiences...SOFacebook Groupsand the consensus seems to be that 
Formsets are bad if you have a lot of rows.  I'm having trouble accepting that 
because if that was the case why do they exist?  And why is the default like 
1000 forms?  I really like the formset conceptbut I'm having a hard time 
accepting that if you have more than 25 rows it's just gonna be "slow".  And by 
slow I mean when I try to render the form using formsets and I have 100 rows of 
data with like 12 fields each...it takes 19 seconds or so for the form to 
render.  Does this sound like normal behavior?  I'm legitimately asking as I 
honestly don't know.

Thanks in advance for any thoughts or feedback.

Steve

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CH0PR18MB4292692992A37BD51AAEB0AFD2319%40CH0PR18MB4292.namprd18.prod.outlook.com.


Re: Formsets

2022-02-06 Thread Steve Smith
HI Steve!

Thanks for the reply.  I have tried select related and prefetch relatedbut 
didn't know about deferwill look into...my current formset scenario is 
440ish queries and it takes about 19 seconds to load.  Some have suggested 
Celery and RabbitMQ and other alternatives which I'm not familiar with.  I need 
to explore those things further.  I have used the debug toolbar as wellit 
shows me that there are lots of duplicate queries...but I'm unclear on how to 
go about fixing them...as the select related and prefetch hasn't seemed to help 
either.

I'm using class based views with formsets and just kind of at a loss right now 
as to if there is anything that can be done to speed up these queries.  I 
opened up a SO on the issue...and got some suggestions on how to go about 
improving my dictionary look up...but after trying some of those suggestions 
the performance issue remains.

Thanks again for taking the time to respond.

Steve

From: django-users@googlegroups.com  on behalf 
of Steven Mapes 
Sent: Sunday, February 6, 2022 11:47 AM
To: Django users 
Subject: Re: Formsets

For me using select_related, prefetch_related and defer generally soft the 
issues. If that's still too slow then, if possible, you could look at using 
caching the queryset(s) you need the values. Have you run debug toolbar on the 
page to check what queries are running?

On Saturday, 5 February 2022 at 20:27:10 UTC stevesm...@hotmail.com wrote:
Hello all!

I find formsets wildly useful...but very difficult to architect.  I have them 
working...But I am running into a commonly documented problem...They are slow 
as you build up the number of fields and queries.  Are there any general tips 
that can be used or share on how to improve this issue?  I have tried all of 
the commonly prescribed 
solutions...select_related...prefetch_related...etc...But nothing seems to help.

I realize that Queries take timebut I'm just trying to see if there is a 
way to streamline them a bit.  It seems to me that formsets use a lot of 
queries depending on the amount of data and that's the trade off.

Again thanks for any thoughts or comments.

Steve


--
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<mailto:django-users+unsubscr...@googlegroups.com>.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/6513c105-8151-4c7a-8fd2-e692d5c5dcb5n%40googlegroups.com<https://groups.google.com/d/msgid/django-users/6513c105-8151-4c7a-8fd2-e692d5c5dcb5n%40googlegroups.com?utm_medium=email_source=footer>.

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CH0PR18MB42921F540CB239D4F5E250CCD22B9%40CH0PR18MB4292.namprd18.prod.outlook.com.


Re: Lack of tutorials and explanations about channels

2022-01-24 Thread Steve Smith
I am a huge fan of Django.  But I will agree that the documentation is most 
areas beyond the absolute basics is abysmal.  I have a lot written in Django in 
Class Based Views because I read early on they were the way to go.  I'm not 
going to tell you how much research and time it took me but it was a lot.  
Django is super powerful and it's amazingbut the documentation...while 
maybe better than any other framework is still very lacking for people in my 
humble opinion.  The documentation and books that I've come across are written 
in a way that they assume you already understand it and they pick up from 
there.  Love django.  Agree with the comment about documentation about Channels 
and as I've expressed most of the other documentation as well.




From: django-users@googlegroups.com  on behalf 
of lone...@gmail.com 
Sent: Monday, January 24, 2022 6:03 AM
To: Django users 
Subject: Re: Lack of tutorials and explanations about channels

You and me both are on the same page about documentation about Channels.  I 
tried to follow: Django Channels Tutorial : the most minimal Real Time app 
(not Chat) | Django WebSockets on 
YouTube, but I kept running into issues.  If you can follow this video, and 
figure it out, let me know if it is missing something.

On Wednesday, November 10, 2021 at 8:48:31 AM UTC-5 Dossou Mawussekuifan Gloria 
Donald KANTI wrote:
Why aren't there much tutorials and explanations about Channels and websocket 
integration in django over the internet ? Quite confusing. How can we get to 
know and understand it more if nobody wants to explain it. I am new to python 
and drf, wanna implement some realtime features in my app but no chance to get 
good resources explaining very well how things can be done. If there are some 
pros here knowing very well about the topic please, write some blog or make 
some detailed youtube videos to explain the topic. It will really help me and 
others in the future. It is crucial also for the image of django. Thank you

--
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/902feb53-0009-4e5b-946e-4f027daa64a6n%40googlegroups.com.

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CH0PR18MB4292FACCBAC6D6D04DD47D88D25E9%40CH0PR18MB4292.namprd18.prod.outlook.com.


Avoiding duplicate on_commit actions

2020-10-22 Thread Steve Jorgensen
Hi all,

If a record is updated more than once in a transaction causing something to 
need to happen on commit, but don't want to suffer the performance cost of 
unnecessarily doing that post-commit activity multiple times, is there any 
clean way to de-duplicate that?

If on_commit has an optional key argument to have it replace any entry with 
the same key rather than adding it again, that would solve this problem 
nicely. Of course, on_commit does not appear to have anything like that.

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/4b4e3544-3e50-4c10-bc68-2b31a73069b0n%40googlegroups.com.


Re: Rails to Django Application Architecture Question

2019-05-27 Thread Steve R
Would it be correct to think of an app being basically one object 
equivalent to a single medium-to-complex class?

On Friday, May 24, 2019 at 3:30:40 PM UTC-5, Steve R wrote:
>
> Thank you!
>
> On Friday, May 24, 2019 at 3:08:33 PM UTC-5, Alex Heyden wrote:
>>
>> What you're describing is how you'd lay out the models in an app. It 
>> sounds like you may have one Django app. If I were writing this in Django, 
>> I might try to spin the workflow and task logic off into its own 
>> application if I thought that the core ideas of users and projects might 
>> feed some other bit of logic elsewhere, but YAGNI may apply.
>>
>> On Fri, May 24, 2019 at 12:19 PM Steve R  wrote:
>>
>>> Hi All - 
>>>
>>> I am a new Django user, coming from RoR. I am having some difficulty 
>>> wrapping my head around the whole 'apps' thing. 
>>>
>>> Here is my specific use case, and I would appreciate feedback on if I am 
>>> thinking about this correctly, and if not, how to think about it.
>>>
>>> I have a project management application I built in RoR that I am 
>>> reimplementing in Django. 
>>>
>>> A User has one or more Projects, each Project has one or more Workflows, 
>>> and each Workflow has one or more Tasks. Tasks are assigned to users, who 
>>> may or may not be the Project owner.
>>>
>>> In Django, a User would be an app, but...
>>>
>>> Would a Project be an app, with all the functionality of Workflow and 
>>> Task below it? Separate apps 'feels' wrong, because a task is such a minor 
>>> element (for example), but if I squint, I could see why someone might want 
>>> a Task for something else.
>>>
>>> Or
>>>
>>> Would I have an app each for Projects, Workflows and Tasks, then set up 
>>> logic linking the apps together?
>>>
>>> I thing the question for me is, at what point are the reusable apps in 
>>> Django intended to be independent - I get the impression, the answer is 
>>> 'wherever possible', but does that apply even to very small apps, as Task 
>>> would be?
>>>
>>> Thanks in advance for your insight.
>>>
>>> SR
>>>
>>> -- 
>>> 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...@googlegroups.com.
>>> To post to this group, send email to django...@googlegroups.com.
>>> Visit this group at https://groups.google.com/group/django-users.
>>> To view this discussion on the web visit 
>>> https://groups.google.com/d/msgid/django-users/eed74b23-f8a7-44ee-8e9f-bc19a56e50c0%40googlegroups.com
>>>  
>>> <https://groups.google.com/d/msgid/django-users/eed74b23-f8a7-44ee-8e9f-bc19a56e50c0%40googlegroups.com?utm_medium=email_source=footer>
>>> .
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>>

-- 
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 https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/ccc2d082-2305-490b-8770-9a95508d2779%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Rails to Django Application Architecture Question

2019-05-24 Thread Steve R
Thank you!

On Friday, May 24, 2019 at 3:08:33 PM UTC-5, Alex Heyden wrote:
>
> What you're describing is how you'd lay out the models in an app. It 
> sounds like you may have one Django app. If I were writing this in Django, 
> I might try to spin the workflow and task logic off into its own 
> application if I thought that the core ideas of users and projects might 
> feed some other bit of logic elsewhere, but YAGNI may apply.
>
> On Fri, May 24, 2019 at 12:19 PM Steve R > 
> wrote:
>
>> Hi All - 
>>
>> I am a new Django user, coming from RoR. I am having some difficulty 
>> wrapping my head around the whole 'apps' thing. 
>>
>> Here is my specific use case, and I would appreciate feedback on if I am 
>> thinking about this correctly, and if not, how to think about it.
>>
>> I have a project management application I built in RoR that I am 
>> reimplementing in Django. 
>>
>> A User has one or more Projects, each Project has one or more Workflows, 
>> and each Workflow has one or more Tasks. Tasks are assigned to users, who 
>> may or may not be the Project owner.
>>
>> In Django, a User would be an app, but...
>>
>> Would a Project be an app, with all the functionality of Workflow and 
>> Task below it? Separate apps 'feels' wrong, because a task is such a minor 
>> element (for example), but if I squint, I could see why someone might want 
>> a Task for something else.
>>
>> Or
>>
>> Would I have an app each for Projects, Workflows and Tasks, then set up 
>> logic linking the apps together?
>>
>> I thing the question for me is, at what point are the reusable apps in 
>> Django intended to be independent - I get the impression, the answer is 
>> 'wherever possible', but does that apply even to very small apps, as Task 
>> would be?
>>
>> Thanks in advance for your insight.
>>
>> SR
>>
>> -- 
>> 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...@googlegroups.com .
>> To post to this group, send email to django...@googlegroups.com 
>> .
>> Visit this group at https://groups.google.com/group/django-users.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/django-users/eed74b23-f8a7-44ee-8e9f-bc19a56e50c0%40googlegroups.com
>>  
>> <https://groups.google.com/d/msgid/django-users/eed74b23-f8a7-44ee-8e9f-bc19a56e50c0%40googlegroups.com?utm_medium=email_source=footer>
>> .
>> For more options, visit https://groups.google.com/d/optout.
>>
>

-- 
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 https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/c76c0f35-6c76-4a92-b554-4fa150c5d3b4%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Rails to Django Application Architecture Question

2019-05-24 Thread Steve R
Hi All - 

I am a new Django user, coming from RoR. I am having some difficulty 
wrapping my head around the whole 'apps' thing. 

Here is my specific use case, and I would appreciate feedback on if I am 
thinking about this correctly, and if not, how to think about it.

I have a project management application I built in RoR that I am 
reimplementing in Django. 

A User has one or more Projects, each Project has one or more Workflows, 
and each Workflow has one or more Tasks. Tasks are assigned to users, who 
may or may not be the Project owner.

In Django, a User would be an app, but...

Would a Project be an app, with all the functionality of Workflow and Task 
below it? Separate apps 'feels' wrong, because a task is such a minor 
element (for example), but if I squint, I could see why someone might want 
a Task for something else.

Or

Would I have an app each for Projects, Workflows and Tasks, then set up 
logic linking the apps together?

I thing the question for me is, at what point are the reusable apps in 
Django intended to be independent - I get the impression, the answer is 
'wherever possible', but does that apply even to very small apps, as Task 
would be?

Thanks in advance for your insight.

SR

-- 
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 https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/eed74b23-f8a7-44ee-8e9f-bc19a56e50c0%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Passing values from Python to Javascript

2018-05-23 Thread steve Valet
I am trying to pass values from Django/Python to Javascript, and have it 
working to a degree, but need some assistance (obligatory: I'm new to 
Django so could be hosing this)

I have three files in play here, *views.py, app.js, home.html*. I can get 
the values passed to home.html as part of the render, but I can't get the 
code to work outside of the home.html file. Below is a *very simplified* 
example of what I'm doing. 

*VIEWS.PY*

return render(request, "home.html", {'data':data'})


*HOME.HTML*



 

  

  

   myFunction({{ data | safe }});

  

 




*APP.JS*

function *myFunction*(vars){

return vars

};




I would like to have the JS in the HTML file in the APP.JS file so I can 
centralize all Javascript, but cannot get it to work outside the HTML. I also 
tried sending the "data" to JSON using "json.dumps" but got an error that the 
data was not serializable, so went with this code posted above.


Can I do what I'm trying to do?


Thanks

Steve

-- 
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 https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/c57509d3-fc80-4398-b04b-af1c390e9c85%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: DoesNotExist behavior in db.models query.py

2017-10-23 Thread steve
Thank you Aaron, I started to figure this all out too as I read the docs 
more carefully and looked at the source code more thoughtfully.

One nuance on the try/except block you propose: doesn't work as expected in 
the request framework because even though the except block can be stated as 
you propose, the exception gets thrown by db.models query.py and is 
declared as a simple
raise DoesNotExist...

And this then bubbles all the way back through the middleware.

The simplest answer for my use case is to just use filter().

As get() is defined as a method of the QuerySet class, at first glance I 
assumed it would return a queryset, but as you point out, it doesn't. It 
returns an instance of a model class.  In my perfect world, get() would 
have been named as get_as_model_object so that it was clear this is a 
convenience method of the class. But that's just quibbling. Had I read the 
source code more carefully, it would have dawned on me what to do and why I 
had been confused.

Thank you.
steve

On Monday, October 23, 2017 at 2:49:28 PM UTC-7, st...@fitcode.com wrote:
>
> I have been tripping over the following exception
> DoesNotExist: INSERT_YOUR_MODEL_NAME_HERE matching query does not exist.
>
> The error is source in django 1.11.2 in db.models query.py file, in the 
> get(self, *args, **kwargs) function, line 378 to be exact
> ...
> raise self.model.DoesNotExist(...)
> ...
> This throws a 500 error and I would like my code not to throw a 500 error 
> in this situation, rather a customized message more along a 4xx error e.g.
> {"message": "record matching identifier A and identifier B not found in 
> database"}
> rather than a 500 error.
>
> It seems to me that my only choice right now is to subclass QuerySet and 
> write my own version of the get(self, *args, **kwargs) method. Is that my 
> only choice or is there a django parameter I can set so that 0 matching 
> results does not return a 500?
>
> Or do I need to intercept the 500 error somewhere else.
>
> Sorry, am a bit of a newbie to django internals, all help and advice is 
> appreciated.
>
> Thanks,
> Steve
>

-- 
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 https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/775408b6-0ece-486a-9026-1c09ba34%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: DoesNotExist behavior in db.models query.py

2017-10-23 Thread steve
Replying to myself here: as is often the case, the problem lies with my own 
source code.
I was calling
MODELNAME.objects.get(modelfieldname1='foo',modelfieldname2='bar')


which raises the 500 when no such record exists.

Turns out that calling
MODELNAME.objects.filter(modelfieldname1='foo',modelfieldname2='bar')


behaves politely when finding no matching record and returns a 0 length 
QuerySet array. So with calling filter I can then just test on length of 
result and make my behavior omit a 400 and some helpful information to 
client side about the nature of the 400 error.

Separately, this does raise the question of should get() and filter() 
behave similarly or is there a reason that filter() allows empty result 
sets but get() does not?

Thanks,
Steve

On Monday, October 23, 2017 at 2:49:28 PM UTC-7, st...@fitcode.com wrote:
>
> I have been tripping over the following exception
> DoesNotExist: INSERT_YOUR_MODEL_NAME_HERE matching query does not exist.
>
> The error is source in django 1.11.2 in db.models query.py file, in the 
> get(self, *args, **kwargs) function, line 378 to be exact
> ...
> raise self.model.DoesNotExist(...)
> ...
> This throws a 500 error and I would like my code not to throw a 500 error 
> in this situation, rather a customized message more along a 4xx error e.g.
> {"message": "record matching identifier A and identifier B not found in 
> database"}
> rather than a 500 error.
>
> It seems to me that my only choice right now is to subclass QuerySet and 
> write my own version of the get(self, *args, **kwargs) method. Is that my 
> only choice or is there a django parameter I can set so that 0 matching 
> results does not return a 500?
>
> Or do I need to intercept the 500 error somewhere else.
>
> Sorry, am a bit of a newbie to django internals, all help and advice is 
> appreciated.
>
> Thanks,
> Steve
>

-- 
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 https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/67bd9382-0ac1-49c6-8b26-1827b91a852c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


DoesNotExist behavior in db.models query.py

2017-10-23 Thread steve
I have been tripping over the following exception
DoesNotExist: INSERT_YOUR_MODEL_NAME_HERE matching query does not exist.

The error is source in django 1.11.2 in db.models query.py file, in the 
get(self, *args, **kwargs) function, line 378 to be exact
...
raise self.model.DoesNotExist(...)
...
This throws a 500 error and I would like my code not to throw a 500 error 
in this situation, rather a customized message more along a 4xx error e.g.
{"message": "record matching identifier A and identifier B not found in 
database"}
rather than a 500 error.

It seems to me that my only choice right now is to subclass QuerySet and 
write my own version of the get(self, *args, **kwargs) method. Is that my 
only choice or is there a django parameter I can set so that 0 matching 
results does not return a 500?

Or do I need to intercept the 500 error somewhere else.

Sorry, am a bit of a newbie to django internals, all help and advice is 
appreciated.

Thanks,
Steve

-- 
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 https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/499aad32-3e2d-4717-97cb-f65feccc0d65%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Include pictures in content

2017-04-11 Thread Steve Watts
I also don't normally comment, but in your case, you might also try 
prefacing assets with media or static - i.e. 
http://yourwebsite.com/media/assets/... or 
http://yourwebsite.com/static/assets/... . That said, it's hard to know 
without seeing your settings.py file from your project. As it is, the 
question is more about how someone implemented the website, not about an 
implementation issue.

It may also be telling you to store the link somewhere else on the web for 
reference by your website.

Best of luck, though!

On Thursday, April 6, 2017 at 2:05:56 PM UTC-5, John Fabiani wrote:
>
> I normally don't jump into discussions - so I apologize in advance!
>
> Try reading this link:
>
> https://docs.djangoproject.com/en/1.10/howto/static-files/
>
> Johnf
>
> On 04/06/2017 11:50 AM, ard...@dunnsmail.co.uk  wrote:
>
> Thanks ludovic, 
> I haven't had any success yet, but your answer has led me deeper into the 
> django maze!
>
> On Thursday, April 6, 2017 at 11:59:29 AM UTC+1, ard...@dunnsmail.co.uk 
> wrote: 
>>
>> I am new to using django which has been used to create our church 
>> website. I want to incorporate pictures into content on a post. The 'insert 
>> image' icon on the content toolbar asks for an 'image web link'. The 
>> pictures I want to include (as pictures, not as links) are on the web site 
>> in the default home/assets/images folder. Can anyone tell me the format of 
>> the link to these images stored on the site? 
>> Thank You, Alan Dunn
>>
> -- 
> 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 https://groups.google.com/group/django-users.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/django-users/d9b1a93a-3646-48cd-8f64-b8462259a239%40googlegroups.com
>  
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>
>
>

-- 
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 https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/bb143bdc-d795-4673-9938-c1cc96f333e4%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Setting The Admin Login.

2017-02-13 Thread Steve R Burrus
We;ll Tim I like any other Django newb ie just wanna be able to go into the 
Django admin like I clearly remember doing with past versions of Django. Is 
there any more advice you can give me for this problem?   

On Monday, February 13, 2017 6:27 PM, Tim Graham <timogra...@gmail.com> 
wrote:
 

 I'm not sure what you're trying to do.

On Monday, February 13, 2017 at 5:29:49 PM UTC-5, Steve Burrus wrote:
I am sorry Tim but I checked oiut both "creat esuperuser" and "changepassword" 
commands but  it did no good! Can you please give me a more detailed solution? 
 

On Monday, February 13, 2017 3:42 PM, Tim Graham <timog...@gmail.com> wrote:
 

 I guess you're looking for the createsuperuser command: 
https://docs.djangoproject. com/en/stable/ref/django- admin/#createsuperuser

On Monday, February 13, 2017 at 4:28:45 PM UTC-5, Steve Burrus wrote:
 How do I go about setting the username/password for the CURRENT version of the 
Django Server anyway? It used to be easier to do in earlier versions of Django.

 

-- 
You received this message because you are subscribed to a topic in the Google 
Groups "Django users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/ 
topic/django-users/Evyu_ 1IPZ2o/unsubscribe.
To unsubscribe from this group and all its topics, send an email to 
django-users...@ googlegroups.com.
To post to this group, send email to django...@googlegroups.com.
Visit this group at https://groups.google.com/ group/django-users.
To view this discussion on the web visit https://groups.google.com/d/ 
msgid/django-users/b7d58c4f- 307c-4883-9ca6-f424c648223c% 40googlegroups.com.
For more options, visit https://groups.google.com/d/ optout.


   
-- 
You received this message because you are subscribed to a topic in the Google 
Groups "Django users" group.
To unsubscribe from this topic, visit 
https://groups.google.com/d/topic/django-users/Evyu_1IPZ2o/unsubscribe.
To unsubscribe from this group and all its topics, 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 https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/5307d9ec-f69e-4000-a0b3-e86825896932%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


   

-- 
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 https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/1109209035.4161424.1487035939958%40mail.yahoo.com.
For more options, visit https://groups.google.com/d/optout.


Re: Setting The Admin Login.

2017-02-13 Thread Steve R Burrus
I am sorry Tim but I checked oiut both "creat esuperuser" and "changepassword" 
commands but  it did no good! Can you please give me a more detailed solution? 
 

On Monday, February 13, 2017 3:42 PM, Tim Graham <timogra...@gmail.com> 
wrote:
 

 I guess you're looking for the createsuperuser command: 
https://docs.djangoproject.com/en/stable/ref/django-admin/#createsuperuser

On Monday, February 13, 2017 at 4:28:45 PM UTC-5, Steve Burrus wrote:
 How do I go about setting the username/password for the CURRENT version of the 
Django Server anyway? It used to be easier to do in earlier versions of Django.

 

-- 
You received this message because you are subscribed to a topic in the Google 
Groups "Django users" group.
To unsubscribe from this topic, visit 
https://groups.google.com/d/topic/django-users/Evyu_1IPZ2o/unsubscribe.
To unsubscribe from this group and all its topics, 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 https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/b7d58c4f-307c-4883-9ca6-f424c648223c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


   

-- 
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 https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/844799351.4041439.1487024939747%40mail.yahoo.com.
For more options, visit https://groups.google.com/d/optout.


Setting The Admin Login.

2017-02-13 Thread Steve Burrus
 How do I 

*go about setting the username/password for the CURRENT version of the 
Django Server anyway? It used to be easier to do in earlier versions of 
Django. *

-- 
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 https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/f8e7f518-3aad-40de-86e1-23f30633c0bb%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Django MySql weirdness

2016-07-26 Thread Steve Bischoff
https://github.com/django/django/tree/master/django/contrib/admin/migrations

The migrations are in here - the code that is failing 
in 0002_logentry_remove_auto_add.py

is 


operations = [
migrations.AlterField(
model_name='logentry',
name='action_time',
field=models.DateTimeField(
verbose_name='action time',
default=timezone.now,
editable=False,
),
),
]
On Monday, July 25, 2016 at 3:17:13 PM UTC-4, Constantine Covtushenko wrote:
>
> Hi Steve,
>
> Can you please provide code snippet here for 'action_time' field?
>
> Regards,
>
> On Mon, Jul 25, 2016 at 9:11 PM, Steve Bischoff <bisch...@gmail.com 
> > wrote:
>
>>
>>
>> http://stackoverflow.com/questions/38534734/django-42000-invalid-default-value-for-action-time
>>
>> I have been trying to figure this one out for a bit now, does anyone have 
>> any tips on why mysql won't take in this date time from django?
>>
>> Thanks
>>
>> -- 
>> 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 https://groups.google.com/group/django-users.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/django-users/e7900617-6c13-4bbc-b9ad-a542310d79a8%40googlegroups.com
>>  
>> <https://groups.google.com/d/msgid/django-users/e7900617-6c13-4bbc-b9ad-a542310d79a8%40googlegroups.com?utm_medium=email_source=footer>
>> .
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>

-- 
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 https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/9e10739c-56f7-48b8-bc17-7c8eca40376f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Django MySql weirdness

2016-07-25 Thread Steve Bischoff

http://stackoverflow.com/questions/38534734/django-42000-invalid-default-value-for-action-time

I have been trying to figure this one out for a bit now, does anyone have 
any tips on why mysql won't take in this date time from django?

Thanks

-- 
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 https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/e7900617-6c13-4bbc-b9ad-a542310d79a8%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Installing Django Problem.

2016-07-04 Thread Steve R Burrus
Wel;l everyone I guess that I have met with success as far as connecting to  
the Django server a nd configuring the admin BUT there remains A LOT of things 
about Django I don't know yet.    

On Monday, July 4, 2016 2:31 PM, ludovic coues <cou...@gmail.com> wrote:
 

 I could ask you what error you get when running syncdb. I could tell
you to use manage.py createsuperuser.
But the best advice anyone can give you is to do a tutorial about
django. The django girls one is really great. The one from the
official documentation is shorter. Either one will give you a solid
base for starting to use django.

2016-07-04 16:19 GMT+02:00 Steve Burrus <steveburru...@gmail.com>:
> Well I successfully set up the Django server an d then connected to oit BUT
> I couldn't use that "syncdb" command to then set the pw and username in the
> admin.
>
> On Sun, Jul 3, 2016 at 11:15 PM, Mike Dewhirst <mi...@dewhirst.com.au>
> wrote:
>>
>> On 4/07/2016 1:06 PM, Steve Burrus wrote:
>>>
>>> Well I did tjhis okay "(stevesenv)
>>> C:\Users\sbur87\Desktop\steves_dir\stevesenv>pip install django" but
>>> still the question persists where I go from here? I remember using
>>> "django-admin" before. How do I use that?
>>
>>
>> Here is a good place to start ...
>>
>> https://docs.djangoproject.com/en/1.9/
>>
>> That page covers how the documentation is organised. You need to work your
>> way through all the installation steps including database etc.
>>
>> Then the most important next step is to wrk through the tutorial. Once you
>> get that done there are quite a few third party tutorials on the web.
>>
>> Good luck
>>
>>
>> Mike
>>
>>
>>
>>
>>>
>>> On Sun, Jul 3, 2016 at 9:32 PM, Mike Dewhirst <mi...@dewhirst.com.au
>>> <mailto:mi...@dewhirst.com.au>> wrote:
>>>
>>>    On 4/07/2016 12:01 PM, Steve Burrus wrote:
>>>
>>>        well I uyet again am encountering problems with installing the
>>>        Django
>>>        server. I managed to get to this point "(stevesenv)
>>>        C:\Users\sbur87\Desktop\steves_dir\stevesenv>"
>>>
>>>
>>>    It looks as though you have successfully got virtualenv working.
>>>
>>>    Therefore the short answer to your question is ...
>>>
>>>    (stevesenv) C:\Users\sbur87\Desktop\steves_dir\stevesenv>pip install
>>>    django
>>>
>>>    Cheers
>>>
>>>    Mike
>>>
>>>
>>>    but where exactly do I go
>>>
>>>        from here in installing django? Man y thanx to anyone who can
>>>        help me
>>>        with this "trying" problem of mine.Â
>>>
>>>        --
>>>        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
>>>        <mailto:django-users%2bunsubscr...@googlegroups.com>
>>>        <mailto:django-users+unsubscr...@googlegroups.com
>>>        <mailto:django-users%2bunsubscr...@googlegroups.com>>.
>>>        To post to this group, send email to
>>>        django-users@googlegroups.com
>>> <mailto:django-users@googlegroups.com>
>>>        <mailto:django-users@googlegroups.com
>>>        <mailto:django-users@googlegroups.com>>.
>>>        Visit this group at https://groups.google.com/group/django-users.
>>>        To view this discussion on the web visit
>>>
>>> https://groups.google.com/d/msgid/django-users/e29b7fb8-ebda-4afc-890d-4048c4fe2e52%40googlegroups.com
>>>
>>> <https://groups.google.com/d/msgid/django-users/e29b7fb8-ebda-4afc-890d-4048c4fe2e52%40googlegroups.com?utm_medium=email_source=footer>.
>>>        For more options, visit https://groups.google.com/d/optout.
>>>
>>>
>>>    --
>>>    You received this message because you are subscribed to a topic in
>>>    the Google Groups "Django users" group.
>>>    To unsubscribe from this topic, visit
>>>
>>> https://groups.google.com/d/topic/django-users/9wVk4lDZcMY/unsubscribe.
>>>    To unsubscribe from this group and all its topics, send an email to
>>>    django-users+unsubscr...@googlegroups.com
>>>    <mailto:django

Re: Installing Django Problem.

2016-07-04 Thread Steve Burrus
Well I successfully set up the Django server an d then connected to oit BUT
I couldn't use that "syncdb" command to then set the pw and username in the
admin.

On Sun, Jul 3, 2016 at 11:15 PM, Mike Dewhirst <mi...@dewhirst.com.au>
wrote:

> On 4/07/2016 1:06 PM, Steve Burrus wrote:
>
>> Well I did tjhis okay "(stevesenv)
>> C:\Users\sbur87\Desktop\steves_dir\stevesenv>pip install django" but
>> still the question persists where I go from here? I remember using
>> "django-admin" before. How do I use that?
>>
>
> Here is a good place to start ...
>
> https://docs.djangoproject.com/en/1.9/
>
> That page covers how the documentation is organised. You need to work your
> way through all the installation steps including database etc.
>
> Then the most important next step is to wrk through the tutorial. Once you
> get that done there are quite a few third party tutorials on the web.
>
> Good luck
>
>
> Mike
>
>
>
>
>
>> On Sun, Jul 3, 2016 at 9:32 PM, Mike Dewhirst <mi...@dewhirst.com.au
>> <mailto:mi...@dewhirst.com.au>> wrote:
>>
>> On 4/07/2016 12:01 PM, Steve Burrus wrote:
>>
>> well I uyet again am encountering problems with installing the
>> Django
>> server. I managed to get to this point "(stevesenv)
>> C:\Users\sbur87\Desktop\steves_dir\stevesenv>"
>>
>>
>> It looks as though you have successfully got virtualenv working.
>>
>> Therefore the short answer to your question is ...
>>
>> (stevesenv) C:\Users\sbur87\Desktop\steves_dir\stevesenv>pip install
>> django
>>
>> Cheers
>>
>> Mike
>>
>>
>> but where exactly do I go
>>
>> from here in installing django? Man y thanx to anyone who can
>> help me
>> with this "trying" problem of mine.Â
>>
>> --
>> 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
>> <mailto:django-users%2bunsubscr...@googlegroups.com>
>> <mailto:django-users+unsubscr...@googlegroups.com
>> <mailto:django-users%2bunsubscr...@googlegroups.com>>.
>> To post to this group, send email to
>> django-users@googlegroups.com > django-users@googlegroups.com>
>> <mailto:django-users@googlegroups.com
>> <mailto:django-users@googlegroups.com>>.
>> Visit this group at https://groups.google.com/group/django-users.
>> To view this discussion on the web visit
>>
>> https://groups.google.com/d/msgid/django-users/e29b7fb8-ebda-4afc-890d-4048c4fe2e52%40googlegroups.com
>> <
>> https://groups.google.com/d/msgid/django-users/e29b7fb8-ebda-4afc-890d-4048c4fe2e52%40googlegroups.com?utm_medium=email_source=footer
>> >.
>> For more options, visit https://groups.google.com/d/optout.
>>
>>
>> --
>> You received this message because you are subscribed to a topic in
>> the Google Groups "Django users" group.
>> To unsubscribe from this topic, visit
>>
>> https://groups.google.com/d/topic/django-users/9wVk4lDZcMY/unsubscribe.
>> To unsubscribe from this group and all its topics, send an email to
>> django-users+unsubscr...@googlegroups.com
>> <mailto:django-users%2bunsubscr...@googlegroups.com>.
>> To post to this group, send email to django-users@googlegroups.com
>> <mailto:django-users@googlegroups.com>.
>> Visit this group at https://groups.google.com/group/django-users.
>> To view this discussion on the web visit
>>
>> https://groups.google.com/d/msgid/django-users/58cd5e27-6d4d-6929-aa44-b59c526a8c55%40dewhirst.com.au
>> .
>>
>> For more options, visit https://groups.google.com/d/optout.
>>
>>
>> --
>> 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
>> <mailto:django-users+unsubscr...@googlegroups.com>.
>> To post to this group, send email to django-users@googlegroups.com
>> <mailto:django-users@googlegroups.com>.
>> Visit this group at https://g

Re: Installing Django Problem.

2016-07-03 Thread Steve Burrus
Well I did tjhis okay "(stevesenv)
C:\Users\sbur87\Desktop\steves_dir\stevesenv>pip
install django" but still the question persists where I go from here? I
remember using "django-admin" before. How do I use that?

On Sun, Jul 3, 2016 at 9:32 PM, Mike Dewhirst <mi...@dewhirst.com.au> wrote:

> On 4/07/2016 12:01 PM, Steve Burrus wrote:
>
>> well I uyet again am encountering problems with installing the Django
>> server. I managed to get to this point "(stevesenv)
>> C:\Users\sbur87\Desktop\steves_dir\stevesenv>"
>>
>
> It looks as though you have successfully got virtualenv working.
>
> Therefore the short answer to your question is ...
>
> (stevesenv) C:\Users\sbur87\Desktop\steves_dir\stevesenv>pip install django
>
> Cheers
>
> Mike
>
>
> but where exactly do I go
>
>> from here in installing django? Man y thanx to anyone who can help me
>> with this "trying" problem of mine.Â
>>
>> --
>> 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
>> <mailto:django-users+unsubscr...@googlegroups.com>.
>> To post to this group, send email to django-users@googlegroups.com
>> <mailto:django-users@googlegroups.com>.
>> Visit this group at https://groups.google.com/group/django-users.
>> To view this discussion on the web visit
>>
>> https://groups.google.com/d/msgid/django-users/e29b7fb8-ebda-4afc-890d-4048c4fe2e52%40googlegroups.com
>> <
>> https://groups.google.com/d/msgid/django-users/e29b7fb8-ebda-4afc-890d-4048c4fe2e52%40googlegroups.com?utm_medium=email_source=footer
>> >.
>> For more options, visit https://groups.google.com/d/optout.
>>
>
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "Django users" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/django-users/9wVk4lDZcMY/unsubscribe.
> To unsubscribe from this group and all its topics, 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 https://groups.google.com/group/django-users.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/58cd5e27-6d4d-6929-aa44-b59c526a8c55%40dewhirst.com.au
> .
>
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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 https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CABcoaSDkTfc2QoxD_S3PqJCaTiigmp1msrvxDOq-pUK9Y9hD8Q%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Installing Django Problem.

2016-07-03 Thread Steve Burrus
well I uyet again am encountering problems with installing the Django 
server. I managed to get to this point "(stevesenv) 
C:\Users\sbur87\Desktop\steves_dir\stevesenv>" but where exactly do I go 
from here in installing django? Man y thanx to anyone who can help me with 
this "trying" problem of mine. 

-- 
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 https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/e29b7fb8-ebda-4afc-890d-4048c4fe2e52%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Nullable ChoiceField on ModelForm - has_changed always True

2016-01-20 Thread steve byerly
It actually looks like the commit fixed the regression and was in 1.9.1. 
Didn't realize it had been released.

On Tuesday, January 19, 2016 at 4:45:52 PM UTC-8, steve byerly wrote:
>
> Also of note, I recently upgraded to Django 1.9 from Django 1.7 where this 
> was working fine. It looks like this commit is the cause of my problem:
>
> https://github.com/django/django/commit/ff077cd6496b6f82195e2dc040f70e19e7c206c9
>
> On Tuesday, January 19, 2016 at 4:23:00 PM UTC-8, steve byerly wrote:
>>
>> I have a model with a nullable field (PositiveSmallIntegerField) with 
>> defined choices. When I make a ModelForm for the model and do not select a 
>> value for this field, the field always comes back in the changed data. The 
>> reason is that the empty choice value, the data_value, is an empty string, 
>> while the initial_value is None.
>>
>> I can override the base field and make a TypedChoiceField, and provide a 
>> function to coerce which returns None if the value is an empty string.
>>
>> Is this the only route, or is there a better way to accomplish this?
>>
>

-- 
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 https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/e420f6da-86d2-42af-92ca-8b297d941a94%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Nullable ChoiceField on ModelForm - has_changed always True

2016-01-19 Thread steve byerly
Also of note, I recently upgraded to Django 1.9 from Django 1.7 where this 
was working fine. It looks like this commit is the cause of my problem:
https://github.com/django/django/commit/ff077cd6496b6f82195e2dc040f70e19e7c206c9

On Tuesday, January 19, 2016 at 4:23:00 PM UTC-8, steve byerly wrote:
>
> I have a model with a nullable field (PositiveSmallIntegerField) with 
> defined choices. When I make a ModelForm for the model and do not select a 
> value for this field, the field always comes back in the changed data. The 
> reason is that the empty choice value, the data_value, is an empty string, 
> while the initial_value is None.
>
> I can override the base field and make a TypedChoiceField, and provide a 
> function to coerce which returns None if the value is an empty string.
>
> Is this the only route, or is there a better way to accomplish this?
>

-- 
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 https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/6c38874b-b876-43a5-827b-fcf8d48365cf%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Nullable ChoiceField on ModelForm - has_changed always True

2016-01-19 Thread steve byerly
I have a model with a nullable field (PositiveSmallIntegerField) with 
defined choices. When I make a ModelForm for the model and do not select a 
value for this field, the field always comes back in the changed data. The 
reason is that the empty choice value, the data_value, is an empty string, 
while the initial_value is None.

I can override the base field and make a TypedChoiceField, and provide a 
function to coerce which returns None if the value is an empty string.

Is this the only route, or is there a better way to accomplish this?

-- 
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 https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/1e11369b-7bcb-432f-acb6-c3785328b642%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


how do I .............?

2016-01-13 Thread Steve Burrus
how do I connmect to the Django server on the command line? 

-- 
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 https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/bb769cd8-8f1a-41e2-84cb-20e5f026b715%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Controlling access at table row level

2015-11-19 Thread Steve West
I've followed up the suggestions given here but am still struggling with 
this problem. My table rows are marked as 'public' or 'private' and the 
suggested approaches (and others I could think of) could certainly control 
access in such a way that logged-in users could access the whole table and 
other users coukd only access the 'public' items. So far so good.

The problem that I can't solve is that the same table is accessed by lots 
of foreign key relationships from other views in various apps. As far as I 
can tell, the available solutions all either allow the foreign key access 
to bypass the security or else result in unresolved foreign key accesses 
that raise exceptions. Either way, I am having to litter my code with 
either further security checks or checks for foreign keys to non-existent 
object instances. I'm kind of coming to the conclusion that there is no 
elegant solution to this but thought I would ask here one more time.

Thanks

Steve

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/8ad1817d-7c6f-435f-8a6f-650a4ed62160%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: QuerySet values() or values_list() with some RelatedObjectDoesNotExist records returns only those records with valid related intances

2015-11-18 Thread Steve W
Solved or Work-Around:

#Include a 'select_related()' invocation in the queryset chain, against the 
related model(s):

cases = Case.objects.select_related('release').all()
cases.count()
228

fieldnames = ('reference','release__release')
records = cases.values(*fieldnames)
records.count()
228

#OK, so that is the desired result. I implemented it in my (real) code and 
it works.

#So select_related() appears to be safe with respect to 
RelatedObjectDoesNotExist, returning None as desired, unlike 
queryset.values() which by default seems to remove the record.

#Perhaps a modification of queryset.values() to include the 
select_related() invocation on each related model would return all values 
as expected.

#Somewhere in the django.db.models.query.ValuesQuerySet I would imagine.

thanks.


 

On Thursday, November 19, 2015 at 12:31:44 AM UTC, Steve W wrote:
>
> Condition:  A model with a ForeignKey or OneToOne relationship to another 
> model...
>
 

> ...How then to make queryset.values() or queryset.values_list() behave in 
> the expected manner, by failing gracefully when it finds a member of a 
> queryset to have a RelatedObjectDoesNotExist exception, and thus writing 
> out the record to values() or values_list() the exception notwithstanding.
>
>
>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/f443f950-f22d-48a6-be92-67e0bed8c72e%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


QuerySet values() or values_list() with some RelatedObjectDoesNotExist records returns only those records with valid related intances

2015-11-18 Thread Steve W
Condition:  A model with a ForeignKey or OneToOne relationship to another 
model, where the related model instance may be null.

Desired Behavior: queryset.values() or values_list() returns all records 
from queryset, not just those with valid related model instance.

Observed Behavior: queryset.values() or values_list() returns records for 
only those members of the queryset where the related model instance exists 

Django 1.8.6 Postgres 9.4.1

#!
class Release(Model):
   release = TextField()

class Case(Model):
reference = TextField()
release = OneToOneField(Release, blank=True, null=True,
..related_name='cases')


from models import Case
cases = Case.objects.all()
cases.count()
228

fieldnames = ['reference']
records = cases.values(*fieldnames)
records.count()
228
#So far, so good

fieldnames = ('reference','release__release')
records = cases.values(*fieldnames)
records.count()
63

#No, not good.  Just lost a whole bunch of records, why?
cases = Case.objects.filter(release__isnull=False)
cases.count()
63
records = cases.values(*fieldnames)
records.count()
63
#Clearly this is because there is no related release for each missing case.

#As we see here:
case_without_release = Case.objects.filter(release__isnull=True)[0]
case.release
ReleatedObjectDoesNotExist: Case has no release

#How then to make queryset.values() or queryset.values_list() behave in the 
expected manner, by failing gracefully when it finds a member of a queryset 
to have a RelatedObjectDoesNotExist exception, and thus writing out the 
record to values() or values_list() the exception notwithstanding.


Thank you,
-Steve 

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/40691ae2-6b72-48a0-bf4c-e1b10a00a40c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Controlling access at table row level

2015-11-06 Thread Steve West
Thanks for the suggestions. I'll give them a try.
Cheers
Steve

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/5f3c185a-0c98-4d90-8520-edfb7ad99e01%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Controlling access at table row level

2015-11-05 Thread Steve West
Hi all

I'm implementing a Django project in which individual table rows are marked 
as either private or public. I need to be able to filter accesses to the 
tables in such a way that logged-in users can see everything, but other 
users only get visibility of the 'public' rows. My initial thoughts were 
that I could apply a check on whether the user is logged in in any of three 
places: at the model level, in views or in templates. It seemed to me that 
the most elegant and robust option would be to do so at the model level, by 
writing custom managers for my models. Within the custom managers, I could 
check if the user is logged in and filter all queries accordingly.

I did an initial implementation of the above approach, but quickly found 
problems. Whenever I span foreign key relationships in my views, the 
default model manager is invoked, so i have had to add in further tests for 
whether the user is logged in at the view level. I've also got some cases 
where foreign keys are spanned at the template level and have had to add 
further login tests there, too.

All-in-all, I don't think I am going about this in the right way!  In the 
Django documentation, it seems to be mostly expected that one will use 
authentication to control access to individual views or model operations, 
rather than controlling finer-grained access to individual rows, so I 
haven't found anything that really helps.

Can anyone please offer any advice or suggest what would be the best way of 
solving the problem or point my at any documentation that might help.

Many thanks

Steve

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/002471e1-8a64-4637-9d00-ae774924fd84%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


How To Make Django Models.

2015-09-09 Thread Steve Burrus
*I am sorry thart I don't know much more about Django than I do but could 
someone please inform me about how do I make a Model? i  haven't moved 
beyond connecting to the Django server yet and configuring the admin.*


 

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/43c328fc-1e03-4cab-aad3-c41ad407ac0c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Migrations and FileField storage

2015-08-25 Thread Steve Capell
Hi Nico,

I had the same problem when I was using this storage object:

photoStorage = FileSystemStorage(location=os.path.join(settings.MEDIA_ROOT, 
'photos/original'), base_url='/photos/original')

class Photo(models.Model):
image = models.ImageField(storage=photoStorage)


The "location" argument ends up being serialized, which makes the 
migrations dependent on MEDIA_ROOT. To fix the problem I wrote my own 
subclass of FileSystemStorage:

@deconstructible
class PhotoFileSystemStorage(FileSystemStorage):
def __init__(self, photoPath):
self.photoPath = photoPath
super(PhotoFileSystemStorage,self).__init__(location=os.path.join(settings.MEDIA_ROOT,
 
self.photoPath), base_url=self.photoPath)

def __eq__(self, other):
   return self.photoPath == other.photoPath

photoStorage = PhotoFileSystemStorage('photos/original')

When an instance of PhotoFileSystemStorage is serialized it just writes out 
self.photoPath, which does not depend on MEDIA_ROOT. After implementing 
this, the migration looks like this:

class Migration(migrations.Migration):

dependencies = [
...
]

operations = [
migrations.AlterField(
model_name='photo',
name='image',

field=models.ImageField(storage=myapp.models.PhotoFileSystemStorage(b'photos/original')),
),
]

You can see it does not depend on MEDIA_ROOT and won't be different if you 
move the project around or deploy it.

The django docs on this are 
here: https://docs.djangoproject.com/en/1.8/topics/migrations/

Hope this helps.


Steve


-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/b1972234-7ef7-48f6-8dee-afcfacf7fafb%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Django + microservices: What's correct approach?

2015-08-25 Thread Steve McConville
> 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.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/ceefe6b9-ab71-405c-abae-dc09ed3f695f%40googlegroups.com.
>
> For more options, visit https://groups.google.com/d/optout.



-- 
steve
http://stevemcconville.com/

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAOoCU%3DTR0T3_toYVRkocWgBCTp5mQqGrYr-z-76Bv6ujxByMZA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


AWS Ops Works - Setup DJango

2015-08-14 Thread Steve McAtee
Hello,

I'm a bit of a noob when it comes to DJango.  I am trying to deploy a 
zipped django application into AWS OpsWorks. 

I am using: https://github.com/alecpm/opsworks-web-python

I have built the stack and get it to start and install Django/python.

What I am stuck in is how do I take a Zip of a Django app and deploy it 
into AWS OpsWorks?  Normally in Java you would build an application. 
 However, I think this is wanting everything to be done in the Chef Recipe.

Any help would be appreciated.  I'd hate to have to go back to Java.



-- 
NOTICE: This electronic mail message and any files transmitted with it are 
intended exclusively for the individual or entity to which it is addressed. 
The message, together with any attachment, may contain confidential and/or 
privileged information. Any unauthorized review, use, printing, saving, 
copying, disclosure or distribution is strictly prohibited. If you have 
received this message in error, please immediately advise the sender by 
reply email and delete all copies.

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/eb7a36f5-b764-45b3-bc0b-671ff069f69f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re. My Django Book.

2015-07-30 Thread Steve Burrus
* Say I was wondering if anyone else has ever read this particulkar Django 
book called "Sams Teach Yourself Django in 24 Hours" I checked out of the 
library yesterday? [yeah I know it's one of the "24 hours" series] Does it 
really teach the beginner a lot of things concerning Django?*


   

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/de78f7fa-cb87-4d88-a9c6-886f43841bb2%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Need Django Help Again.

2015-07-22 Thread Steve Burrus
say do yoiu know of a handy series of tutorials I can use to actually do
something in Django beyond merely connecting to the server and maybe
configuring the admin? I am getting tired of just connecting to the server
and then "calling it a day" if you know what I mean.



On Wed, Jul 22, 2015 at 1:20 PM, Bill Freeman <ke1g...@gmail.com> wrote:

> That's actually a virtualenv mistake, rather than a django mistake.
> Whenever things don't behave in a VE try "pip freeze" to see if things are
> as you expect.
>
> On Wed, Jul 22, 2015 at 1:16 PM, Steve Burrus <steveburru...@gmail.com>
> wrote:
>
>> *Okay it's a case of "my bad". I got it gpoing. I had just forgotten to
>> do this command : "pip install django" in the "burrus" virtual environment
>> inst ance! I still have the shakiest knowledge of django in general so
>> little mistakes like this I am gonna have a little while longer.*
>>
>>
>> *On Wed, Jul 22, 2015 at 12:03 PM, Bill Freeman <ke1g...@gmail.com
>> <ke1g...@gmail.com>> wrote:*
>>
>>>
>>> *I presume that you have actually checked for a django-admin.py file in
>>> the Scripts directory?*
>>>
>>>
>>> *On Wed, Jul 22, 2015 at 12:58 PM, Steve Burrus <steveburru...@gmail.com
>>> <steveburru...@gmail.com>> wrote:*
>>>
>>>>
>>>>
>>>>
>>>>
>>>>>
>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>
>>>> *well I haVE tried both this "python .\Scripts\django-admin.py
>>>> startproject me" and Bill's suggestion opf  "python django-admin.py
>>>> startproject me" but both haVE failed! I'll try Bill's other suggestion of
>>>> the forward slashes but I doubt it will work.On Wed, Jul 22, 2015 at 11:51
>>>> AM, Steve Burrus <steveburru...@gmail.com <steveburru...@gmail.com>>
>>>> wrote:well tom tjhanx for your  attempted help but it still didn't work
>>>> after I took care of that space after "\Scripts\"!  here is my error
>>>> message now : "python: can't open file '.\Scripts\django-admin.py': [Errno
>>>> 2] No such file or directory".On Wed, Jul 22, 2015 at 11:34 AM, Tom
>>>> Lockhart <tlockhart1...@gmail.com <tlockhart1...@gmail.com>> wrote:On Jul
>>>> 22, 2015, at 09:11, Steve Burrus <steveburru...@gmail.com
>>>> <steveburru...@gmail.com>> wrote:I find myself in ned of help yet again w.
>>>> django. Just to say parenthetically I have had this problem before. just
>>>> what am I doing wrong with the command "python .\Scripts\ django-admin.py
>>>> startproject me" to consistently get this error message! Thanx to anyone
>>>> who helps me.   "C:\Users\SteveB\Desktop\burrus>.\Scripts\activate(burrus)
>>>> C:\Users\SteveB\Desktop\burrus>python .\Scripts\ django-admin.py
>>>> startproject meC:\Users\SteveB\Desktop\burrus\Scripts\python.exe: can't
>>>> find '__main__' module in '.\\Scripts\\’"You seem to have a space after the
>>>> “\Scripts\”.hth- Tom -- You received this message because you are
>>>> subscribed to a topic in the Google Groups "Django users" group. To
>>>> unsubscribe from this topic, visit
>>>> https://groups.google.com/d/topic/django-users/uxHvoccBiZc/unsubscribe
>>>> <https://groups.google.com/d/topic/django-users/uxHvoccBiZc/unsubscribe>.
>>>> To unsubscribe from this group and all its topics, send an email to
>>>> django-users+unsubscr...@googlegroups.com
>>>> <django-users+unsubscr...@googlegroups.com>. To post to this group, send
>>>> email to django-users@googlegroups.com <django-users@googlegroups.com>.
>>>> Visit this group at http://groups.google.com/group/django-users
>>>> <http://groups.google.com/group/django-users>. To view this discussion on
>>>> the web visit
>>>> https://groups.google.com/d/msgid/django-users/9F05E056-A548-4EE4-89AE-0F3F14876503%40gmail.com
>>>> <https://groups.google.com/d/msgid/django-users/9F05E056-A548-4EE4-89AE-0F3F14876503%40gmail.com?utm_medium=email_source=footer>.
>>>

Re: Need Django Help Again.

2015-07-22 Thread Steve Burrus
*Okay it's a case of "my bad". I got it gpoing. I had just forgotten to do
this command : "pip install django" in the "burrus" virtual environment
inst ance! I still have the shakiest knowledge of django in general so
little mistakes like this I am gonna have a little while longer.*


*On Wed, Jul 22, 2015 at 12:03 PM, Bill Freeman <ke1g...@gmail.com
<ke1g...@gmail.com>> wrote:*
>
>
> *I presume that you have actually checked for a django-admin.py file in
> the Scripts directory?*
>
>
> *On Wed, Jul 22, 2015 at 12:58 PM, Steve Burrus <steveburru...@gmail.com
> <steveburru...@gmail.com>> wrote:*
>
>>
>>
>>
>>
>>>
>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>
>> *well I haVE tried both this "python .\Scripts\django-admin.py
>> startproject me" and Bill's suggestion opf  "python django-admin.py
>> startproject me" but both haVE failed! I'll try Bill's other suggestion of
>> the forward slashes but I doubt it will work.On Wed, Jul 22, 2015 at 11:51
>> AM, Steve Burrus <steveburru...@gmail.com <steveburru...@gmail.com>>
>> wrote:well tom tjhanx for your  attempted help but it still didn't work
>> after I took care of that space after "\Scripts\"!  here is my error
>> message now : "python: can't open file '.\Scripts\django-admin.py': [Errno
>> 2] No such file or directory".On Wed, Jul 22, 2015 at 11:34 AM, Tom
>> Lockhart <tlockhart1...@gmail.com <tlockhart1...@gmail.com>> wrote:On Jul
>> 22, 2015, at 09:11, Steve Burrus <steveburru...@gmail.com
>> <steveburru...@gmail.com>> wrote:I find myself in ned of help yet again w.
>> django. Just to say parenthetically I have had this problem before. just
>> what am I doing wrong with the command "python .\Scripts\ django-admin.py
>> startproject me" to consistently get this error message! Thanx to anyone
>> who helps me.   "C:\Users\SteveB\Desktop\burrus>.\Scripts\activate(burrus)
>> C:\Users\SteveB\Desktop\burrus>python .\Scripts\ django-admin.py
>> startproject meC:\Users\SteveB\Desktop\burrus\Scripts\python.exe: can't
>> find '__main__' module in '.\\Scripts\\’"You seem to have a space after the
>> “\Scripts\”.hth- Tom -- You received this message because you are
>> subscribed to a topic in the Google Groups "Django users" group. To
>> unsubscribe from this topic, visit
>> https://groups.google.com/d/topic/django-users/uxHvoccBiZc/unsubscribe
>> <https://groups.google.com/d/topic/django-users/uxHvoccBiZc/unsubscribe>.
>> To unsubscribe from this group and all its topics, send an email to
>> django-users+unsubscr...@googlegroups.com
>> <django-users+unsubscr...@googlegroups.com>. To post to this group, send
>> email to django-users@googlegroups.com <django-users@googlegroups.com>.
>> Visit this group at http://groups.google.com/group/django-users
>> <http://groups.google.com/group/django-users>. To view this discussion on
>> the web visit
>> https://groups.google.com/d/msgid/django-users/9F05E056-A548-4EE4-89AE-0F3F14876503%40gmail.com
>> <https://groups.google.com/d/msgid/django-users/9F05E056-A548-4EE4-89AE-0F3F14876503%40gmail.com?utm_medium=email_source=footer>.
>> For more options, visit https://groups.google.com/d/optout
>> <https://groups.google.com/d/optout>. *
>>
>>
>>
>>
>>
>>
>>
>>
>> * -- 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
>> <django-users+unsubscr...@googlegroups.com>. To post to this group, send
>> email to django-users@googlegroups.com <django-users@googlegroups.com>.
>> Visit this group at http://groups.google.com/group/django-users
>> <http://groups.google.com/group/django-users>. To view this discussion on
>> the web visit
>> https://groups.google.com/d/msgid/django-users/CABcoaSDY2f0hibB-i-KXd1s5eQvQPHk9cARORmzPMxffUbwUtg%40mail.gmail.com
>> <https://groups.google.com/d/msgid/django-users/CABcoaSDY2f0hibB-i-KXd1s5eQvQPHk9cARORmzPMxffUbwUtg%40mail.gmail.com?utm_medium=email_source=footer>.
>> For more options, visit https://groups.google.com/d/optout
>> <https://groups.google.com/d/optout>. *
>
>

Re: Need Django Help Again.

2015-07-22 Thread Steve Burrus
*well I haVE tried both this "python .\Scripts\django-admin.py startproject
me" and Bill's suggestion opf  "python django-admin.py startproject me" but
both haVE failed! I'll try Bill's other suggestion of the forward slashes
but I doubt it will work.*


*On Wed, Jul 22, 2015 at 11:51 AM, Steve Burrus <steveburru...@gmail.com
<steveburru...@gmail.com>> wrote:*
>
> *well tom tjhanx for your  attempted help but it still didn't work after I
> took care of that space after "\Scripts\"!  here is my error message now :
> "python: can't open file '.\Scripts\django-admin.py': [Errno 2] No such
> file or directory".*
>
>
> *On Wed, Jul 22, 2015 at 11:34 AM, Tom Lockhart <tlockhart1...@gmail.com
> <tlockhart1...@gmail.com>> wrote:*
>>
>>
>>
>> *On Jul 22, 2015, at 09:11, Steve Burrus <steveburru...@gmail.com
>> <steveburru...@gmail.com>> wrote:*
>> *I find myself in ned of help yet again w. django. Just to say
>> parenthetically I have had this problem before. just what am I doing wrong
>> with the command "**python .\Scripts\ django-admin.py startproject me"
>> to consistently get this error message! Thanx to anyone who helps me. *
>>
>> *"C:\Users\SteveB\Desktop\burrus>.\Scripts\activate*
>> *(burrus) C:\Users\SteveB\Desktop\burrus>python .\Scripts\
>> django-admin.py startproject me*
>> *C:\Users\SteveB\Desktop\burrus\Scripts\python.exe: can't find '__main__'
>> module in '.\\Scripts\\’"*
>>
>>
>> *You seem to have a space after the “\Scripts\”.*
>>
>> *hth*
>>
>> *- Tom*
>>
>>
>>
>>
>>
>>
>>
>> * -- You received this message because you are subscribed to a topic in
>> the Google Groups "Django users" group. To unsubscribe from this topic,
>> visit
>> https://groups.google.com/d/topic/django-users/uxHvoccBiZc/unsubscribe
>> <https://groups.google.com/d/topic/django-users/uxHvoccBiZc/unsubscribe>.
>> To unsubscribe from this group and all its topics, send an email to
>> django-users+unsubscr...@googlegroups.com
>> <django-users+unsubscr...@googlegroups.com>. To post to this group, send
>> email to django-users@googlegroups.com <django-users@googlegroups.com>.
>> Visit this group at http://groups.google.com/group/django-users
>> <http://groups.google.com/group/django-users>. To view this discussion on
>> the web visit
>> https://groups.google.com/d/msgid/django-users/9F05E056-A548-4EE4-89AE-0F3F14876503%40gmail.com
>> <https://groups.google.com/d/msgid/django-users/9F05E056-A548-4EE4-89AE-0F3F14876503%40gmail.com?utm_medium=email_source=footer>.*
>>
>>
>> * For more options, visit https://groups.google.com/d/optout
>> <https://groups.google.com/d/optout>. *
>>
>
>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CABcoaSDY2f0hibB-i-KXd1s5eQvQPHk9cARORmzPMxffUbwUtg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: Need Django Help Again.

2015-07-22 Thread Steve Burrus
*well tom tjhanx for your  attempted help but it still didn't work after I
took care of that space after "\Scripts\"!  here is my error message now :
"python: can't open file '.\Scripts\django-admin.py': [Errno 2] No such
file or directory".*


*On Wed, Jul 22, 2015 at 11:34 AM, Tom Lockhart <tlockhart1...@gmail.com
<tlockhart1...@gmail.com>> wrote:*
>
>
>
> *On Jul 22, 2015, at 09:11, Steve Burrus <steveburru...@gmail.com
> <steveburru...@gmail.com>> wrote:*
> *I find myself in ned of help yet again w. django. Just to say
> parenthetically I have had this problem before. just what am I doing wrong
> with the command "**python .\Scripts\ django-admin.py startproject me" to
> consistently get this error message! Thanx to anyone who helps me. *
>
> *"C:\Users\SteveB\Desktop\burrus>.\Scripts\activate*
> *(burrus) C:\Users\SteveB\Desktop\burrus>python .\Scripts\ django-admin.py
> startproject me*
> *C:\Users\SteveB\Desktop\burrus\Scripts\python.exe: can't find '__main__'
> module in '.\\Scripts\\’"*
>
>
> *You seem to have a space after the “\Scripts\”.*
>
> *hth*
>
> *- Tom*
>
>
>
>
>
>
>
> * -- You received this message because you are subscribed to a topic in
> the Google Groups "Django users" group. To unsubscribe from this topic,
> visit
> https://groups.google.com/d/topic/django-users/uxHvoccBiZc/unsubscribe
> <https://groups.google.com/d/topic/django-users/uxHvoccBiZc/unsubscribe>.
> To unsubscribe from this group and all its topics, send an email to
> django-users+unsubscr...@googlegroups.com
> <django-users+unsubscr...@googlegroups.com>. To post to this group, send
> email to django-users@googlegroups.com <django-users@googlegroups.com>.
> Visit this group at http://groups.google.com/group/django-users
> <http://groups.google.com/group/django-users>. To view this discussion on
> the web visit
> https://groups.google.com/d/msgid/django-users/9F05E056-A548-4EE4-89AE-0F3F14876503%40gmail.com
> <https://groups.google.com/d/msgid/django-users/9F05E056-A548-4EE4-89AE-0F3F14876503%40gmail.com?utm_medium=email_source=footer>.*
>
>
> * For more options, visit https://groups.google.com/d/optout
> <https://groups.google.com/d/optout>. *
>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CABcoaSD1OZKCQpq_yp5-Q6CuAEM%3DDmGfw%2BY-jpTOV-oTjB7Vxw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Need Django Help Again.

2015-07-22 Thread Steve Burrus
*I find myself in ned of help yet again w. django. Just to say 
parenthetically I have had this problem before. just what am I doing wrong 
with the command "**python .\Scripts\ django-admin.py startproject me" to 
consistently get this error message! Thanx to anyone who helps me. *  

*"C:\Users\SteveB\Desktop\burrus>.\Scripts\activate*
*(burrus) C:\Users\SteveB\Desktop\burrus>python .\Scripts\ django-admin.py 
startproject me*
*C:\Users\SteveB\Desktop\burrus\Scripts\python.exe: can't find '__main__' 
module in '.\\Scripts\\'"*

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/98551cf6-475c-41f9-b7a1-1ce5eecc30ce%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Using Django FormPreview the right way

2015-07-21 Thread Steve SanPietro
Hi All,

I have a Django project with a form, and I want to display a preview page 
before the user submits.  I can display a preview page using a Django 
FormPreview, but not all form data is displayed properly. Specifically, if 
I have a model field with choices, the string values of these choices 
aren't displayed properly when I use the get_FOO_display method - they 
display as blanks instead.  I'm also having problems applying template 
filters to date fields. The end result is that some data on the preview 
page is visible but other data is blank:

I've posted a question about this topic on StackOverflow here 
,
 
but so far, no one has been able to answer it.  I'm not sure if it's 
considered good etiquette to link to StackOverflow questions on this 
mailing list, so if this is inappropriate, please let me know.  If not, I'd 
greatly appreciate it if anyone here would be able to answer this question.

Thanks!

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/db450332-06ea-4414-b67a-1d2356d56051%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Installing Django [Again]

2015-07-09 Thread Steve Burrus
*I know thrat I have appealed for help about this before but I am having 
problems aGAIN with installing Django. Well I was able to run "pip install 
django" okay but then I don't know where to go from there! Here is where I 
am now :  (myenv)C:\Users\SteveB\Desktop\myenv>*


-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/7621b62f-01fc-4ef4-8907-7385b9e31a17%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Python & Django.

2015-07-06 Thread Steve Burrus
Well I want to sheeplishly say thwat I DID get Python 3.4.2 going with the 
Django server! I kind of feel like the late Gilda Radner saying "Never 
mind!" in her well-known Saturday Night Live sketch. But to answer your 
question andrew I am using the Windows 10 beta preview version of Windows.

"(steve) C:\Users\SteveB\Desktop\steve\src>python manage.py runserver
Performing system checks...

System check identified no issues (0 silenced).
July 06, 2015 - 11:48:25
Django version 1.8.2, using settings 'proj.settings'
Starting development server at http://127.0.0.1:8000/
Quit the server with CTRL-BREAK.
[06/Jul/2015 11:49:02]"GET / HTTP/1.1" 200 1767
[06/Jul/2015 11:49:03]"GET /favicon.ico HTTP/1.1" 404 1934"




On Sunday, July 5, 2015 at 10:33:36 AM UTC-5, Steve Burrus wrote:
>
> *Listen I am having/experiencing some degree of diffilculty in being able 
> to coordinaTE my Pytjhon version with Django. i can easily end up 
> connecting to the [django] server but I have to use python version 2.7.* 
> ins tead of the preferred version 3.4.* ZCan some please help me with this?*
>
>
>  
>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/83790021-8f76-45ab-894e-4e59404f227d%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Python & Django.

2015-07-05 Thread Steve Burrus
*"Are you getting an error message?" lNo particular error message. But I
cannot even start to go thru the usual procedure to end up connecting to
the Django server! It's irrational that for as long as the version 3.4.* of
python has been out that  I hAvE to still use the old version 2.7.  *


*On Sun, Jul 5, 2015 at 4:52 PM, Aaron C. de Bruyn <aa...@heyaaron.com
<aa...@heyaaron.com>> wrote:*
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
> *Are you getting an error message? Can you describe what is happening (or
> not happening)? Thanks, -A On Sun, Jul 5, 2015 at 8:33 AM, Steve Burrus
> <steveburru...@gmail.com <steveburru...@gmail.com>> wrote: > Listen I am
> having/experiencing some degree of diffilculty in being able to >
> coordinaTE my Pytjhon version with Django. i can easily end up connecting
> to > the [django] server but I have to use python version 2.7.* ins tead of
> the > preferred version 3.4.* ZCan some please help me with this? > > > > >
> -- > 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
> <django-users%2bunsubscr...@googlegroups.com>. > To post to this group,
> send email to django-users@googlegroups.com
> <django-users@googlegroups.com>. > Visit this group at
> http://groups.google.com/group/django-users
> <http://groups.google.com/group/django-users>. > To view this discussion on
> the web visit >
> https://groups.google.com/d/msgid/django-users/1d63c599-24ae-416f-8f01-d584c3fd8dfa%40googlegroups.com
> <https://groups.google.com/d/msgid/django-users/1d63c599-24ae-416f-8f01-d584c3fd8dfa%40googlegroups.com>.
> > For more options, visit https://groups.google.com/d/optout
> <https://groups.google.com/d/optout>. -- You received this message because
> you are subscribed to a topic in the Google Groups "Django users" group. To
> unsubscribe from this topic, visit
> https://groups.google.com/d/topic/django-users/fAjA0D7wyXM/unsubscribe
> <https://groups.google.com/d/topic/django-users/fAjA0D7wyXM/unsubscribe>.
> To unsubscribe from this group and all its topics, send an email to
> django-users+unsubscr...@googlegroups.com
> <django-users%2bunsubscr...@googlegroups.com>. To post to this group, send
> email to django-users@googlegroups.com <django-users@googlegroups.com>.
> Visit this group at http://groups.google.com/group/django-users
> <http://groups.google.com/group/django-users>. To view this discussion on
> the web visit
> https://groups.google.com/d/msgid/django-users/CAEE%2BrGpyXcBm1AszLHXqsaJ2rg7y13u-1SjT9MizNbT6wdx8Cw%40mail.gmail.com
> <https://groups.google.com/d/msgid/django-users/CAEE%2BrGpyXcBm1AszLHXqsaJ2rg7y13u-1SjT9MizNbT6wdx8Cw%40mail.gmail.com>.
> *
>
> *For more options, visit https://groups.google.com/d/optout
> <https://groups.google.com/d/optout>. *
>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CABcoaSDK9Yk%2BxadQMw2Kq3cXpEz4BzDzsbs_JDE8db%3DUFGUOEw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Python & Django.

2015-07-05 Thread Steve Burrus
*Listen I am having/experiencing some degree of diffilculty in being able 
to coordinaTE my Pytjhon version with Django. i can easily end up 
connecting to the [django] server but I have to use python version 2.7.* 
ins tead of the preferred version 3.4.* ZCan some please help me with this?*


 

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/1d63c599-24ae-416f-8f01-d584c3fd8dfa%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Can't Start Project.

2015-07-01 Thread Steve Burrus
"As long as you're happy with the default file name." What exactly are you
referring to Bill? The database settings? Say how dpo you synch either
mysql or the postgres database server into django anyway? I really haven't
figured out yet how to do that I am afraid.



On Wed, Jul 1, 2015 at 5:51 PM, Bill Freeman <ke1g...@gmail.com> wrote:

> As long as you're happy with the default file name.
>
> On Wed, Jul 1, 2015 at 6:06 PM, Gergely Polonkai <gerg...@polonkai.eu>
> wrote:
>
>> No, Django does that for you. You only have to worry about DB settings if
>> you want something else like MySQL or Postgres.
>> On 1 Jul 2015 23:40, "Bill Freeman" <ke1g...@gmail.com> wrote:
>>
>>> Yes.  syncdb should work, assuming that sqlite is available (I think
>>> that it's built in in all the python 3.x versions), and assuming that you
>>> have a correctly configured settings.py (startproject makes one, but you
>>> will still have things to enter, such as data base configuration info (like
>>> the file to use to back sqlite), or to edit, such as your timezone.
>>>
>>> On Wed, Jul 1, 2015 at 5:35 PM, Steve Burrus <steveburru...@gmail.com>
>>> wrote:
>>>
>>>> no django was not installed so I did a quick "pip install django" and
>>>> installed django 1.8.2 into my ins tance of virualenv and was [finally]
>>>> able to connect to the django server. I assume trhat I can easily do the
>>>> "python manage.py syncdb" to connect to the sqllite3 server?
>>>>
>>>>
>>>> On Wed, Jul 1, 2015 at 3:58 PM, Bill Freeman <ke1g...@gmail.com> wrote:
>>>>
>>>>> It sounds like django isn't on your path.  If you are running in a
>>>>> virtualenv, was django pip installed while running in that same 
>>>>> environment?
>>>>>
>>>>> On Wed, Jul 1, 2015 at 4:26 PM, Steve Burrus <steveburru...@gmail.com>
>>>>> wrote:
>>>>>
>>>>>> cd to the directory containing manage.py (the project directory),
>>>>>> then: "python manage.py runserver" Yeah I just now did exact;ly that but
>>>>>> STILL got the error message : "(steve)
>>>>>> C:\Users\SteveB\Desktop\steve\src>python manage.py runserver Traceback
>>>>>> (most recent call last):  File "manage.py", line 8, in  from
>>>>>> django.core.management import execute_from_command_line ImportError:
>>>>>> No module named django.core.management" I r enamed my newly created 
>>>>>> project
>>>>>> to "src".
>>>>>>
>>>>>>
>>>>>> On Wed, Jul 1, 2015 at 3:14 PM, Bill Freeman <ke1g...@gmail.com>
>>>>>> wrote:
>>>>>>
>>>>>>> cd to the directory containing manage.py (the project directory),
>>>>>>> then:
>>>>>>>
>>>>>>>   python manage.py runserver
>>>>>>>
>>>>>>> On Wed, Jul 1, 2015 at 2:04 PM, Steve Burrus <
>>>>>>> steveburru...@gmail.com> wrote:
>>>>>>>
>>>>>>>> well I was able to create a new project earlier however I am now
>>>>>>>> having trouble with starting the django ser ver. when I ran this 
>>>>>>>> cpommand
>>>>>>>> "python .\Scripts\django-admin.py runserver" I always get this error
>>>>>>>> message : "python: can't open file '.\Scripts\django-admin.py': [Errno 
>>>>>>>> 2]
>>>>>>>> No such file or directory". What's going on for me to get this error?
>>>>>>>>
>>>>>>>> On Wednesday, July 1, 2015 at 10:27:14 AM UTC-5, Steve Burrus wrote:
>>>>>>>>>
>>>>>>>>> I need some help please with  tryiong to start a new Django
>>>>>>>>> project. Here is the error message I always get when I try to do 
>>>>>>>>> this. can
>>>>>>>>> someone help me with this?
>>>>>>>>>
>>>>>>>>> "C:\Users\SteveB\Desktop\steve>.\Scripts\activate
>>>>>>>>> (steve) C:\Users\SteveB\Desktop\steve>python
>>>>>>>>> .\Scripts\django-admin.py startproject proj
>>>>>>>>> python: can't op

Re: Can't Start Project.

2015-07-01 Thread Steve Burrus
no django was not installed so I did a quick "pip install django" and
installed django 1.8.2 into my ins tance of virualenv and was [finally]
able to connect to the django server. I assume trhat I can easily do the
"python manage.py syncdb" to connect to the sqllite3 server?


On Wed, Jul 1, 2015 at 3:58 PM, Bill Freeman <ke1g...@gmail.com> wrote:

> It sounds like django isn't on your path.  If you are running in a
> virtualenv, was django pip installed while running in that same environment?
>
> On Wed, Jul 1, 2015 at 4:26 PM, Steve Burrus <steveburru...@gmail.com>
> wrote:
>
>> cd to the directory containing manage.py (the project directory), then:
>> "python manage.py runserver" Yeah I just now did exact;ly that but STILL
>> got the error message : "(steve) C:\Users\SteveB\Desktop\steve\src>python
>> manage.py runserver Traceback (most recent call last):  File
>> "manage.py", line 8, in  from django.core.management import
>> execute_from_command_line ImportError: No module named
>> django.core.management" I r enamed my newly created project to "src".
>>
>>
>> On Wed, Jul 1, 2015 at 3:14 PM, Bill Freeman <ke1g...@gmail.com> wrote:
>>
>>> cd to the directory containing manage.py (the project directory), then:
>>>
>>>   python manage.py runserver
>>>
>>> On Wed, Jul 1, 2015 at 2:04 PM, Steve Burrus <steveburru...@gmail.com>
>>> wrote:
>>>
>>>> well I was able to create a new project earlier however I am now having
>>>> trouble with starting the django ser ver. when I ran this cpommand "python
>>>> .\Scripts\django-admin.py runserver" I always get this error message :
>>>> "python: can't open file '.\Scripts\django-admin.py': [Errno 2] No such
>>>> file or directory". What's going on for me to get this error?
>>>>
>>>> On Wednesday, July 1, 2015 at 10:27:14 AM UTC-5, Steve Burrus wrote:
>>>>>
>>>>> I need some help please with  tryiong to start a new Django project.
>>>>> Here is the error message I always get when I try to do this. can someone
>>>>> help me with this?
>>>>>
>>>>> "C:\Users\SteveB\Desktop\steve>.\Scripts\activate
>>>>> (steve) C:\Users\SteveB\Desktop\steve>python .\Scripts\django-admin.py
>>>>> startproject proj
>>>>> python: can't open file '.\Scripts\django-admin.py': [Errno 2] No such
>>>>> file or directory"
>>>>>
>>>>>
>>>>>
>>>>>  --
>>>> 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.
>>>> To view this discussion on the web visit
>>>> https://groups.google.com/d/msgid/django-users/db741397-9c7c-4368-805c-07d60d6042bf%40googlegroups.com
>>>> <https://groups.google.com/d/msgid/django-users/db741397-9c7c-4368-805c-07d60d6042bf%40googlegroups.com?utm_medium=email_source=footer>
>>>> .
>>>> For more options, visit https://groups.google.com/d/optout.
>>>>
>>>
>>>  --
>>> You received this message because you are subscribed to a topic in the
>>> Google Groups "Django users" group.
>>> To unsubscribe from this topic, visit
>>> https://groups.google.com/d/topic/django-users/1wWP0wRstsU/unsubscribe.
>>> To unsubscribe from this group and all its topics, 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.
>>> To view this discussion on the web visit
>>> https://groups.google.com/d/msgid/django-users/CAB%2BAj0uiQO5Ksjd-xkQ_kVr2SDvNEGM654x0mmEs1gCRW2jmCg%40mail.gmail.com
>>> <https://groups.google.com/d/msgid/django-users/CAB%2BAj0uiQO5Ksjd-xkQ_kVr2SDvNEGM654x0mmEs1gCRW2jmCg%40mail.gmail.com?utm_medium=email_source=footer>
>>> .
>>>
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>>
>>  --
>> You received this message because you are subscribed to the Google Groups
>> "Django users" group

Re: Can't Start Project.

2015-07-01 Thread Steve Burrus
cd to the directory containing manage.py (the project directory), then:
"python manage.py runserver" Yeah I just now did exact;ly that but STILL
got the error message : "(steve) C:\Users\SteveB\Desktop\steve\src>python
manage.py runserver Traceback (most recent call last):  File "manage.py",
line 8, in  from django.core.management import
execute_from_command_line ImportError: No module named
django.core.management" I r enamed my newly created project to "src".


On Wed, Jul 1, 2015 at 3:14 PM, Bill Freeman <ke1g...@gmail.com> wrote:

> cd to the directory containing manage.py (the project directory), then:
>
>   python manage.py runserver
>
> On Wed, Jul 1, 2015 at 2:04 PM, Steve Burrus <steveburru...@gmail.com>
> wrote:
>
>> well I was able to create a new project earlier however I am now having
>> trouble with starting the django ser ver. when I ran this cpommand "python
>> .\Scripts\django-admin.py runserver" I always get this error message :
>> "python: can't open file '.\Scripts\django-admin.py': [Errno 2] No such
>> file or directory". What's going on for me to get this error?
>>
>> On Wednesday, July 1, 2015 at 10:27:14 AM UTC-5, Steve Burrus wrote:
>>>
>>> I need some help please with  tryiong to start a new Django project.
>>> Here is the error message I always get when I try to do this. can someone
>>> help me with this?
>>>
>>> "C:\Users\SteveB\Desktop\steve>.\Scripts\activate
>>> (steve) C:\Users\SteveB\Desktop\steve>python .\Scripts\django-admin.py
>>> startproject proj
>>> python: can't open file '.\Scripts\django-admin.py': [Errno 2] No such
>>> file or directory"
>>>
>>>
>>>
>>>  --
>> 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.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/django-users/db741397-9c7c-4368-805c-07d60d6042bf%40googlegroups.com
>> <https://groups.google.com/d/msgid/django-users/db741397-9c7c-4368-805c-07d60d6042bf%40googlegroups.com?utm_medium=email_source=footer>
>> .
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>  --
> You received this message because you are subscribed to a topic in the
> Google Groups "Django users" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/django-users/1wWP0wRstsU/unsubscribe.
> To unsubscribe from this group and all its topics, 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.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/CAB%2BAj0uiQO5Ksjd-xkQ_kVr2SDvNEGM654x0mmEs1gCRW2jmCg%40mail.gmail.com
> <https://groups.google.com/d/msgid/django-users/CAB%2BAj0uiQO5Ksjd-xkQ_kVr2SDvNEGM654x0mmEs1gCRW2jmCg%40mail.gmail.com?utm_medium=email_source=footer>
> .
>
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CABcoaSAOXFYq8HQYsCw48rvGjBSEv29XgoFcARKATfx_My_eWQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: Can't Start Project.

2015-07-01 Thread Steve Burrus
well I was able to create a new project earlier however I am now having 
trouble with starting the django ser ver. when I ran this cpommand "python 
.\Scripts\django-admin.py runserver" I always get this error message : 
"python: can't open file '.\Scripts\django-admin.py': [Errno 2] No such 
file or directory". What's going on for me to get this error?

On Wednesday, July 1, 2015 at 10:27:14 AM UTC-5, Steve Burrus wrote:
>
> I need some help please with  tryiong to start a new Django project. Here 
> is the error message I always get when I try to do this. can someone help 
> me with this?
>   
> "C:\Users\SteveB\Desktop\steve>.\Scripts\activate
> (steve) C:\Users\SteveB\Desktop\steve>python .\Scripts\django-admin.py 
> startproject proj
> python: can't open file '.\Scripts\django-admin.py': [Errno 2] No such 
> file or directory"
>
>
>
>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/db741397-9c7c-4368-805c-07d60d6042bf%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Can't Start Project.

2015-07-01 Thread Steve Burrus
I need some help please with  tryiong to start a new Django project. Here 
is the error message I always get when I try to do this. can someone help 
me with this?
  
"C:\Users\SteveB\Desktop\steve>.\Scripts\activate
(steve) C:\Users\SteveB\Desktop\steve>python .\Scripts\django-admin.py 
startproject proj
python: can't open file '.\Scripts\django-admin.py': [Errno 2] No such file 
or directory"



-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/77455e4f-a8de-42c2-93fa-8c1f04a74ef4%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: How To Activate Django Server.

2015-06-26 Thread Steve Burrus
we;ll here is the error message that I get when I try to install django in
the virtual env. :
"C:\Users\SteveB\Desktop\myenv>.\Scripts\activate
(myenv) C:\Users\SteveB\Desktop\myenv>pip install django
Fatal error in launcher: Job information querying failed"
What's the problem anyway?



On Fri, Jun 26, 2015 at 5:49 PM, Javier Guerra Giraldez <jav...@guerrag.com>
wrote:

> On Fri, Jun 26, 2015 at 4:56 PM, Steve Burrus <steveburru...@gmail.com>
> wrote:
> > I AM able to create a new virtual env. but I gfet this error message
> when I
> > try to create a new project!
>
>
> have you installed django in this virtualenv?
>
> --
> Javier
>
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "Django users" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/django-users/W_41qowiu8k/unsubscribe.
> To unsubscribe from this group and all its topics, 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.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/CAFkDaoTqQ26wA9up0mTA1Y0A7UHKC-cKWXwBCA%3DBAoUscSTRCw%40mail.gmail.com
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CABcoaSDu0MfXm%2BUHheYOZNEAi0BnL7S%3Dcyd0zCd211TMh0Twbg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: How To Activate Django Server.

2015-06-26 Thread Steve Burrus
I AM able to create a new virtual env. but I gfet this error message when I 
try to create a new project! Do i possibly have to start the DjANgo server 
first then try to create the new project? It's so dumb that I very recently 
knew how to do all of this fairly easily but not now. What am I doing wrong 
anyway?
 
"(myenv) C:\Users\SteveB\Desktop\myenv>python .\Scripts\django-admin 
startproject myproj
python: can't open file '.\Scripts\django-admin': [Errno 2] No such file or 
directory"




>
>
>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/28ca5ec4-ca2f-40f1-b115-6dcc086a34b2%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: How To Activate Django Server.

2015-06-25 Thread Steve Burrus
No i am sorry but python manage.py runserver doesn't work! I first tried to
run it in a newly created virtual environment, it failed. so I just tried
to run it in the Desktop folder but it still failed. I remember a command
which had in it "django-admin.py" that I need to type right?

 "C:\Users\SteveB\Desktop>python manage.py runserver
python: can't open file 'manage.py': [Errno 2] No such file or directory"



On Thu, Jun 25, 2015 at 12:00 PM, <ybdra...@gmail.com> wrote:

>  On 06/25/15 18:07, Steve Burrus wrote:
>
> I am sorry that I hjave to ask about this, since I was recently able to do
> it, but I have to ask how do I go about going from successfully creating a
> new virtual environment to then being able to connect to the Django server?
> I have seen countless videos, on youtube, on how this is done but I simply
>  forgot.
>
>
>   python manage.py runserver
>
> dragon
>
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "Django users" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/django-users/W_41qowiu8k/unsubscribe.
> To unsubscribe from this group and all its topics, 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.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/558C33B3.7030700%40gmail.com
> <https://groups.google.com/d/msgid/django-users/558C33B3.7030700%40gmail.com?utm_medium=email_source=footer>
> .
>
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CABcoaSDK8Oc_8A6AGRMgDZX4ZVg6FeSCePGbo5YgNmrYCMiQiA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


How To Activate Django Server.

2015-06-25 Thread Steve Burrus
I am sorry that I hjave to ask about this, since I was recently able to do 
it, but I have to ask how do I go about going from successfully creating a 
new virtual environment to then being able to connect to the Django server? 
I have seen countless videos, on youtube, on how this is done but I simply 
 forgot.



-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/faf49754-69a1-45d2-a9d4-47aa610209f0%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: how to get get-pip.py

2015-06-05 Thread Steve Burrus
*to everyone concerned : It's all goo d now! I  not only got pip installed
I also managed to upgrade it and got django going, and connected to the
Server, synched my new database. So  that is just about all the help which
I require for now.*


*On Fri, Jun 5, 2015 at 9:10 PM, dvdhbs <dvd...@gmail.com
<dvd...@gmail.com>> wrote:*
>
>
>
>
>
>
>
>
>
>
>
> *Steve,Try this at a command prompt:py -3.4 -m pip install --upgrade
> pipYou can't upgrade pip using pip directly on Windows.Best,Dave*
>
>
>
>
>
>
>
> * -- You received this message because you are subscribed to a topic in
> the Google Groups "Django users" group. To unsubscribe from this topic,
> visit
> https://groups.google.com/d/topic/django-users/tKJTNAq4sS4/unsubscribe
> <https://groups.google.com/d/topic/django-users/tKJTNAq4sS4/unsubscribe>.
> To unsubscribe from this group and all its topics, send an email to
> django-users+unsubscr...@googlegroups.com
> <django-users+unsubscr...@googlegroups.com>. To post to this group, send
> email to django-users@googlegroups.com <django-users@googlegroups.com>.
> Visit this group at http://groups.google.com/group/django-users
> <http://groups.google.com/group/django-users>. To view this discussion on
> the web visit
> https://groups.google.com/d/msgid/django-users/81822987-48c2-439d-bf68-cfe7cbd5a516%40googlegroups.com
> <https://groups.google.com/d/msgid/django-users/81822987-48c2-439d-bf68-cfe7cbd5a516%40googlegroups.com?utm_medium=email_source=footer>.*
>
>
> * For more options, visit https://groups.google.com/d/optout
> <https://groups.google.com/d/optout>. *
>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CABcoaSC5TzZsmbOXLQ6b%2ByXGsqhW9J%3D%2B%3D%2BOAfwmTE3zMgp-unw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: how to get get-pip.py

2015-06-05 Thread Steve Burrus
oh I thought tha t I told you thsat I *was *able to make python/pip work!
It's just this little thing about not being able to upgrade pip which
bothers me, just a little bit. and I am not trying to run pip with any
other User other than myself.

On Fri, Jun 5, 2015 at 1:50 PM, Gergely Polonkai <gerg...@polonkai.eu>
wrote:

> It seems the very first thing you should do is make pip (and with that,
> Python) work. For this, you may want to go to a Python related mailing
> list, although I’m sure there are many overlapping between the Django list
> and that one.
>
> 2015-06-05 20:05 GMT+02:00 Steve Burrus <steveburru...@gmail.com>:
>
>> well tqhat's okay. I was absolutely struggling to get pip installed
>> correctly for quite a long time! I need to see more videos on how to start
>> to work with Django. You have any tips about t hat?
>>
>> On Fri, Jun 5, 2015 at 12:43 PM, DHaval Joshi <dreamerd...@gmail.com>
>> wrote:
>>
>>> sry dear i don't know about windows installation.
>>>
>>> On Fri, Jun 5, 2015 at 10:20 PM, Gergely Polonkai <gerg...@polonkai.eu>
>>> wrote:
>>>
>>>> Hello,
>>>>
>>>> it seems that the user running pip doesn’t have write access to the
>>>> temp directory. You should check the permissions of
>>>> C:\Users\SteveB\AppData\Local\Temp and its subdirectories as you can see in
>>>> the PermissionError line (just change the double backslashes (\\) to single
>>>> ones (\).
>>>>
>>>> Is it possible that you run pip with a user other than the one you used
>>>> to install Python?
>>>>
>>>> Best,
>>>> Gergely
>>>>
>>>> 2015-06-05 18:41 GMT+02:00 Steve Burrus <steveburru...@gmail.com>:
>>>>
>>>>> well moknte I got good/bad news for you! The GOOD news is that I
>>>>> finally got pip installed successfully but the BAD news is that I wasn't
>>>>> able to upgrade pip. Here is the resulting error when I tried to do that :
>>>>>
>>>>> "C:\Users\SteveB>pip install --upgrade pip
>>>>> You are using pip version 6.0.8, however version 7.0.3 is available.
>>>>> You should consider upgrading via the 'pip install --upgrade pip'
>>>>> command.
>>>>> Collecting pip from
>>>>> https://pypi.python.org/packages/py2.py3/p/pip/pip-7.0.3-py2.py3-none-any.whl#md5=6950e1d775fea7ea50af690f72589dbd
>>>>>   Using cached pip-7.0.3-py2.py3-none-any.whl
>>>>> Installing collected packages: pip
>>>>>   Found existing installation: pip 6.0.8
>>>>> Uninstalling pip-6.0.8:
>>>>>   Successfully uninstalled pip-6.0.8
>>>>>   Exception:
>>>>>   Traceback (most recent call last):
>>>>> File "C:\Python34\lib\shutil.py", line 371, in
>>>>> _rmtree_unsafe os.unlink(fullname)
>>>>>   PermissionError: [WinError 5] Access is denied:
>>>>> 'C:\\Users\\SteveB\\AppData\\Local\\Temp\\pip-xfly9791-uninstall\\python34\\scripts\\pip.exe'
>>>>>
>>>>>   During handling of the above exception, another exception occurred:
>>>>>
>>>>>   Traceback (most recent call last):
>>>>> File "C:\Python34\lib\site-packages\pip\basecommand.py", line 232,
>>>>> in main
>>>>>   return PREVIOUS_BUILD_DIR_ERROR
>>>>> File "C:\Python34\lib\site-packages\pip\commands\install.py", line
>>>>> 347, in run
>>>>>   if os.path.islink(target_item_dir):
>>>>> File "C:\Python34\lib\site-packages\pip\req\req_set.py", line 560,
>>>>> in install
>>>>>   self.successfully_downloaded.append(req_to_install)
>>>>> File "C:\Python34\lib\site-packages\pip\req\req_install.py", line
>>>>> 680, in commit_uninstall
>>>>> File "C:\Python34\lib\site-packages\pip\req\req_uninstall.py",
>>>>> line 153, in commit
>>>>>   rmtree(self.save_dir)
>>>>> File "C:\Python34\lib\site-packages\pip\_vendor\retrying.py", line
>>>>> 49, in wrapped_f
>>>>>   return Retrying(*dargs, **dkw).call(f, *args, **kw)
>>>>> File "C:\Python34\lib\site-packages\pip\_vendor\retrying.py", line
>>>>> 212, in call
>>>>>   raise attempt.get()
>>>>> File &q

Re: how to get get-pip.py

2015-06-05 Thread Steve Burrus
well tqhat's okay. I was absolutely struggling to get pip installed
correctly for quite a long time! I need to see more videos on how to start
to work with Django. You have any tips about t hat?

On Fri, Jun 5, 2015 at 12:43 PM, DHaval Joshi <dreamerd...@gmail.com> wrote:

> sry dear i don't know about windows installation.
>
> On Fri, Jun 5, 2015 at 10:20 PM, Gergely Polonkai <gerg...@polonkai.eu>
> wrote:
>
>> Hello,
>>
>> it seems that the user running pip doesn’t have write access to the temp
>> directory. You should check the permissions of
>> C:\Users\SteveB\AppData\Local\Temp and its subdirectories as you can see in
>> the PermissionError line (just change the double backslashes (\\) to single
>> ones (\).
>>
>> Is it possible that you run pip with a user other than the one you used
>> to install Python?
>>
>> Best,
>> Gergely
>>
>> 2015-06-05 18:41 GMT+02:00 Steve Burrus <steveburru...@gmail.com>:
>>
>>> well moknte I got good/bad news for you! The GOOD news is that I finally
>>> got pip installed successfully but the BAD news is that I wasn't able to
>>> upgrade pip. Here is the resulting error when I tried to do that :
>>>
>>> "C:\Users\SteveB>pip install --upgrade pip
>>> You are using pip version 6.0.8, however version 7.0.3 is available.
>>> You should consider upgrading via the 'pip install --upgrade pip'
>>> command.
>>> Collecting pip from
>>> https://pypi.python.org/packages/py2.py3/p/pip/pip-7.0.3-py2.py3-none-any.whl#md5=6950e1d775fea7ea50af690f72589dbd
>>>   Using cached pip-7.0.3-py2.py3-none-any.whl
>>> Installing collected packages: pip
>>>   Found existing installation: pip 6.0.8
>>> Uninstalling pip-6.0.8:
>>>   Successfully uninstalled pip-6.0.8
>>>   Exception:
>>>   Traceback (most recent call last):
>>> File "C:\Python34\lib\shutil.py", line 371, in
>>> _rmtree_unsafe os.unlink(fullname)
>>>   PermissionError: [WinError 5] Access is denied:
>>> 'C:\\Users\\SteveB\\AppData\\Local\\Temp\\pip-xfly9791-uninstall\\python34\\scripts\\pip.exe'
>>>
>>>   During handling of the above exception, another exception occurred:
>>>
>>>   Traceback (most recent call last):
>>> File "C:\Python34\lib\site-packages\pip\basecommand.py", line 232,
>>> in main
>>>   return PREVIOUS_BUILD_DIR_ERROR
>>> File "C:\Python34\lib\site-packages\pip\commands\install.py", line
>>> 347, in run
>>>   if os.path.islink(target_item_dir):
>>> File "C:\Python34\lib\site-packages\pip\req\req_set.py", line 560,
>>> in install
>>>   self.successfully_downloaded.append(req_to_install)
>>> File "C:\Python34\lib\site-packages\pip\req\req_install.py", line
>>> 680, in commit_uninstall
>>> File "C:\Python34\lib\site-packages\pip\req\req_uninstall.py", line
>>> 153, in commit
>>>   rmtree(self.save_dir)
>>> File "C:\Python34\lib\site-packages\pip\_vendor\retrying.py", line
>>> 49, in wrapped_f
>>>   return Retrying(*dargs, **dkw).call(f, *args, **kw)
>>> File "C:\Python34\lib\site-packages\pip\_vendor\retrying.py", line
>>> 212, in call
>>>   raise attempt.get()
>>> File "C:\Python34\lib\site-packages\pip\_vendor\retrying.py", line
>>> 247, in get
>>>   six.reraise(self.value[0], self.value[1], self.value[2])
>>> File "C:\Python34\lib\site-packages\pip\_vendor\six.py", line 659,
>>> in reraise
>>>   raise value
>>> File "C:\Python34\lib\site-packages\pip\_vendor\retrying.py", line
>>> 200, in call
>>>   attempt = Attempt(fn(*args, **kwargs), attempt_number, False)
>>> File "C:\Python34\lib\site-packages\pip\utils\__init__.py", line 61,
>>> in rmtree
>>>   try:
>>> File "C:\Python34\lib\shutil.py", line 478, in rmtree
>>>   return _rmtree_unsafe(path, onerror)
>>> File "C:\Python34\lib\shutil.py", line 368, in _rmtree_unsafe
>>>   _rmtree_unsafe(fullname, onerror)
>>> File "C:\Python34\lib\shutil.py", line 368, in _rmtree_unsafe
>>>   _rmtree_unsafe(fullname, onerror)
>>> File "C:\Python34\lib\shutil.py", line 373, in _rmtree_unsafe
>>>   onerror(os.unlink, fullname, sys.exc_info())
>>> File "C:\Python34\lib\si

Re: how to get get-pip.py

2015-06-05 Thread Steve Burrus
well moknte I got good/bad news for you! The GOOD news is that I finally
got pip installed successfully but the BAD news is that I wasn't able to
upgrade pip. Here is the resulting error when I tried to do that :

"C:\Users\SteveB>pip install --upgrade pip
You are using pip version 6.0.8, however version 7.0.3 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
Collecting pip from
https://pypi.python.org/packages/py2.py3/p/pip/pip-7.0.3-py2.py3-none-any.whl#md5=6950e1d775fea7ea50af690f72589dbd
  Using cached pip-7.0.3-py2.py3-none-any.whl
Installing collected packages: pip
  Found existing installation: pip 6.0.8
Uninstalling pip-6.0.8:
  Successfully uninstalled pip-6.0.8
  Exception:
  Traceback (most recent call last):
File "C:\Python34\lib\shutil.py", line 371, in _rmtree_unsafe
os.unlink(fullname)
  PermissionError: [WinError 5] Access is denied:
'C:\\Users\\SteveB\\AppData\\Local\\Temp\\pip-xfly9791-uninstall\\python34\\scripts\\pip.exe'

  During handling of the above exception, another exception occurred:

  Traceback (most recent call last):
File "C:\Python34\lib\site-packages\pip\basecommand.py", line 232, in
main
  return PREVIOUS_BUILD_DIR_ERROR
File "C:\Python34\lib\site-packages\pip\commands\install.py", line 347,
in run
  if os.path.islink(target_item_dir):
File "C:\Python34\lib\site-packages\pip\req\req_set.py", line 560, in
install
  self.successfully_downloaded.append(req_to_install)
File "C:\Python34\lib\site-packages\pip\req\req_install.py", line 680,
in commit_uninstall
File "C:\Python34\lib\site-packages\pip\req\req_uninstall.py", line
153, in commit
  rmtree(self.save_dir)
File "C:\Python34\lib\site-packages\pip\_vendor\retrying.py", line 49,
in wrapped_f
  return Retrying(*dargs, **dkw).call(f, *args, **kw)
File "C:\Python34\lib\site-packages\pip\_vendor\retrying.py", line 212,
in call
  raise attempt.get()
File "C:\Python34\lib\site-packages\pip\_vendor\retrying.py", line 247,
in get
  six.reraise(self.value[0], self.value[1], self.value[2])
File "C:\Python34\lib\site-packages\pip\_vendor\six.py", line 659, in
reraise
  raise value
File "C:\Python34\lib\site-packages\pip\_vendor\retrying.py", line 200,
in call
  attempt = Attempt(fn(*args, **kwargs), attempt_number, False)
File "C:\Python34\lib\site-packages\pip\utils\__init__.py", line 61, in
rmtree
  try:
File "C:\Python34\lib\shutil.py", line 478, in rmtree
  return _rmtree_unsafe(path, onerror)
File "C:\Python34\lib\shutil.py", line 368, in _rmtree_unsafe
  _rmtree_unsafe(fullname, onerror)
File "C:\Python34\lib\shutil.py", line 368, in _rmtree_unsafe
  _rmtree_unsafe(fullname, onerror)
File "C:\Python34\lib\shutil.py", line 373, in _rmtree_unsafe
  onerror(os.unlink, fullname, sys.exc_info())
File "C:\Python34\lib\site-packages\pip\utils\__init__.py", line 73, in
rmtree_errorhandler
  raise
  PermissionError: [WinError 5] Access is denied:
'C:\\Users\\SteveB\\AppData\\Local\\Temp\\pip-xfly9791-uninstall\\python34\\scripts\\pip.exe'
"

Now what's wrong?

On Fri, Jun 5, 2015 at 10:51 AM, Steve Burrus <steveburru...@gmail.com>
wrote:

> Okay Monte I will certsainly "man up" and start over and try to do what
> you said. Incidentally I have done the "Add python.exe to the PATH" thing
> that you suggested but it still failed! I have done all of the
> configuration the right way but I still simply cannot type "pip" [into the
> command line] and get all of the pip commands.
>
> On Thursday, June 4, 2015 at 10:30:36 PM UTC-5, Monte Milanuk wrote:
>>
>> Stop.
>>
>> Uninstall python (whatever version(s) you have).
>>
>> Re-install python (3.4.3), but this time when you get to the screen
>> telling you what all is going to be installed, scroll down and enable
>> the last item "Add python.exe to the PATH".
>>
>> Python commands (including pip) should work from the command line with
>> no problem.  I did *exactly* this as a test this afternoon, and told you
>> so earlier. Quit flailing about and start over.
>>
>>
>>
>>
>>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CABcoaSATZOdDeEpuK0ghOH%2BgPR4BtH%3DVOuQqwqktF2TdVd_XWw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: how to get get-pip.py

2015-06-05 Thread Steve Burrus
Okay Monte I will certsainly "man up" and start over and try to do what you 
said. Incidentally I have done the "Add python.exe to the PATH" thing that 
you suggested but it still failed! I have done all of the configuration the 
right way but I still simply cannot type "pip" [into the command line] and 
get all of the pip commands.

On Thursday, June 4, 2015 at 10:30:36 PM UTC-5, Monte Milanuk wrote:
>
> Stop. 
>
> Uninstall python (whatever version(s) you have). 
>
> Re-install python (3.4.3), but this time when you get to the screen 
> telling you what all is going to be installed, scroll down and enable 
> the last item "Add python.exe to the PATH". 
>
> Python commands (including pip) should work from the command line with 
> no problem.  I did *exactly* this as a test this afternoon, and told you 
> so earlier. Quit flailing about and start over. 
>
>
>
>
>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/efc089d1-6e9c-48a8-a7c3-4cca3bdbec32%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: how to get get-pip.py

2015-06-04 Thread Steve Burrus
*well I mdid exactly what you instructed but it still didn't work! Here is
the error mesg. that I got : "*
*c:\Users\SteveB\Desktop>pip install virtualenv *
*Fatal error in launcher: Job information querying failed".*


*On Thu, Jun 4, 2015 at 8:00 PM, Michael Manfre <mman...@gmail.com
<mman...@gmail.com>> wrote:*
>
>
>
>
>
> *On Thu, Jun 4, 2015 at 7:15 PM, Steve Burrus <steveburru...@gmail.com
> <steveburru...@gmail.com>> wrote:when I try to run Python it comes for me
> normally! [ No problem ] I not heard yet about a pip.exe file. Just where
> is that contained in the Python ins tallation anyway? I  will try that "pip
> install virtualenv" soon.*
> *C:\Python34\Scripts\pip.exe*
>
> *I recommend adding C:\Python34\Scripts to your path right after the
> C:\Python34 folder (each path should be separated by a semicolon)*
>
> *Regards,*
> *Michael Manfre*
>
>
>
>
>
>
>
> * -- You received this message because you are subscribed to a topic in
> the Google Groups "Django users" group. To unsubscribe from this topic,
> visit
> https://groups.google.com/d/topic/django-users/tKJTNAq4sS4/unsubscribe
> <https://groups.google.com/d/topic/django-users/tKJTNAq4sS4/unsubscribe>.
> To unsubscribe from this group and all its topics, send an email to
> django-users+unsubscr...@googlegroups.com
> <django-users+unsubscr...@googlegroups.com>. To post to this group, send
> email to django-users@googlegroups.com <django-users@googlegroups.com>.
> Visit this group at http://groups.google.com/group/django-users
> <http://groups.google.com/group/django-users>. To view this discussion on
> the web visit
> https://groups.google.com/d/msgid/django-users/CAGdCwBuCETybj7AQ0U%3D_0SgHf_ah7CymZpBegnFF3gLdivJkYQ%40mail.gmail.com
> <https://groups.google.com/d/msgid/django-users/CAGdCwBuCETybj7AQ0U%3D_0SgHf_ah7CymZpBegnFF3gLdivJkYQ%40mail.gmail.com?utm_medium=email_source=footer>.*
>
>
> * For more options, visit https://groups.google.com/d/optout
> <https://groups.google.com/d/optout>. *
>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CABcoaSBzQoVr_8Bv%3D5HCiAHg3kz8b0X9M720TN_3OG1eCanNEA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: how to get get-pip.py

2015-06-04 Thread Steve Burrus
when I try to run Python it comes for me normally! [ No problem ] I not
heard yet about a pip.exe file. Just where is that contained in the Python
ins tallation anyway? I  will try that "pip install virtualenv" soon.

On Thu, Jun 4, 2015 at 3:52 PM, Alon Nisser <alonis...@gmail.com> wrote:

> 1. Please, This is an open source community, with people answering
> questions here on their free time (no one here is getting payed to answer).
>  so no need for the BOLD Frustrated type.
>
> 2. Specifying you are on windows from the beginning would help, Lots of us
> are using different flavors of windows.
>
> 3. The error you are getting is proving that the path etc isn't set up
> correctly to support python install , shoot up a terminal and type python
> and hit enter - do you get a running python interpreter or the same error
> as pip? are the folders where python.exe and pip.exe are added to your
> windows path? (you can check where the binaries are with your favorite file
> explorer tool)  if not , you should add them. if they are did you add them
> to the path while the terminal you are using now was already active? if so
> you should try from another terminal ('cmd') instance
>
> 4. A final advice on python environments - make it a habit to use
> virtualenv (pip install virtualenv) and don't use global installs of
> packages
>
> Good luck!
>
> On Thursday, June 4, 2015 at 9:53:36 PM UTC+3, Steve Burrus wrote:
>>
>>
>> *"Which version of Python did you install?" well up until last nite I was
>> using some flavor of Python 3.5. But someone suggested that I get the 3.4
>> version of it so I did. I have all of the environment varianbles set
>> correctly. I did the ez_install.py thing right. And you would think that I
>> could easily do the "pip install django" ri ght but it fails.*
>>
>>
>> *On Thu, Jun 4, 2015 at 1:37 PM, Michael Manfre <mma...@gmail.com> wrote:*
>>
>>> *"sudo apt-get install ..." is a command that works on Ubuntu and a few
>>> other flavors of linux. It does not work on Windows.*
>>>
>>>
>>> *Which version of Python did you install? If it's Python 3.4 or newer,
>>> pip is bundled. Python 3.4 is installed to "C:\Python34\" as the
>>> default. To use pip, you would execute "C:\Python34\python -m pip install
>>> PACKAGE_NAME" without the surrounding quotes. *
>>> *To avoid having to type the full path all the time, you will need to
>>> add it to your path. Please read
>>> https://docs.python.org/3.4/using/windows.html#excursus-setting-environment-variables
>>> <https://docs.python.org/3.4/using/windows.html#excursus-setting-environment-variables>*
>>>
>>>
>>> *If you are using a version of Python earlier than 3.4, follow the
>>> instructions found at https://pip.pypa.io/en/latest/installing.html
>>> <https://pip.pypa.io/en/latest/installing.html>*
>>>
>>> *Regards,*
>>>
>>>
>>> *Michael ManfreOn Thursday, June 4, 2015 at 1:33:47 PM UTC-4, Steve
>>> Burrus wrote:*
>>>>
>>>> *I am sorry Dhavi but your command didmn't work! Now I don't think you
>>>> know  that I am on a Windows system and that "sudo" command do esn't work
>>>> on windows. Any other ideas for me? *
>>>>
>>>>
>>>> *On Thu, Jun 4, 2015 at 3:04 AM, DHaval Joshi <dream...@gmail.com>
>>>> wrote:*
>>>>>
>>>>>
>>>>>
>>>>> *try this sudo apt-get install python-pip*
>>>>>
>>>>>
>>>>>
>>>>> *On Thu, Jun 4, 2015 at 8:54 AM, Steve Burrus <steveb...@gmail.com>
>>>>> wrote:*
>>>>>
>>>>>> *Well Mikea I hardly did it the first time that I  tried but I was
>>>>>> able to get Python 3.4 installed ! And I also got that ez-setup installed
>>>>>> okay. But where do I go from here to get pip going okay?  incidentally I
>>>>>> tried doing step 5 "C:\users\steve\pip install django" but that didn't
>>>>>> work! There must be another path to the django install.*
>>>>>>
>>>>>> *
>>>>>>Steve Burrus  *
>>>>>>
>>>>>>
>>>>>> *On Wed, Jun 3, 2015 at 9:04 PM, Mike Dewhirst
>>>>>> <mi...@dewhirst.com.au> wrote:*
>>>>>>
>>>>>>>
>>>>>>>
>>>>&g

Re: how to get get-pip.py

2015-06-04 Thread Steve Burrus
it seems like I haVE also seen someone say I should put, into the System
path, the Python Lib\site-packages\django\bin or sometjhing like that.

On Thu, Jun 4, 2015 at 4:01 PM, memilanuk <memila...@gmail.com> wrote:

> On 06/04/2015 01:43 PM, Steve Burrus wrote:
>
>> but which Path should I use in Env. Variables, the one in "Users" or the
>> one below in "System", to set
>> the correct path with Python? I have seen conflicting tutorials which
>> have said to use one or the other.
>>
>>
> Like I said... the simplest way to get it right would be to uninstall, and
> let the installer do it for you.
>
> Otherwise... I've always used the System path, and it looks like the
> Python 3.4.3 installer used the same approach: it pre-pended
> 'C:\Python34\;C:\Python34\Scripts;' (without the quotes) to the System path.
>
>
> --
> Shiny!  Let's be bad guys.
>
> Reach me @ memilanuk (at) gmail dot com
>
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "Django users" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/django-users/tKJTNAq4sS4/unsubscribe.
> To unsubscribe from this group and all its topics, 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.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/mkqeae%24sb4%241%40ger.gmane.org
> .
>
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CABcoaSA%2BjeTf2%2BiCCEo-U%3DGgDoieLCwibyN2cmVcTuOQcQdd7w%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: how to get get-pip.py

2015-06-04 Thread Steve Burrus
sorry monte for the "inane" quesation but which Path should I use in Env.
Variables, the one in "Users" or the one below in "System", to set the
correct path with Python? I have seen conflicting tutorials which have said
to use one or the other.


  Steve

On Thu, Jun 4, 2015 at 3:20 PM, memilanuk <memila...@gmail.com> wrote:

> On 06/04/2015 11:53 AM, Steve Burrus wrote:
>
>> *"Which version of Python did you install?" well up until last nite I
>> was using some flavor of Python 3.5. But someone suggested that I get
>> the 3.4 version of it so I did. I have _all _of the environment
>> varianbles set correctly. I did the ez_install.py thing right. And you
>> would think that I could easily do the "pip install django" ri ght but
>> it fails.
>>
> An observation... why are you trying to use python 3.5?  You do realize
> that its not been fully released yet... right?
> If you don't know that, or don't know that pip comes already installed in
> python 3.4.x and later, or how to set your PATH... you really, really don't
> need to be running a beta or release candidate version of python.  For
> anything.
>
> Stick with the latest released version, which is currently 3.4.3 - and
> comes with pip already installed.  There are seven 'options' to the
> install, six of which are done for you by default.  The last - 'Add
> python.exe to your PATH' - should make 'pip' work straight from the command
> line.  Uninstall, re-install, check that option and move on.  I just did it
> in a Windows 7 VM - works fine.
>
> A side note... lay off the large bold font - it makes your posts to the
> list somewhat obnoxious to read.  And try trimming your replies - and/or
> not top-posting.
>
>
> Monte
>
>
>
>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CABcoaSChDncjUf18-AHdFT9cUjK1FVDVqYNFQNMmQFtSUN4ZuQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: how to get get-pip.py

2015-06-04 Thread Steve Burrus
*"Which version of Python did you install?" well up until last nite I was
using some flavor of Python 3.5. But someone suggested that I get the 3.4
version of it so I did. I have all of the environment varianbles set
correctly. I did the ez_install.py thing right. And you would think that I
could easily do the "pip install django" ri ght but it fails.*


*On Thu, Jun 4, 2015 at 1:37 PM, Michael Manfre <mman...@gmail.com
<mman...@gmail.com>> wrote:*
>
> *"sudo apt-get install ..." is a command that works on Ubuntu and a few
> other flavors of linux. It does not work on Windows.*
>
>
> *Which version of Python did you install? If it's Python 3.4 or newer, pip
> is bundled. Python 3.4 is installed to "C:\Python34\" as the default. To
> use pip, you would execute "C:\Python34\python -m pip install PACKAGE_NAME"
> without the surrounding quotes. *
> *To avoid having to type the full path all the time, you will need to add
> it to your path. Please read
> https://docs.python.org/3.4/using/windows.html#excursus-setting-environment-variables
> <https://docs.python.org/3.4/using/windows.html#excursus-setting-environment-variables>*
>
>
> *If you are using a version of Python earlier than 3.4, follow the
> instructions found at https://pip.pypa.io/en/latest/installing.html
> <https://pip.pypa.io/en/latest/installing.html>*
>
> *Regards,*
>
>
> *Michael ManfreOn Thursday, June 4, 2015 at 1:33:47 PM UTC-4, Steve Burrus
> wrote:*
>>
>> *I am sorry Dhavi but your command didmn't work! Now I don't think you
>> know  that I am on a Windows system and that "sudo" command do esn't work
>> on windows. Any other ideas for me? *
>>
>>
>> *On Thu, Jun 4, 2015 at 3:04 AM, DHaval Joshi <dream...@gmail.com> wrote:*
>>>
>>>
>>>
>>> *try this sudo apt-get install python-pip*
>>>
>>>
>>>
>>> *On Thu, Jun 4, 2015 at 8:54 AM, Steve Burrus <steveb...@gmail.com>
>>> wrote:*
>>>
>>>> *Well Mikea I hardly did it the first time that I  tried but I was able
>>>> to get Python 3.4 installed ! And I also got that ez-setup installed okay.
>>>> But where do I go from here to get pip going okay?  incidentally I tried
>>>> doing step 5 "C:\users\steve\pip install django" but that didn't work!
>>>> There must be another path to the django install.*
>>>>
>>>> *
>>>>  Steve Burrus  *
>>>>
>>>>
>>>> *On Wed, Jun 3, 2015 at 9:04 PM, Mike Dewhirst <mi...@dewhirst.com.au>
>>>> wrote:*
>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>> *Sorry Steve I didn't realise you needed help to get Django installed.
>>>>> You said you were having a problem with pip. Generally the best way to get
>>>>> help is to explain exactly what you have done and detail the error 
>>>>> messages
>>>>> generated. Putting your message in bold doesn't help. I just checked my
>>>>> sent messages and see that I replied to you a couple of days ago at which
>>>>> time you said you had Django working. I can understand that you are having
>>>>> problems in a Windows environment because I am forced to use it myself and
>>>>> I too have to cope with its idiosyncrasies. I didn't know there is a
>>>>> Windows version 10 and I see from Tuesday's post you say it is a beta
>>>>> version. If you have no other choice of platform you should expect a beta
>>>>> version of any operating system to have problems which the supplier really
>>>>> wants to hear about so they can sort it out. So, to help Microsoft out I
>>>>> suggest the following: 1. Uninstall Django and Python 2. Install Python 
>>>>> 3.4
>>>>> for Windows (3.5 is quite new) exactly as described on the Python website.
>>>>> 3. Fully document

Re: how to get get-pip.py

2015-06-04 Thread Steve Burrus
*I am sorry Dhavi but your command didmn't work! Now I don't think you know
 that I am on a Windows system and that "sudo" command do esn't work on
windows. Any other ideas for me? *


*On Thu, Jun 4, 2015 at 3:04 AM, DHaval Joshi <dreamerd...@gmail.com
<dreamerd...@gmail.com>> wrote:*
>
>
>
> *try this sudo apt-get install python-pip*
>
>
>
> *On Thu, Jun 4, 2015 at 8:54 AM, Steve Burrus <steveburru...@gmail.com
> <steveburru...@gmail.com>> wrote:*
>
>> *Well Mikea I hardly did it the first time that I  tried but I was able
>> to get Python 3.4 installed ! And I also got that ez-setup installed okay.
>> But where do I go from here to get pip going okay?  incidentally I tried
>> doing step 5 "C:\users\steve\pip install django" but that didn't work!
>> There must be another path to the django install.*
>>
>> *
>>Steve Burrus  *
>>
>>
>> *On Wed, Jun 3, 2015 at 9:04 PM, Mike Dewhirst <mi...@dewhirst.com.au
>> <mi...@dewhirst.com.au>> wrote:*
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>> *Sorry Steve I didn't realise you needed help to get Django installed.
>>> You said you were having a problem with pip. Generally the best way to get
>>> help is to explain exactly what you have done and detail the error messages
>>> generated. Putting your message in bold doesn't help. I just checked my
>>> sent messages and see that I replied to you a couple of days ago at which
>>> time you said you had Django working. I can understand that you are having
>>> problems in a Windows environment because I am forced to use it myself and
>>> I too have to cope with its idiosyncrasies. I didn't know there is a
>>> Windows version 10 and I see from Tuesday's post you say it is a beta
>>> version. If you have no other choice of platform you should expect a beta
>>> version of any operating system to have problems which the supplier really
>>> wants to hear about so they can sort it out. So, to help Microsoft out I
>>> suggest the following: 1. Uninstall Django and Python 2. Install Python 3.4
>>> for Windows (3.5 is quite new) exactly as described on the Python website.
>>> 3. Fully document any errors encountered 4. Report such errors to Microsoft
>>> if any 5. If there were no errors installing Python 3.4 and you are able to
>>> get a non-Supervisor command prompt running, then install Django like this:
>>> C:\users\steve\pip install django 6. If you encounter any problems at all
>>> you must let Microsoft know because they will want to fix it. Mike On
>>> 4/06/2015 11:16 AM, Steve Burrus wrote: *
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>> * *"you should use Python >= 3.4" I rerpeatedly use version 3.5 of
>>>> Python! I have looked at many of these tutorial videos, via youtube, on how
>>>> to set up Django but I_still _get that error msg. when I try to type in
>>>> "pip" after I think I haVE successfully installed it!* * * *Â  Â  Â  Â  Â
>>>> Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â Â  Â  Â  Â  Â  Â
>>>>                                Steve B. * * * *On Wed, Jun
>>>> 3, 2015 at 8:04 PM, Mike Dewhirst <mi...@dewhirst.com.au
>>>> <mi...@dewhirst.com.au> <mailto:mi...@dewhirst.com.au
>>>> <mi...@dewhirst.com.au>>> wrote: * *On

Re: how to get get-pip.py

2015-06-03 Thread Steve Burrus
*Well Mikea I hardly did it the first time that I  tried but I was able to
get Python 3.4 installed ! And I also got that ez-setup installed okay. But
where do I go from here to get pip going okay?  incidentally I tried doing
step 5 "C:\users\steve\pip install django" but that didn't work! There must
be another path to the django install.*

*
     Steve Burrus  *


*On Wed, Jun 3, 2015 at 9:04 PM, Mike Dewhirst <mi...@dewhirst.com.au
<mi...@dewhirst.com.au>> wrote:*
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
> *Sorry Steve I didn't realise you needed help to get Django installed. You
> said you were having a problem with pip. Generally the best way to get help
> is to explain exactly what you have done and detail the error messages
> generated. Putting your message in bold doesn't help. I just checked my
> sent messages and see that I replied to you a couple of days ago at which
> time you said you had Django working. I can understand that you are having
> problems in a Windows environment because I am forced to use it myself and
> I too have to cope with its idiosyncrasies. I didn't know there is a
> Windows version 10 and I see from Tuesday's post you say it is a beta
> version. If you have no other choice of platform you should expect a beta
> version of any operating system to have problems which the supplier really
> wants to hear about so they can sort it out. So, to help Microsoft out I
> suggest the following: 1. Uninstall Django and Python 2. Install Python 3.4
> for Windows (3.5 is quite new) exactly as described on the Python website.
> 3. Fully document any errors encountered 4. Report such errors to Microsoft
> if any 5. If there were no errors installing Python 3.4 and you are able to
> get a non-Supervisor command prompt running, then install Django like this:
> C:\users\steve\pip install django 6. If you encounter any problems at all
> you must let Microsoft know because they will want to fix it. Mike On
> 4/06/2015 11:16 AM, Steve Burrus wrote: *
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>> * *"you should use Python >= 3.4" I rerpeatedly use version 3.5 of
>> Python! I have looked at many of these tutorial videos, via youtube, on how
>> to set up Django but I_still _get that error msg. when I try to type in
>> "pip" after I think I haVE successfully installed it!* * * *Â  Â  Â  Â  Â
>> Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â Â  Â  Â  Â  Â  Â
>>                                Steve B. * * * *On Wed, Jun
>> 3, 2015 at 8:04 PM, Mike Dewhirst <mi...@dewhirst.com.au
>> <mi...@dewhirst.com.au> <mailto:mi...@dewhirst.com.au
>> <mi...@dewhirst.com.au>>> wrote: * *On 4/06/2015 8:42 AM, Steve Burrus
>> wrote: * *well I am still waiting for an answer to my earlier
>> post about pip and apparently not configuring it right.Â
>>   * * Have you looked at the pip website? Maybe there is a user
>> support mailing list for pip. But in any case, perhaps you should
>> use Python >= 3.4 because it has pip built in. Good luck Mike
>>   * *Â * -- 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
>> <django-users%2bunsubscr...@googlegroups.com>
>> <mailto:django-users+unsubscr...@googlegroups.com
>> <django-users%2bunsubscr...@googlegroups.com>>. To post to this group, send
>> email to django-users@googlegroups.com <django-users@googlegroups.com>
>> <mailto:django-users@googlegroups.com <django-users@googlegroups.com>>.
>> Visit this group at http://groups.google.com/group/django-users
>> <http://groups.google.com/group/django-users>. To view this discussion on
>> the web visit
>> https://groups.google.com/d/msgid/django-users/CABcoaSCRByxHr%2B6ZXOKo4PRRPcYCvpWA7H_UkcTBPhgtTrFZ8Q%40mail.gmail.com
>> <https://groups.google.com/d/msgid/django-users/CABcoaSCRByxHr%2B6ZXOKo4PRRPc

Re: how to get get-pip.py

2015-06-03 Thread Steve Burrus
*"you should use Python >= 3.4" I rerpeatedly use version 3.5 of Python! I
have looked at many of these tutorial videos, via youtube, on how to set up
Django but I still get that error msg. when I try to type in "pip" after I
think I haVE successfully installed it!*


*
 Steve B. *


*On Wed, Jun 3, 2015 at 8:04 PM, Mike Dewhirst <mi...@dewhirst.com.au
<mi...@dewhirst.com.au>> wrote:*
>
>
> *On 4/06/2015 8:42 AM, Steve Burrus wrote: *
>>
>>
>>
>> * well I am still waiting for an answer to my earlier post about pip and
>> apparently not configuring it right. *
>
>
>
>
>
>
>
>
>
>
> * Have you looked at the pip website? Maybe there is a user support
> mailing list for pip. But in any case, perhaps you should use Python >= 3.4
> because it has pip built in. Good luck Mike *
>>
>>
>>
>
>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CABcoaSCRByxHr%2B6ZXOKo4PRRPcYCvpWA7H_UkcTBPhgtTrFZ8Q%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: how to get get-pip.py

2015-06-03 Thread Steve Burrus
well I am still waiting for an answer to my earlier post about pip and
apparently not configuring it right.

On Wed, Jun 3, 2015 at 11:13 AM, Steve Burrus <steveburru...@gmail.com>
wrote:

> well I am ab;e to install pip okay BUT there must be a config. error
> because all that I get when I t ry to run pip is this :
>
> "C:\Users\SteveB\Desktop>pip
> 'pip' is not recognized as an internal or external command, operable
> program or batch file."
>
> Now what is wrong anyway? [I have set the environment variables the right
> way for Python I believe]
>
>
>
> On Tuesday, June 2, 2015 at 6:01:47 PM UTC-5, Steve Burrus wrote:
>>
>> how do I get get-pip.py?
>>
>>
>>
>  --
> You received this message because you are subscribed to a topic in the
> Google Groups "Django users" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/django-users/tKJTNAq4sS4/unsubscribe.
> To unsubscribe from this group and all its topics, 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.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/aaacb0a7-daba-4c15-9855-6703a1e64592%40googlegroups.com
> <https://groups.google.com/d/msgid/django-users/aaacb0a7-daba-4c15-9855-6703a1e64592%40googlegroups.com?utm_medium=email_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CABcoaSAXEciVaE9Fv5RxbHgpRq1Q388txFZKMbeDk%3DkuJ_-CDw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: how to get get-pip.py

2015-06-03 Thread Steve Burrus
well I am ab;e to install pip okay BUT there must be a config. error 
because all that I get when I t ry to run pip is this :

"C:\Users\SteveB\Desktop>pip
'pip' is not recognized as an internal or external command, operable 
program or batch file."

Now what is wrong anyway? [I have set the environment variables the right 
way for Python I believe]
  


On Tuesday, June 2, 2015 at 6:01:47 PM UTC-5, Steve Burrus wrote:
>
> how do I get get-pip.py?
>
>  
>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/aaacb0a7-daba-4c15-9855-6703a1e64592%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


how to get get-pip.py

2015-06-02 Thread Steve Burrus
how do I get get-pip.py?

 

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/74aa072c-181d-42c6-81ac-92029d305356%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Trouble w. Setting Up Virtual Env.

2015-06-02 Thread Steve Burrus
*I hasve repeatedly tried now to set up the Django Virtual Environment 
without any success! Just what am I doing wrong anyway?? I am at my "wit's 
end"  trying to figure out what the specific problem is.*
  
*c:\Users\SteveB\Desktop>virtualenv steve1*
*Using base prefix 'C:\\Python 3.5'*
*New python executable in steve1\Scripts\python.exe*
*Installing setuptools, pip, wheel...*
*  Complete output from command c:\Users\SteveB\Desk...1\Scripts\python.exe 
-c "import sys, pip; sys...d\"] + sys.argv[1:]))" setuptools pip wheel:*
*  Ignoring indexes: https://pypi.python.org/simple*
*Collecting setuptools*
*  The repository located at None is not a trusted or secure host and is 
being ignored. If this repository is available via HTTPS it is recommended 
to use HTTPS instead, otherwise you may silence this warning and allow it 
anyways with '--trusted-host None'.*
*  The repository located at None is not a trusted or secure host and is 
being ignored. If this repository is available via HTTPS it is recommended 
to use HTTPS instead, otherwise you may silence this warning and allow it 
anyways with '--trusted-host None'.*
*  The repository located at None is not a trusted or secure host and is 
being ignored. If this repository is available via HTTPS it is recommended 
to use HTTPS instead, otherwise you may silence this warning and allow it 
anyways with '--trusted-host None'.*
*  The repository located at None is not a trusted or secure host and is 
being ignored. If this repository is available via HTTPS it is recommended 
to use HTTPS instead, otherwise you may silence this warning and allow it 
anyways with '--trusted-host None'.*
*  The repository located at None is not a trusted or secure host and is 
being ignored. If this repository is available via HTTPS it is recommended 
to use HTTPS instead, otherwise you may silence this warning and allow it 
anyways with '--trusted-host None'.*
*  The repository located at None is not a trusted or secure host and is 
being ignored. If this repository is available via HTTPS it is recommended 
to use HTTPS instead, otherwise you may silence this warning and allow it 
anyways with '--trusted-host None'.*
*  Could not find a version that satisfies the requirement setuptools (from 
versions: )*
*No matching distribution found for setuptools*
**
*...Installing setuptools, pip, wheel...done.*
*Traceback (most recent call last):*
*  File "C:\Python 3.5\lib\runpy.py", line 170, in _run_module_as_main 
"__main__", mod_spec)*
*  File "C:\Python 3.5\lib\runpy.py", line 85, in _run_code exec(code, 
run_globals)*
*  File "C:\Python 3.5\Scripts\virtualenv.exe\__main__.py", line 9, in 
*
*  File "C:\Python 3.5\lib\site-packages\virtualenv.py", line 832, in main 
symlink=options.symlink)*
*  File "C:\Python 3.5\lib\site-packages\virtualenv.py", line 1004, in 
create_environment*
*install_wheel(to_install, py_executable, search_dirs)*
*  File "C:\Python 3.5\lib\site-packages\virtualenv.py", line 969, in 
install_wheel*
*'PIP_NO_INDEX': '1'*
*  File "C:\Python 3.5\lib\site-packages\virtualenv.py", line 910, in 
call_subprocess*
*% (cmd_desc, proc.returncode))*
*OSError: Command c:\Users\SteveB\Desk...1\Scripts\python.exe -c "import 
sys, pip; sys...d\"] + sys.argv[1:]))" setuptools pip wheel failed with 
error code 1*

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/898eb3b7-a396-40d3-8ec6-4815d48c2263%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Where to now??

2015-06-01 Thread Steve Burrus
*Well I successfully instsalled Django 1.8*. After doing the "pip freeze" 
command in my Win 10 beta command prompt I see that I g ot that version of 
Django installed. But where do I go from here? How do i launch the server 
and create my virtual environment?*



-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/60896f7d-c729-435d-9d3b-b663945fc271%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Sending Data from client side(another computer) to Django(my computer) using Socket library

2015-05-11 Thread steve malise
I want to display HTTP POST data from client side to on the server side and
what am supposed do to achieve?

On Mon, May 11, 2015 at 3:31 PM, Jani Tiainen <rede...@gmail.com> wrote:

> Hi,
>
> Sounds like you're mixing up terms and technologies here and really you
> are trying something that Django was never designed for.
>
> It would be really helpful to know what are you really trying to do,
> instead of just trying techniques that may or may not work for your case.
>
>
> On Mon, 11 May 2015 15:18:37 +0200
> steve malise <stviasw...@gmail.com> wrote:
>
> > Meaning write JavaScript code to make a request?
> > how can achieve it other than writing JavaScript code?
> >
> >
> > On Mon, May 11, 2015 at 3:13 PM, Guilherme Leal <lealhu...@gmail.com>
> wrote:
> >
> > > The "navigation" of your browser always performs a GET method. If
> you're
> > > trying to test that kind of request in the browser, the best aproach
> would
> > > be open the JavaScript and make the request there.
> > >
> > > 2015-05-11 10:09 GMT-03:00 steve malise <stviasw...@gmail.com>:
> > >
> > >> client code:
> > >> import httplib
> > >> import urllib
> > >>
> > >> data = urllib.urlencode({'data':'data1'})
> > >> conn = httplib.HTTPConnection(myipaddr)
> > >> headers = {"Content-type":"application/x-www-form-urlencoded",
> > >> "Accept":"text/plain",
> > >>  "Content-Length:":len(data)}
> > >> h.request('POST','/',data,headers)
> > >>
> > >> res = h.getresponse()
> > >> print r.status,r.reason
> > >>
> > >> server side code(view.py):
> > >>
> > >> from django.shortcuts import render
> > >> from django.views.decorators.csrf import csrf_exempt
> > >> from django.http import HttpResponse
> > >> from django.conf.urls import url
> > >> from django.template import loader
> > >> from django.utils.timezone import utc
> > >> from django.template import Context, Template
> > >> from django.template.loader import get_template
> > >> from django.shortcuts import render_to_response
> > >> from django.template import RequestContext
> > >> from myapp.models import Temperature
> > >> from myapp import models
> > >> import socket , select
> > >> import os
> > >> import datetime
> > >> socktetList=[]
> > >>
> > >>
> > >> @csrf_exempt
> > >> def myview(request):
> > >> if request.method == 'POST':
> > >> return HttpResponse("%s %s" % (request.method, request.body))
> > >> #print POST body
> > >> else:
> > >> return HttpResponse("%s %s" % (request.method, request.body))
> > >>
> > >> on the client side i get "200 OK"(everything is ok)
> > >> but when i open my browser it return "GET",
> > >>
> > >> i want it to return or display POST DATA.
> > >>
> > >> how can i do that??
> > >> please help
> > >>
> > >>
> > >>
> > >> On Thu, May 7, 2015 at 4:13 PM, Thomas Levine <_...@thomaslevine.com>
> wrote:
> > >>
> > >>> On 07 May 16:00, steve malise wrote:
> > >>> > The error comes when i runserver and send data from another
> computer to
> > >>> > django,then i get this "code 400, message Bad request syntax ( data
> > >>> from
> > >>> > another computer)"
> > >>>
> > >>> This is because
> > >>>
> > >>> On 07 May 11:42, Tom Evans wrote:
> > >>> > Eurgh. Your hand-crafted HTTP request is not a valid request. Use
> one
> > >>> > of the http libraries built in to python:
> > >>>
> > >>> You can find here some directions on forming the request validly,
> > >>> http://www.w3.org/Protocols/Specs.html
> > >>>
> > >>> as you apparently don't want to use any of the libraries below.
> > >>>
> > >>> On 07 May 16:00, steve malise wrote:
> > >>> > urllib2:
> > >>> > https://docs.python.org/2/howto/urllib2.html#data
> > >>> >
> > >>> > httplib:
> > >&g

Re: Sending Data from client side(another computer) to Django(my computer) using Socket library

2015-05-11 Thread steve malise
Meaning write JavaScript code to make a request?
how can achieve it other than writing JavaScript code?


On Mon, May 11, 2015 at 3:13 PM, Guilherme Leal <lealhu...@gmail.com> wrote:

> The "navigation" of your browser always performs a GET method. If you're
> trying to test that kind of request in the browser, the best aproach would
> be open the JavaScript and make the request there.
>
> 2015-05-11 10:09 GMT-03:00 steve malise <stviasw...@gmail.com>:
>
>> client code:
>> import httplib
>> import urllib
>>
>> data = urllib.urlencode({'data':'data1'})
>> conn = httplib.HTTPConnection(myipaddr)
>> headers = {"Content-type":"application/x-www-form-urlencoded",
>> "Accept":"text/plain",
>>  "Content-Length:":len(data)}
>> h.request('POST','/',data,headers)
>>
>> res = h.getresponse()
>> print r.status,r.reason
>>
>> server side code(view.py):
>>
>> from django.shortcuts import render
>> from django.views.decorators.csrf import csrf_exempt
>> from django.http import HttpResponse
>> from django.conf.urls import url
>> from django.template import loader
>> from django.utils.timezone import utc
>> from django.template import Context, Template
>> from django.template.loader import get_template
>> from django.shortcuts import render_to_response
>> from django.template import RequestContext
>> from myapp.models import Temperature
>> from myapp import models
>> import socket , select
>> import os
>> import datetime
>> socktetList=[]
>>
>>
>> @csrf_exempt
>> def myview(request):
>> if request.method == 'POST':
>> return HttpResponse("%s %s" % (request.method, request.body))
>> #print POST body
>> else:
>> return HttpResponse("%s %s" % (request.method, request.body))
>>
>> on the client side i get "200 OK"(everything is ok)
>> but when i open my browser it return "GET",
>>
>> i want it to return or display POST DATA.
>>
>> how can i do that??
>> please help
>>
>>
>>
>> On Thu, May 7, 2015 at 4:13 PM, Thomas Levine <_...@thomaslevine.com> wrote:
>>
>>> On 07 May 16:00, steve malise wrote:
>>> > The error comes when i runserver and send data from another computer to
>>> > django,then i get this "code 400, message Bad request syntax ( data
>>> from
>>> > another computer)"
>>>
>>> This is because
>>>
>>> On 07 May 11:42, Tom Evans wrote:
>>> > Eurgh. Your hand-crafted HTTP request is not a valid request. Use one
>>> > of the http libraries built in to python:
>>>
>>> You can find here some directions on forming the request validly,
>>> http://www.w3.org/Protocols/Specs.html
>>>
>>> as you apparently don't want to use any of the libraries below.
>>>
>>> On 07 May 16:00, steve malise wrote:
>>> > urllib2:
>>> > https://docs.python.org/2/howto/urllib2.html#data
>>> >
>>> > httplib:
>>> > https://docs.python.org/2/library/httplib.html#examples
>>> >
>>> > or use a 3rd party library that wraps those in a more pleasing
>>> interface:
>>> >
>>> > requests:
>>> > http://docs.python-requests.org/en/latest/
>>>
>>> Using one of the above-listed libraries would still accomplish what you
>>> are trying to do, as you described here,
>>>
>>> On 07 May 16:00, steve malise wrote:
>>> > What i am trying to do is run python script(client side) on another
>>> > computer which is on same network with my computer,then receive data
>>> from
>>> > another computer with the django(which is running on my computer(server
>>> > side)).i am using built-in "runserver".
>>>
>>> so I suspect that you are doing something more that we missed. Perhaps
>>> you could tell us why you want to do this?
>>>
>>> --
>>> 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.
>>> To view this discu

Re: Sending Data from client side(another computer) to Django(my computer) using Socket library

2015-05-11 Thread steve malise
client code:
import httplib
import urllib

data = urllib.urlencode({'data':'data1'})
conn = httplib.HTTPConnection(myipaddr)
headers = {"Content-type":"application/x-www-form-urlencoded",
"Accept":"text/plain",
 "Content-Length:":len(data)}
h.request('POST','/',data,headers)

res = h.getresponse()
print r.status,r.reason

server side code(view.py):

from django.shortcuts import render
from django.views.decorators.csrf import csrf_exempt
from django.http import HttpResponse
from django.conf.urls import url
from django.template import loader
from django.utils.timezone import utc
from django.template import Context, Template
from django.template.loader import get_template
from django.shortcuts import render_to_response
from django.template import RequestContext
from myapp.models import Temperature
from myapp import models
import socket , select
import os
import datetime
socktetList=[]


@csrf_exempt
def myview(request):
if request.method == 'POST':
return HttpResponse("%s %s" % (request.method, request.body))
#print POST body
else:
return HttpResponse("%s %s" % (request.method, request.body))

on the client side i get "200 OK"(everything is ok)
but when i open my browser it return "GET",

i want it to return or display POST DATA.

how can i do that??
please help



On Thu, May 7, 2015 at 4:13 PM, Thomas Levine <_...@thomaslevine.com> wrote:

> On 07 May 16:00, steve malise wrote:
> > The error comes when i runserver and send data from another computer to
> > django,then i get this "code 400, message Bad request syntax ( data from
> > another computer)"
>
> This is because
>
> On 07 May 11:42, Tom Evans wrote:
> > Eurgh. Your hand-crafted HTTP request is not a valid request. Use one
> > of the http libraries built in to python:
>
> You can find here some directions on forming the request validly,
> http://www.w3.org/Protocols/Specs.html
>
> as you apparently don't want to use any of the libraries below.
>
> On 07 May 16:00, steve malise wrote:
> > urllib2:
> > https://docs.python.org/2/howto/urllib2.html#data
> >
> > httplib:
> > https://docs.python.org/2/library/httplib.html#examples
> >
> > or use a 3rd party library that wraps those in a more pleasing interface:
> >
> > requests:
> > http://docs.python-requests.org/en/latest/
>
> Using one of the above-listed libraries would still accomplish what you
> are trying to do, as you described here,
>
> On 07 May 16:00, steve malise wrote:
> > What i am trying to do is run python script(client side) on another
> > computer which is on same network with my computer,then receive data from
> > another computer with the django(which is running on my computer(server
> > side)).i am using built-in "runserver".
>
> so I suspect that you are doing something more that we missed. Perhaps
> you could tell us why you want to do this?
>
> --
> 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.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/20150507141332.GA27942%40d1stkfactory
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CACwh%3D0zjAYKjmyTJTWcucTyLM_iVaLokcgqREZpXgzp7e_GEGw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: Sending Data from client side(another computer) to Django(my computer) using Socket library

2015-05-07 Thread steve malise
What i am trying to do is run python script(client side) on another
computer which is on same network with my computer,then receive data from
another computer with the django(which is running on my computer(server
side)).i am using built-in "runserver".

The error comes when i runserver and send data from another computer to
django,then i get this "code 400, message Bad request syntax ( data from
another computer)"



On Thu, May 7, 2015 at 3:28 PM, Tom Evans <tevans...@googlemail.com> wrote:

> On Thu, May 7, 2015 at 12:48 PM, steve malise <stviasw...@gmail.com>
> wrote:
> > where can i write web server?
> >
>
> Why do you want to?
>
> Django is a web application, it is hosted inside webservers, typically
> using WSGI. Typically, you would use one of the many webservers that
> can host wsgi applications - nginx, apache+mod_wsgi, uwsgi, chaussette
> and many many others. You can also use the built-in "runserver"
> webserver for development.
>
> If you want to write your own webserver for your own edification, the
> wsgiref library is built in to python to provide a reference
> implementation.
>
> Cheers
>
> Tom
>
> --
> 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.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/CAFHbX1LKc_%2BBW_8JakpFLPOiZ%2BM07YwemFTZ1AH%2Bmk_TH8j42g%40mail.gmail.com
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CACwh%3D0xQumBtV0BkWj0pqDdy8v7ZKyGU4oh9m2uXkuWoJJCbEw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: Sending Data from client side(another computer) to Django(my computer) using Socket library

2015-05-07 Thread steve malise
where can i write web server?


On Thu, May 7, 2015 at 12:42 PM, Tom Evans <tevans...@googlemail.com> wrote:

> On Thu, May 7, 2015 at 9:24 AM, steve malise <stviasw...@gmail.com> wrote:
> >
> > client side code:
> > data = "message"
> > try:
> > clsocket = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
> > clsocket.connect(('192.168.2.2', 8000))
> > print("Connection has been Made")
> > clsocket.send("POST / HTTP/1.1 "+ data)
> > clsocket.close()
> > except:
> > print("ERROR:Connection is not established")
>
> Eurgh. Your hand-crafted HTTP request is not a valid request. Use one
> of the http libraries built in to python:
>
> urllib2:
> https://docs.python.org/2/howto/urllib2.html#data
>
> httplib:
> https://docs.python.org/2/library/httplib.html#examples
>
> or use a 3rd party library that wraps those in a more pleasing interface:
>
> requests:
> http://docs.python-requests.org/en/latest/
>
> >
> > Django code(view.py)
> >
> > def RandomValues(request):
> >
> > template = get_template('TIME TABLE.html')
> > s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
> > s.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEADDR, 1)
> > try:
> > s.bind(('192.168.2.2',8000))
> > s.listen(5)
> > socketList.append(s)
> > except:
> > return HttpResponse("Unable to bind ")
> >
> >
> >
> > while 1:
> > readyToread,readyTowrite,inError =
> select.select(socketList,[],[],1)
> > for sock in readyToread:
> >
> >  if sock == s:
> >   sockfd, addr = s.accept()
> >socketList.append(sockfd)
> >   else:
> >data = sock.recv(4096)
> >message = data.decode("utf-8")
> >
> > return HttpResponse(message)
>
> ?
>
> Why are you writing a webserver inside a view?
>
> Cheers
>
> Tom
>
> --
> 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.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/CAFHbX1%2BS_w9zCk_Af5wMXZABFM%3D6k40nRWfp9P1gonsT5BNDFQ%40mail.gmail.com
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CACwh%3D0w7X_YndLs4DJugQFw7DTmGpf9c-RcLR6sUMHQ0%2BNZscw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Sending Data from client side(another computer) to Django(my computer) using Socket library

2015-05-07 Thread steve malise

client side code:
data = "message"
try:
clsocket = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
clsocket.connect(('192.168.2.2', 8000))
print("Connection has been Made")
clsocket.send("POST / HTTP/1.1 "+ data)
clsocket.close()   
except:
print("ERROR:Connection is not established")

Django code(view.py)

def RandomValues(request):

template = get_template('TIME TABLE.html')
s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
s.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEADDR, 1)
try:
s.bind(('192.168.2.2',8000))
s.listen(5)
socketList.append(s)
except:
return HttpResponse("Unable to bind ")



while 1:
readyToread,readyTowrite,inError = select.select(socketList,[],[],1)
for sock in readyToread:
  
 if sock == s:
  sockfd, addr = s.accept()
   socketList.append(sockfd)
  else:
   data = sock.recv(4096)
   message = data.decode("utf-8")

return HttpResponse(message)

On my command prompt it says:
[07/May/2015 10:06:21]code 400, message Bad request syntax ('POST / 
HTTP/1.1 message')
[07/May/2015 10:06:21]"POST / HTTP/1.1 message" 400 -

Even if i remove "POST / HTTP/1.1",i still get this error 

please help i am new to Django 



-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/12ab40fa-b80f-4f35-ab5a-75530e9eca03%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Choices as a callable.. but no parameters?

2015-04-20 Thread Steve Hiemstra
I am trying to build a form with dynamic choices. e.g., the choices should 
depend on the user.

https://docs.djangoproject.com/en/1.8/ref/forms/fields/#choicefield

Says choices may now be a callable, and sure enough it is called in `
django/forms/fields.py(818)` – but without any parameters.

How can I get access to the current user, view, or any bit of context.

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/4a74be7f-e3cc-4e72-9a15-6a1ca43c9677%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Django Logging Send Email on Openshift

2015-04-06 Thread Steve Pousty
It's not a good idea to send emails directly from OpenShift since we are on 
AWS ip ranges. You should use a service like SendGrid or MailGun.

On Monday, April 6, 2015 at 10:31:11 AM UTC-7, Guilherme Leal wrote:
>
> Is anybody using OpenShift for Django hosting? I'm having trouble 
> configuring the Logging engine to send emails on errors and could use some 
> help.
>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/cc51a93f-21f9-44eb-8b9e-1d4056443591%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: trouble logging in to post ticket for django documentation

2014-08-22 Thread Steve
Thanks Russ.  Everything's peachy.

I poked around enough before posting my message that I ought have put that 
together myself.  Sorry to have bothered you.  Cheers.

On Friday, 22 August 2014 20:33:58 UTC-4, Russell Keith-Magee wrote:
>
> Hi Steve,
>
> We recently changed the login procedures for our Trac instance, and we're 
> still shaking out some of the bugs. In this case, the forbidden page has 
> the wrong link on it. If you want to log in with your Github account, visit:
>
> https://code.djangoproject.com/github/login
>
> then go ahead an lodge your ticket.
>
> Apologies for the inconvenience.
>
> Yours,
> Russ Magee %-)
>
>
>
> On Sat, Aug 23, 2014 at 4:06 AM, Steve <gus.g...@gmail.com > 
> wrote:
>
>> Total noob here.  I'm working through the (very helpful) django 
>> tutorials.  I'd like to enter a suggestion ticket.  I've created a github 
>> account and logged into it, yet I still receive the following error message 
>> from code.djangoproject.com:
>>
>> You are currently not logged in. You may want to do so 
>> <https://code.djangoproject.com/login> now.
>>  Error: Forbidden
>>
>> TICKET_CREATE privileges are required to perform this operation. You 
>> don't have the required permissions.
>>
>> I try to login again via the "do so" link above; I enter my new github 
>> username and password but instead of logging in I'm stuck in an infinite 
>> loop whereby I'm asked for my login credentials forever.  What gives? 
>>  Cheers.
>>  
>> -- 
>> 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.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/django-users/b2505d7c-769e-4e4a-8bb4-4f4e988fb8b4%40googlegroups.com
>>  
>> <https://groups.google.com/d/msgid/django-users/b2505d7c-769e-4e4a-8bb4-4f4e988fb8b4%40googlegroups.com?utm_medium=email_source=footer>
>> .
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/68333c36-fd6f-46fb-b13a-4549d34372de%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


trouble logging in to post ticket for django documentation

2014-08-22 Thread Steve
Total noob here.  I'm working through the (very helpful) django tutorials. 
 I'd like to enter a suggestion ticket.  I've created a github account and 
logged into it, yet I still receive the following error message from 
code.djangoproject.com:

You are currently not logged in. You may want to do so 
 now.
Error: Forbidden

TICKET_CREATE privileges are required to perform this operation. You don't 
have the required permissions.

I try to login again via the "do so" link above; I enter my new github 
username and password but instead of logging in I'm stuck in an infinite 
loop whereby I'm asked for my login credentials forever.  What gives? 
 Cheers.

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/b2505d7c-769e-4e4a-8bb4-4f4e988fb8b4%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: write equation in django

2014-08-12 Thread Steve McConville
There are a number of ways to do this, but the most popular I think is
MathJax. There is a django app for assisting with it's integration here:
https://github.com/kaleidos/django-mathjax


On 12 August 2014 07:51, sandy <sndbt...@gmail.com> wrote:

> Hi,
> I want to include a mathematical equation in django project. Can anyone
> plz guide me as to where I should write the input to the equation, so as to
> see its output on the frontend screen.
>
>
> Thanks,
> Sandy
>
> --
> 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.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/5693b267-bb52-48d2-ae34-73a24e13836f%40googlegroups.com
> <https://groups.google.com/d/msgid/django-users/5693b267-bb52-48d2-ae34-73a24e13836f%40googlegroups.com?utm_medium=email_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>



-- 
steve
http://stevemcconville.com/

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAOoCU%3DQOYkj1Eo70iEWkwr8hVcOTebfCtWJUJfboWdi8wmtgyg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: __unicode__() addition not working in basic poll application.

2014-03-27 Thread Steve Evans
Thankyou! so much...!

It was because i had tabs instead of 4 spaces for the indents.
So basically it was an indentation error but it didn't say that in the 
console.

I think this will fix a lot of other peoples problems if they are using 
tabs instead of spaces for indentations.

Cheers.

On Thursday, 27 March 2014 10:53:29 UTC, Shai Efrati wrote:
>
> i wonder if it is just the formatting of the email, but i think you missed 
> spaces before your def. def are hierarchically under classes, so it should 
> be:
>
> import datetime
> from django.db import models
> from django.utils import timezone
>
> # Create your models here.
> class Poll(models.Model):
> question = models.CharField(max_length=200)
> def __unicode__(self):
> return self.question
> pub_date = models.DateTimeField('date published')
> def was_published_recently(self):
>   return self.pub_date >= timezone.now() - 
> datetime.timedelta(days=1)
>
> class Choice(models.Model):
> poll = models.ForeignKey(Poll)
> choice_text = models.CharField(max_length=200)
> votes = models.IntegerField(default=0)
> def __unicode__(self):
>  return self.choice_text
>
>
> Good luck!
>
>
> Shai.
>
>
> On Thu, Mar 27, 2014 at 12:06 PM, Steve Evans <00se...@gmail.com
> > wrote:
>
>> Hi I am having the same issue:
>>
>> I am using Python 2.7, and Django 1.6.
>>
>> Here is my code for models.py:
>>
>> import datetime
>> from django.db import models
>> from django.utils import timezone
>>
>> # Create your models here.
>> class Poll(models.Model):
>> question = models.CharField(max_length=200)
>> def __unicode__(self):
>> return self.question
>>
>> pub_date = models.DateTimeField('date published')
>> def was_published_recently(self):
>> return self.pub_date >= timezone.now() - datetime.timedelta(days=1)
>>
>> class Choice(models.Model):
>> poll = models.ForeignKey(Poll)
>> choice_text = models.CharField(max_length=200)
>> votes = models.IntegerField(default=0)
>> def __unicode__(self):
>> return self.choice_text
>>
>>
>> I have restarted the shell and this is what I get as a result:
>>
>> bash-3.2$ python manage.py shell
>>
>> Python 2.7.6 (default, Dec 19 2013, 06:00:47) 
>>
>> [GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] on darwin
>>
>> Type "help", "copyright", "credits" or "license" for more information.
>>
>> (InteractiveConsole)
>>
>> >>> from polls.models import Poll, Choice
>>
>> >>> Poll.objects.all()
>>
>> [, ]
>>
>> >>> exit()
>>
>> bash-3.2$ python manage.py shell
>>
>> Python 2.7.6 (default, Dec 19 2013, 06:00:47) 
>>
>> [GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] on darwin
>>
>> Type "help", "copyright", "credits" or "license" for more information.
>>
>> (InteractiveConsole)
>>
>> >>> from polls.models import Poll, Choice
>>
>> >>> Poll.objects.all()
>>
>> [, ]
>>
>> >>> 
>> Any help would be great...
>>
>> Cheers,
>> Steve
>>
>>
>>
>> On Sunday, 12 January 2014 14:34:22 UTC, shmengie wrote:
>>>
>>>  trojactory has the right idea.
>>>
>>> __unicode__ has two underscores on either side of _ _ unicode _ _
>>>
>>> If you don't spell __unicode__ with two underscores on both sides, you 
>>> are not overriding the default method __unicode__ 
>>>
>>> You are getting the default output for __unicode__ instead of the 
>>> expected.
>>>
>>  -- 
>> 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.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/django-users/114e5208-81b6-4068-82df-853176ebfd68%40googlegroups.com<https://groups.google.com/d/msgid/django-users/114e5208-81b6-4068-82df-853176ebfd68%40googlegroups.com?utm_medium=email_source=footer>
>> .
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/a2d77f15-84ce-47cb-9b23-5dbc1827e65b%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: __unicode__() addition not working in basic poll application.

2014-03-27 Thread Steve Evans
Hi I am having the same issue:

I am using Python 2.7, and Django 1.6.

Here is my code for models.py:

import datetime
from django.db import models
from django.utils import timezone

# Create your models here.
class Poll(models.Model):
question = models.CharField(max_length=200)
def __unicode__(self):
return self.question

pub_date = models.DateTimeField('date published')
def was_published_recently(self):
return self.pub_date >= timezone.now() - datetime.timedelta(days=1)

class Choice(models.Model):
poll = models.ForeignKey(Poll)
choice_text = models.CharField(max_length=200)
votes = models.IntegerField(default=0)
def __unicode__(self):
return self.choice_text


I have restarted the shell and this is what I get as a result:

bash-3.2$ python manage.py shell

Python 2.7.6 (default, Dec 19 2013, 06:00:47) 

[GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] on darwin

Type "help", "copyright", "credits" or "license" for more information.

(InteractiveConsole)

>>> from polls.models import Poll, Choice

>>> Poll.objects.all()

[, ]

>>> exit()

bash-3.2$ python manage.py shell

Python 2.7.6 (default, Dec 19 2013, 06:00:47) 

[GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] on darwin

Type "help", "copyright", "credits" or "license" for more information.

(InteractiveConsole)

>>> from polls.models import Poll, Choice

>>> Poll.objects.all()

[, ]

>>> 
Any help would be great...

Cheers,
Steve



On Sunday, 12 January 2014 14:34:22 UTC, shmengie wrote:
>
> trojactory has the right idea.
>
> __unicode__ has two underscores on either side of _ _ unicode _ _
>
> If you don't spell __unicode__ with two underscores on both sides, you are 
> not overriding the default method __unicode__ 
>
> You are getting the default output for __unicode__ instead of the expected.
>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/114e5208-81b6-4068-82df-853176ebfd68%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


First tutorial - 404

2014-02-15 Thread Steve Booth
I've been Googling on this for several hours.  Time to ask.

I'm just trying to run through the very first tutorial, and frankly, it's 
been a nightmare. Running under Fedora 18, Python 2.7, Django version is 
1.4.5.

So, I got the 1.4 tutorial up, created the site.. all works fine.  Fire up 
the server -- looks great.  Browse to http://127.0.0.1:800..

And I do NOT get the nice, blue Django page, I get a Page Not Found 404 
error telling me the URLconf in mysite.urls does not match '^admin/'

Well... YEA!  So either the 1.4 tutorial doc's are wrong, or the default 
site doesnt work, or I dont know what I'm doing.

Any help would be greatly appreciated. 

I shouldn't have to be asking this ... it should just work.

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/b8be3c8b-9c0a-4812-89b3-777ded918b65%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Group subscription management

2013-11-30 Thread Steve Sawyer
Thanks, Felipe.

For anyone else who might have trouble with this, go to the My Groups item 
on the left nav bar which displays the groups of which you're a member. 
Then click the "Edit Memberships" tab at the top. This will give you a 
drop-down to manage the subscription for all of your groups.

 

On Saturday, November 30, 2013 12:02:23 PM UTC-5, Steve Sawyer wrote:
>
> I am drowning in emails, and I can't seem to figure out how to 
> un-subscribe from everything that gets posted to this group.
>
> I tried to subscribe just to a daily digest so I only get one email a day, 
> but now I can't even find that setting to turn it off, as it appears to 
> also turn on an echo of every individual post into my mailbox.
>
> Can anyone help me out here??
>
>
>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/b502f846-60a5-4221-9065-3e70d15fb5b8%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Group subscription management

2013-11-30 Thread Steve Sawyer
I am drowning in emails, and I can't seem to figure out how to un-subscribe 
from everything that gets posted to this group.

I tried to subscribe just to a daily digest so I only get one email a day, 
but now I can't even find that setting to turn it off, as it appears to 
also turn on an echo of every individual post into my mailbox.

Can anyone help me out here??


-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/3ad39a03-806b-4bbd-bc0d-a3bdbd249d38%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: manage.py deprecation message for model/sql arguments

2013-11-21 Thread Steve Sawyer
Thanks, tim, but it looks like the message says "is deprecated" rather than 
"will be deprecated" - unless this is just how these warnings are worded.

On Thursday, November 21, 2013 11:54:36 AM UTC-5, tim wrote:
>
> It looks like an issue with pywintypes, not Django. A deprecation warning 
> means some code needs to update itself in order to work with future 
> versions of some other code. In this case, it looks to me like pywintypes 
> is using some functionality that will probably be removed in a future 
> version of Python.
>
> On Thursday, November 21, 2013 10:56:57 AM UTC-5, Steve Sawyer wrote:
>>
>> Working my way through the Django tutorial (running Python 3.3 and Django 
>> 1.6), and when I run manage.py with any of the model arguments 
>> (validate/sqlcustom/sqlclear/sqlall etc.) the output seems to be what the 
>> tutorial leads me to expect, but I'm getting this message:
>>
>> *C:\Python33\lib\site-packages\win32\lib\pywintypes.py:39: 
>> DeprecationWarning: imp.get_suffixes() is deprecated; use the constants 
>> defined on importlib.machinery instead*
>>
>> Is this something that requires some corrective action on my part? Is 
>> this an indicator that something is NOT working properly, or MAY NOT work 
>> properly in some of these processes?
>>
>> Thanks.
>>
>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/af791030-1e16-41a3-87c2-ee4eaad6fc6b%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


manage.py deprecation message for model/sql arguments

2013-11-21 Thread Steve Sawyer
Working my way through the Django tutorial (running Python 3.3 and Django 
1.6), and when I run manage.py with any of the model arguments 
(validate/sqlcustom/sqlclear/sqlall etc.) the output seems to be what the 
tutorial leads me to expect, but I'm getting this message:

*C:\Python33\lib\site-packages\win32\lib\pywintypes.py:39: 
DeprecationWarning: imp.get_suffixes() is deprecated; use the constants 
defined on importlib.machinery instead*

Is this something that requires some corrective action on my part? Is this 
an indicator that something is NOT working properly, or MAY NOT work 
properly in some of these processes?

Thanks.

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/f68c0891-893f-4575-9cb4-3cb7d483988f%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Startproject failing on Django 1.6

2013-11-14 Thread Steve Sawyer
Ramiro - I only have a single version of Python installed (I have the 
luxury of being able to keep things simple).

I just tried this again though, using the explicit pathing you recommend. I 
note that I have two copies of django-admin.py, but they're identical - one 
in C:\Python33\Scripts, and the other in site-packages. In any case, I'm 
still getting the ImportError.

I can see that there is an http package that apparently belongs to the 
python standard library, contains a cookies.py module and is located here:

C:\Python33\Lib\http

However, Django installs another http package

C:\Python33\Lib\site-packages\django\http

And this folder contains a file "cookie.py" (singular).

In any case, I'm not sure what module is expected to be imported. However, 
I note that if I try to import http from an interactive session, the 
__init__.py in the Django http package is executed, and I end up getting 
the same ImportError.

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/4f86f8b9-90e4-437c-a8fd-783063a63325%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Startproject failing on Django 1.6

2013-11-13 Thread Steve Sawyer
Thanks, Tom - however, I completely removed the Django 1.5 folders prior to 
installing Django 1.6, so unless there are Django components installed 
outside of those folders, I should be good.

It seems that I might have something mis-configured. I have the 
http.cookies module and I've done everything I can think of to ensure that 
it can be found by Python, but so far I'm not having any luck. I think this 
is the issue, and it may not be specific to Django at all.

On Wednesday, November 13, 2013 8:51:05 AM UTC-5, Tom Evans wrote:
>
> On Tue, Nov 12, 2013 at 6:35 PM, Steve Sawyer 
> <ssaw...@gmail.com> 
> wrote: 
> > Sorry for the typeface - it was the default that the page gave me and 
> didn't 
> > bother to change it (it also wouldn't word-wrap, so my apologies also 
> for 
> > the ragged layout). 
> > 
> > In any case, 1.6 is out now, and I'm trying to get started with Django 
> but 
> > can't get to 1st base here. I did use pip to install it and it installed 
> > successfully. 
> > 
>
> You almost certainly have remnants of your previous installation of 
> django hanging around, which is causing your problems. You will need 
> to completely remove the previous installation first, especially 
> django-admin.py. 
>
> Cheers 
>
> Tom 
>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/6e8a34d2-2670-46f8-ad16-4f38521fb917%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Startproject failing on Django 1.6

2013-11-12 Thread Steve Sawyer
Sorry for the typeface - it was the default that the page gave me and 
didn't bother to change it (it also wouldn't word-wrap, so my apologies 
also for the ragged layout).

In any case, 1.6 is out now, and I'm trying to get started with Django but 
can't get to 1st base here. I did use pip to install it and it installed 
successfully.

On Tuesday, November 12, 2013 1:15:17 PM UTC-5, Avraham Serour wrote:
>
> why are you using this font/size? it hurts my eyes trying to read and 
> makes understanding difficult
>
> in any case, you didn't need to wait for 1.6 to be released, if your 
> objective is to learn and you are not deploying production systems yet you 
> could use the RC, or if before that you could use the beta or before that 
> the dev trunk or even use python 2.7 in the meantime, nothing wrong with 
> that.
>
> how did you install django? I recommend using pip to install python 
> packages
>
> success
> avraham
>
>
> On Tue, Nov 12, 2013 at 7:14 PM, Steve Sawyer <ssaw...@gmail.com
> > wrote:
>
>> Django 1.6
>> Python 3.3
>> Windows 7 pro
>>
>> I've been anxiously awaiting Django 1.6 as I've been learning Python 3 for 
>> the last year. 
>>
>>
>> I tried unsuccessfully to go through the tutorial using Django 1.5.5, and 
>> figured I should wait 
>> for 1.6 to be released so I could avoid having to research and resolve 
>> version incompatibility issues.
>>
>> However, today I removed my prior Django installation, successfully 
>> installed Django 1.6, and 
>>
>>
>> started into the tutorial, but am again failing on this step:
>>
>> django-admin.py startproject mysite
>>
>> I'm getting an ImportError: No module named 'http.cookies'
>>
>> Note that I've verified that I have a folder named 'http', that this folder 
>> is in my PYTHONPATH, that it
>>
>>
>> contains a module named cookies.py and that the folder contains an 
>> __init__.py file.
>>
>> Any suggestions as to what I need to do to resolve this? I'm not making much 
>> progress with the tutorial! :-)
>>
>>
>> Thanks.
>>
>>  -- 
>> 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.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/django-users/3611ff1b-c2a6-4270-b888-1234b91d1d09%40googlegroups.com
>> .
>> 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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/6354da2a-a769-4e39-90c1-23bb79bdb7ac%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


  1   2   3   4   5   6   7   8   >