Re: Post to PayPal with urlllib [newbie question]

2006-08-24 Thread Derek Hoy
inistration, save order details etc. - return confirmation message to Worldpay for them to display I haven't done this before, so I'd be happy to take advice. -- Derek --~--~-~--~~~---~--~~ You received this message because you are subscribed t

Re: Post to PayPal with urlllib [newbie question]

2006-08-24 Thread Derek Hoy
On 8/25/06, Jeremy Dunck <[EMAIL PROTECTED]> wrote: > > In that situation, I guess you just wouldn't ship the order if the > customer underpays (by tweaking the payment amount), right? Unless it was you :) -- Derek --~--~-~--~~~---~--~---

Re: TemplatePages directory

2006-08-27 Thread Derek Hoy
d content in its old location until we move it all over. It's working very well. -- Derek --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to d

Re: Creating graphs in Django application

2006-09-08 Thread Derek Hoy
- http://ploticus.sourceforge.net/ - python API http://www.srcc.lsu.edu/~davids/ploticus_module.html -- Derek --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, se

TypeError: isinstance() arg 2 must be a class, type, or tuple of classes and types in models/fields/related.py line 955

2013-01-17 Thread Derek Edwards
eferral > > def __unicode__(self): > return u"%s" % self.id > Again, this works perfectly in DEBUG mode but begins firing off exception emails to me the minute I switch off debug. I've been hitting my head against the wall for the better part of the day t

Lots of django questions

2015-05-21 Thread Derek Riemer
... Enter code here... Enter code here... Enter code here... Thanks, Derek -- 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+unsubsc

a simple software listing app.

2015-07-01 Thread derek riemer
.e. a portfolio, personal website ... which live in separate apps. Thanks, Derek -- 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+unsu

Re: Regarding Learning Django with collaboration

2015-07-19 Thread Derek Pauley
I am interested. I am a Web Platform Administrator. I use Python everyday. I have been using Django and Flask only for a short while. However I have years of Java and Ruby development experience. I can help with things on the OPS side and can write code. I am interested in Content Management Sy

Re: A native Django multiprocessing task queue - feedback wanted

2015-07-19 Thread Derek Pauley
Looks very nice. On Friday, July 17, 2015 at 1:06:20 PM UTC-5, Ilan wrote: > > About a month ago I started working on a multiprocessing task queue for > Django. It is not supposed to be a Celery beater, but a simpler Django > integrated alternative with similar performance. > This is my first bi

Re: Try Django 1.8 Tutorial 37 on Youtube - Bootstrap Design Falls Apart In Production

2015-07-19 Thread Derek Pauley
Have you reached out to the author of the tutorial? What browser are you using? Were you using the Django debug toolbar? On Thursday, July 16, 2015 at 4:24:40 PM UTC-5, Chris Nowak wrote: > > I'm following this Youtube tutorial as I'm learning Django, and around the > 11 minute mark, after the

Re: Retrieving recurring events using Django queries

2014-09-19 Thread Derek Rodger
Take a look at: https://github.com/llazzaro/django-scheduler also available on PyPI: pypi.python.org/pypi/django-scheduler/ It's very similar to what you have done so far. It handles virtual events ('occurrences') by generating them on the fly for a requested date range. Individual occurrences

Specifying modelform meta field as get_user_model() in 1.7

2014-10-20 Thread Derek Leverenz
if I am just missing something. thanks --Derek Leverenz -- 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 pos

FieldDoesNotExist Error in Tutorial Part 1

2014-11-18 Thread Derek Ng
s/projects/django-tutorial/lib/python3.4/site-packages/django/db/models/fields/related.py", line 1419, in resolve_related_fields else self.rel.to._meta.get_field_by_name(to_field_name)[0]) File "/Users/derekng/Documents/projects/django-tutorial/lib/python3.4/site-packages/django/d

Re: Building a calculator

2018-03-21 Thread Derek Zeng
Basically what you need is to store current selections/values in the session https://docs.djangoproject.com/en/2.0/topics/http/sessions/ Then access the session in the view and redirect accordingly. def my_ On Tuesday, March 20, 2018 at 4:29:00 PM UTC-4, Abbad yeslem wrote: > > Hello, > > I am

Using Django Sessions

2018-03-23 Thread Derek Zeng
You can have a flag in cart class to mark if things are cleared. Then in the __iter__ function, check the flag before getting the keys. If you do this you also need to add the check in add/remove and others accordingly. -- You received this message because you are subscribed to the Google Grou

Re: Django and graphs

2018-03-23 Thread Derek Zeng
What do you mean by Django extension? You can just use the Networkx in any django view controller and render the graph to svg using GraphViz. You can save the svg in database and then render it in a webpage. On Thursday, March 22, 2018 at 3:36:22 PM UTC-4, Mohsen wrote: > > Hi all: > > I am quit

Re: Django deployment

2018-03-25 Thread Derek Zeng
You may want to check out http://www.fabfile.org It's a fairly popular deployment tool for Python projects. It doesn't really matter what your local dev environment, but for the server it's relatively easier if it's Linux. -- You received this message because you are subscribed to the Google G

