Django community: RSS
This page, updated regularly, aggregates Community blog posts from the Django community.
-
Mock Django Request for testing
When testing your applications I sometimes find myself needing to mock a request object. Unfortunately it is quite hard to find a good fake request factory which mimics a normal request. Django has a class included for this purpose called RequestFactory. However it doesn’t fake the session object, breaking most of my test code. To fix this I wrote a tiny snippet implementing the RequestFactory with session and user support. Hope it helps :) from django.core.handlers.base import BaseHandler from django.test.client import RequestFactory class RequestMock(RequestFactory): def request(self, **request): "Construct a generic request object." request = RequestFactory.request(self, **request) handler = BaseHandler() handler.load_middleware() for middleware_method in handler._request_middleware: if middleware_method(request): raise Exception("Couldn't create request mock object - " "request middleware returned a response") return request See the gist here. Share and Enjoy: -
The state of eCommerce in Django
-
The state of eCommerce in Django
So, you’re looking for a reusable, extendable, pony-powered eCommerce app? Here’s what’s out there: Satchmo Most well known. Huge, does everything you and your brother could ever want, but the client, that’s another story. So, you’re in the code, and hours go by because the Product models.py has 1570 lines and it turns out it was a problem with PriceAdjustmentCalc, whatever that does. Lightning Fast Shop Full blown solution (like satchmo), with batteries included, docs, tests, demo, and a lot of code. So regardless whether you need it or not, you get it all. And then, if you need something different, you’ll have to ack and grep a bit. Satchless Still in early development, but very straightforward and well documented so far. Actively developed and a good starting point for most use cases. Very pluggable and customizable products, categories and variants. Same dude also made mamona, which is a nice payment abstraction mechanism. Plata Made by the FeinCMS people. A pretty solid, simple, pluggable alternative for a “shop.” docs, tests, nice code. It makes you write your own urls and views by leveraging some of the model interface it has. The examples are pretty simple and only offer a product … -
The state of eCommerce in Django
So, you’re looking for a reusable, extendable, pony-powered eCommerce app? Here’s what’s out there: Satchmo Most well known. Huge, does everything you and your brother could ever want, but the client, that’s another story. So, you’re in the code, and hours go by because the Product models.py has 1570 lines and it turns out it was a problem with PriceAdjustmentCalc, whatever that does. Lightning Fast Shop Full blown solution (like satchmo), with batteries included, docs, tests, demo, and a lot of code. So regardless whether you need it or not, you get it all. And then, if you need something different, you’ll have to ack and grep a bit. Satchless Still in early development, but very straightforward and well documented so far. Actively developed and a good starting point for most use cases. Very pluggable and customizable products, categories and variants. Same dude also made mamona, which is a nice payment abstraction mechanism. Plata Made by the FeinCMS people. A pretty solid, simple, pluggable alternative for a “shop.” docs, tests, nice code. It makes you write your own urls and views by leveraging some of the model interface it has. The examples are pretty simple and only offer a product … -
The state of eCommerce in Django
So, you're looking for a reusable, extendable, pony-powered eCommerce app? Here's what's out there: Satchmo Most well known. Huge, does everything you and your brother could ever want, but the client, that's another story. So, you're in the code, and hours go by because the Product models.py has 1570 lines and it turns out it was a problem with PriceAdjustmentCalc, whatever that does. Lightning Fast Shop Full blown solution (like satchmo), with batteries included, docs, tests, demo, and a lot of code. So regardless whether you need it or not, you get it all. And then, if you need something different, you'll have to ack and grep a bit. Satchless Still in early development, but very straightforward and well documented so far. Actively developed and a good starting point for most use cases. Very pluggable and customizable products, categories and variants. Same dude also made mamona, which is a nice payment abstraction mechanism. Plata Made by the FeinCMS people. A pretty solid, simple, pluggable alternative for a "shop." docs, tests, nice code. It makes you write your own urls and views by leveraging some of the model interface it has. The examples are pretty simple and only offer a product … -
A Guide to Testing in Django #2
A Guide to Testing in Django #2 -
London Training Dates – Cancelled
I’m afraid the London django course training dates for the 17th and 18th May have now been cancelled due to insufficient interest. Apologies to anyone who was thinking of coming but hadn’t booked yet. -
Redis backend for Django-nonrel in development
Mirko Rossini has finally made his Redis backend public. It's called django-redis-engine and according to him it's still in pre-alpha stage. From a quick glance at the code it looks like you'll be able to define database indexes in order to support queries that go beyond Redis' (meager ;) native query capabilities (much like with django-dbindexer). This is awesome because you won't have to maintain indexes by hand. If you want to see a stable and fully featured Redis backend please help Mirko. Just clone the repository from github and start playing with the code. Enjoy! P.S.: Sorry for the long period of silence. We're still not finished with our final diploma exams, but we're getting close. Soon we can restart blogging more frequently and take the results of the previous survey into account. Leave a comment -
Sold out
DjangoCon Europe 2011 is sold out We are pleased to announce that DjangoCon Europe 2011 is now officially sold out. For those of you who have been unable to book a ticket, there is the possibility to add yourself to the waiting list. W’ll get in touch with you if tickets should become available. You can add yourself to the waiting list on the waiting list page -
Released 0.5.0 beta 7
Today we released LFS 0.5.0 beta 7 What's new? Improved error message for checkout form (Andres Vargas / zodman); issue #87 Fixed invalid HTML; issue #81 Bugfix: correct display of cart within shop view after cart has been updated; issue #82 Bugfix: save and display correct text of TextPortlets; issue #39 Fixed requried permission from "manage_shop" to "core.manage_shop"; issue #84 Fixed Integration Error when adding Product with existing slug; issue #42 Bugfix: made option price optional (as stated within form) Updated documentation; issue #60 Added transifex config file Added translations for mexican spanish (Andres Vargas) Updated spain translations Updated german translations Further Information You can find more information and help on following places: Official page Documentation on PyPI Demo Releases on PyPI Source code on bitbucket.org Google Group lfsproject on Twitter IRC -
LFC website is online
-
Released 1.0 alpha 6
-
Released 1.0 alpha 7
-
News 01/2010
-
Release 1.0 beta 1
-
Release 1.0 beta 4
-
Release 1.0 Final
-
News 02/2010
-
10 Reasons Why You Want To Use LFC
-
Release 1.0.3
-
Dutch Django meeting: lightning talks
Connecting Django to the Multisafepay payment provider - Jan Murre They're sometimes using multisafepay for adding online payment for sites. They're quite happy with it. It is relatively simple. The payment, like with most such providers, takes place on the payment provider's website. This is often perceived as trustworthy by customers. They have an xml api. For that, they had a couple of api implementations. Not in python, though. So he investigated it and a transaction is a pretty straightforward exchange of urls and xml messages. He made a python api based on the xml structure and their own provided non-python api examples. It is not on pypi yet, but Jan Murre might put it there if there's interest. Django-fanstatic - Jan-Jaap Driessen / Boaz Leskes Jan-Jaap never uses Django, Boaz does :-) They got together to integrate fanstatic into the django world. Jan-jaap presented fanstatic at the last python usergroup meeting. It makes javascript and css resources available in python. You can just import resources in python (import js.jquery). Those resources are included in python packages, which means they can have dependencies! Just specify something like jquery.need() in your view. Fanstatic handles the injection of the css/javascript into your … -
Dutch Django meeting: lightning talks
Connecting Django to the Multisafepay payment provider - Jan Murre They're sometimes using multisafepay for adding online payment for sites. They're quite happy with it. It is relatively simple. The payment, like with most such providers, takes place on the payment provider's website. This is often perceived as trustworthy by customers. They have an xml api. For that, they had a couple of api implementations. Not in python, though. So he investigated it and a transaction is a pretty straightforward exchange of urls and xml messages. He made a python api based on the xml structure and their own provided non-python api examples. It is not on pypi yet, but Jan Murre might put it there if there's interest. Django-fanstatic - Jan-Jaap Driessen / Boaz Leskes Jan-Jaap never uses Django, Boaz does :-) They got together to integrate fanstatic into the django world. Jan-jaap presented fanstatic at the last python usergroup meeting. It makes javascript and css resources available in python. You can just import resources in python (import js.jquery). Those resources are included in python packages, which means they can have dependencies! Just specify something like jquery.need() in your view. Fanstatic handles the injection of the css/javascript into your … -
Django Fiber - Dennis Bunskoek (Dutch Django meeting)
At leukeleu / ride the pony they've made a simple, user-friendly CMS for all your Django projects. Django fiber is one app with pages, contentitems, images and files. It replaces the django flatpages app and a couple of other things like treemenus, frontendadmin and so on. It aims to complement your project, it doesn't take it over. It adds simple menus and pages where you can add simple content items. And there's front end editing and drag/drop reordering of page items. They want to have the customers edit the website themselves so they don't have to change small things all the time (and that the customer doesn't have to pay them for 15 minutes all the time). You can add /@fiber to the url and you can log in and you get an edit sidebar. The edit sidebar means it doesn't intrude that much on your regular site layout. Editable items can be edited in-place by clicking on them (you get a popup with and edit form). In the sidebar, you can have a list of prepared bits of content (like your address data) which you can drag into the page. If you change it, it is changed everywhere at … -
Django Fiber - Dennis Bunskoek (Dutch Django meeting)
At leukeleu / ride the pony they've made a simple, user-friendly CMS for all your Django projects. Django fiber is one app with pages, contentitems, images and files. It replaces the django flatpages app and a couple of other things like treemenus, frontendadmin and so on. It aims to complement your project, it doesn't take it over. It adds simple menus and pages where you can add simple content items. And there's front end editing and drag/drop reordering of page items. They want to have the customers edit the website themselves so they don't have to change small things all the time (and that the customer doesn't have to pay them for 15 minutes all the time). You can add /@fiber to the url and you can log in and you get an edit sidebar. The edit sidebar means it doesn't intrude that much on your regular site layout. Editable items can be edited in-place by clicking on them (you get a popup with and edit form). In the sidebar, you can have a list of prepared bits of content (like your address data) which you can drag into the page. If you change it, it is changed everywhere at … -
Une autre façon de gérer ses settings d'application Django
Je travaille actuellement sur une application Django que je compte publier sous licence libre, et je suis confronté au problème classique de l’exposition de la configuration au développeur via les settings de son propre projet. Classiquement, on a tendance à proposer les settings “à plat”, dans le module settings.py du projet : # settings.py MY_APP_NAME_FOO = 42 MY_APP_NAME_ENABLE_CHUCK_NORRIZ_MODE = True Et donc depuis votre appli, vous pouvez récupérer les settings utilisateur de cette façon, en leur assignant une valeur par défaut s’ils ne sont pas déclarés : # apps/myapp/foo.py from django.conf import settings FOO = getattr(settings, 'MY_APP_NAME_FOO', 42) ENABLE_CHUCK_NORRIZ_MODE = getattr(settings, 'MY_APP_NAME_ENABLE_CHUCK_NORRIZ_MODE', False) Simple, pratique, suffisant me direz vous. Oui, mais bon, c’est un petit peu verbeux à mon sens, et pas toujours souple pour gérer un catalogue de settings ainsi que leur surcharge. Et puis j’ai l’impression en préfixant systématiquement ces noms de variables de faire insulte à cette merveilleuse fonctionnalité qu’on appelle la gestion des espaces de noms (voire de refaire du PHP < 5.3, ce qui provoque chez moi des bouffées d’angoisse et entame un processus de décapilation douloureux, mais je m’égare). Qui plus est, personnellement en temps que développeur, j’aurai tendance à préférer gérer les settings …