Help: 'django.utils.six.moves' is not a package

2018-04-08 Thread Derek Zeng
I got the following error when running pytest in django. Help is appreciated. This is the test I run import pytest from .factories import * @pytest.mark.django_db def test_with_client(client): PostFactory.create() # if commented out, the error is gone response = client.get('/') body = st

Re: Help: 'django.utils.six.moves' is not a package

2018-04-09 Thread Derek Zeng
six and some library you are using still > hopes it exists. > > what django version are you using? > > On Mon, Apr 9, 2018 at 3:39 AM, Derek Zeng wrote: > >> I got the following error when running pytest in django. Help is >> appreciated. >> >> This i

Re: Help: 'django.utils.six.moves' is not a package

2018-04-10 Thread Derek Zeng
On Tue, Apr 10, 2018, 1:39 AM Babatunde Akinyanmi wrote: > > > On Tue, 10 Apr 2018, 02:47 Derek Zeng, wrote: > >> I'm using django 2.0. >> What exactly is the purpose of django.utils.six.moves module? >> > Allowing a code base to be able to run on both p

Working with Databases

2019-05-26 Thread Derek Dong
I'm relatively new to Django and web development in general but have decent coding experience. My questions are primarily related to how to work with models to create a ranking system. Some background: I'm an officer for an academic school team and am trying to implement a ranking system that de

Selecting Models by Typing an Identifier

2019-05-28 Thread Derek Dong
I have two questions. The first is: I want to select models in a form. The first is a standard User, the second is a Contest form already defined. Let's take the User as an example. I want to only have to type a string into the form, and have all users with that string as a substring of their us

Internal Ranking System Application

2019-06-16 Thread Derek Dong
How can I integrate OAuth with a ranking system in a Django application? I'm not too familiar with Django design philosophy, which is why I'm asking these questions. The way I understand it, OAuth doesn't let you manipulate information on the server authenticating a user, so I would still need a

Re: Internal Ranking System Application

2019-06-24 Thread Derek Dong
plenty of other ways such as redirecting a user in > the views.py and yada yada if the user is NOT authenticated. > > Something I think would help you is to utilize Django-rest-framework. It's > designed as an API, but I think you'll understand Django much better > throu

Re: Internal Ranking System Application

2019-06-24 Thread Derek Dong
t 1 or Contest 2, etc. > > The score column is this user’s score based on a certain contest. The user > column specifies which user this record of scores belongs to. > > So in its entirety, the Contest table would “read” like this: in Contest > 1, the user Derek received

Re: Internal Ranking System Application

2019-06-24 Thread Derek Dong
I just wanted to add a question: I want to store the indices as floats if possible, to at least 3 decimal places, and display them to the nearest integer. Is this possible? On Monday, June 24, 2019 at 8:38:34 PM UTC-4, Derek Dong wrote: > > Thank you so much for the incredibly in-depth re

Re: Internal Ranking System Application

2019-06-25 Thread Derek Dong
se them efficiently. Using that one table, ContestScores, we can > find some scores for specific contests. We can write something like: > > from .models import ContestScores > > avar= ContestScores.objects.filter(contest=2) > thisvar = ContestScores.objects.filter(user=‘derek’) >

Using OAuth2 with Django

2019-06-26 Thread Derek Dong
So I've been trying to learn how to authenticate users in my Django application with OAuth. The token provider has already been established, and the provided documentation is here: https://ion.readthedocs.io/en/latest/developing/oauth.html However, once I've followed the instructions in the "Pyt

from django.utils.six.moves import range, ImportError: cannot import name 'range'

2017-09-02 Thread Derek Zeng
Hi, Today I tried to install my django project on a new mac computer. I used virutalenv to setup the packages. After I start the app by running './mange.py runserver' and access the home page I got the error from django.utils.six.moves import range, ImportError: cannot import name > 'range'

Re: from django.utils.six.moves import range, ImportError: cannot import name 'range'

2017-09-03 Thread Derek Zeng
line 116, in handle_simple from django.contrib.staticfiles.storage import staticfiles_storage File "/Users/coderek/Documents/projects/py3.5/lib/python3.5/site-packages/django/contrib/staticfiles/storage.py", line 21, in from django.utils.six.moves import range ImportError:

Re: from django.utils.six.moves import range, ImportError: cannot import name 'range'

2017-09-03 Thread Derek Zeng
it's the same in either versions of python. the output was captured when i was just debugging it in 3.5. On Sun, Sep 3, 2017 at 2:55 PM, James Schneider wrote: > > > File > "/Users/coderek/Documents/projects/py3.5/lib/python3.5/site-packages/django/contrib/staticfiles/storage.py", > line 21,

Re: from django.utils.six.moves import range, ImportError: cannot import name 'range'

2017-09-04 Thread Derek Zeng
If I turn off debug mode, it gives me 500 error and showing the same stack trace in the console. I also tried 1.11.4, still the same error. On Mon, Sep 4, 2017 at 2:33 AM, Raffaele Salmaso wrote: > On Sun, Sep 3, 2017 at 4:26 PM, Derek Zeng wrote: >> >> When I use django==1.

Re: from django.utils.six.moves import range, ImportError: cannot import name 'range'

2017-09-04 Thread Derek Zeng
instance will have > # inserted an importer with different class. > if (type(importer).__name__ == "_SixMetaPathImporter" and > importer.name == __name__): > del sys.meta_path[i] > break > > [1] https://docs.djangoproject.com/en/1.11/releases/1.11/# > dja

Django test runner not respecting unittest.TestCase?

2020-08-10 Thread Derek DeHart
For one of my functional tests, I decided to use unittest.TestCase instead of a Django test class because it was convenient when cleaning up the test to have direct access to my local development database in the test itself. Running the test in isolation like so passes as I'd expect: $ python

how to use the sites framework?

2015-08-13 Thread derek riemer
Hi, I have 3 apps. A base site, with a main menu, a personal website with a biography, and a weather app. I was curious if the sites framework can distinguish each app as a separate site while they are all on the same domain? I have derekriemer.pythonanywhere.com, and on the apps are pointed t

Re: Another django book?

2007-08-23 Thread Derek Lee-Wo
Amazon shows it as being released on Oct 22: http://www.amazon.com/Professional-Python-Frameworks-Programming-Turbogears/dp/0470138092/ref=pd_bbs_12/104-9039171-6407132?ie=UTF8&s=books&qid=1187871082&sr=8-12 On 8/23/07, Ramdas S <[EMAIL PROTECTED]> wrote: > Has someone seen this book? > > http:

Re: Comparison between Dreamhost and ASmallOrange

2007-02-16 Thread Derek Lee-Wo
ow how ASO is organized. I checked both of your sites and ASO is markedly faster. Derek On 2/15/07, sansmojo <[EMAIL PROTECTED]> wrote: > > By the way, I would also appreciate any comments on the site. It's a > work in progress, mainly in the middle of the night, so I

Django Book

2007-03-14 Thread Derek Lee-Wo
Amazon shows that the book on Django will be published on March 26th which is 1 1/2 weeks away. Does anyone know if that date is still valid? I'm anxiously waiting to order it. Derek --~--~-~--~~~---~--~~ You received this message because you are subscrib

Best Practices for faster template rendering

2007-02-07 Thread Derek Lee-Wo
I just started working with Django about a week ago and I love it. I was able to get my first webapp up and running faster than I have with various other technologies I've used in the past. One problem I'm having though is the speed of the template rendering. That is, the call to render_to_respon

Re: Best Practices for faster template rendering

2007-02-08 Thread Derek Lee-Wo
> > My app does a bunch of database queries and processing and when I > > timed that part, it all completes within 0.5 seconds, but the call to > > render_to_response() takes 18 seconds. Needless to say, the end-user > > experience isn't acceptable. > > I don't know if you are aware about the fac

Re: Best Practices for faster template rendering

2007-02-08 Thread Derek Lee-Wo
> You'll want to do something like this, timing each line: > > from django.template import loader > > source, origin = find_template_source('your_template_name') > template = get_template_from_string(source, origin, 'your_template_name') > template.render(your_context) > > -- > > It ma

Re: Best Practices for faster template rendering

2007-02-08 Thread Derek Lee-Wo
> I did as you suggested and the call template.render() is where the > 16-18 seconds are being spent. My next step is to add some timings to > django.template.NodeList.render as you suggested. I added a timing statement at the entrance and exit of render() and just inside the foreach loop. I go

Re: Best Practices for faster template rendering

2007-02-09 Thread Derek Lee-Wo
l and manipulation before generating the output so I know the database and SQL is not a factor. This is turning out to be very distressing. I'm starting to look at other template options. I may give Cheetah a try this weekend. Derek --~--~-~--~~~---~--~~ You received th

Re: Best Practices for faster template rendering

2007-02-09 Thread Derek Lee-Wo
Thu, 2007-02-08 at 20:21 -0600, Derek Lee-Wo wrote: > > > One more idea: It looks like you're doing foreign-key lookups in the > > > rendering. > > > > > > {% for workoutWeek in workoutWeeks %} > > > ... > > > {% for workoutDay in workout

Re: Best Practices for faster template rendering

2007-02-09 Thread Derek Lee-Wo
> It may take a couple more days to work this out. It's only been 48 hours > since you posted the original problem and less than 24 hours since you > posted a portion of your code that causes the problem. It is very > unusual behaviour for Django; the templating code is normally very fast, > but t

Re: Best Practices for faster template rendering

2007-02-09 Thread Derek Lee-Wo
The app I have is pretty simply as I'm just beginning so I didn't bother to try and make it any smaller. I've ZIPped the entire project directory and it can be downloaded here: http://www.roadtoboston.com/media/RoadToBoston.zip I have a batch file called runserver.cmd that would run the local t

Re: Best Practices for faster template rendering

2007-02-09 Thread Derek Lee-Wo
> I took a look and traced the bottleneck to lines 125 and 127 in > viewPlan.html. The problem was as Malcolm hinted -- you're > doing a foreign key lookup ({{ workout.workoutType.name }}) > for each iteration of the for loop. > > I changed line 55 of views.py to use select_related() instead > of

<    5   6   7   8   9   10