Title
stringlengths
11
150
A_Id
int64
518
72.5M
Users Score
int64
-42
283
Q_Score
int64
0
1.39k
ViewCount
int64
17
1.71M
Database and SQL
int64
0
1
Tags
stringlengths
6
105
Answer
stringlengths
14
4.78k
GUI and Desktop Applications
int64
0
1
System Administration and DevOps
int64
0
1
Networking and APIs
int64
0
1
Other
int64
0
1
CreationDate
stringlengths
23
23
AnswerCount
int64
1
55
Score
float64
-1
1.2
is_accepted
bool
2 classes
Q_Id
int64
469
42.4M
Python Basics and Environment
int64
0
1
Data Science and Machine Learning
int64
0
1
Web Development
int64
1
1
Available Count
int64
1
15
Question
stringlengths
17
21k
Is Django a good choice for a security critical application?
2,654,928
1
22
8,593
0
python,django,security
You can build a secure application with Django just as you can with any popular Java framework. One part where Java does shine is its extensive cryptographic library. For the minimal encryption tasks that are required by Django, Python’s cryptographic services are sufficient, however its lack of strong block ciphers make the encryption mechanism in Django insecure for data at rest. Python does natively support secure hashing algorithms to include SHA1, SHA224, SHA256, SHA384, and SHA512, however Django’s authentication mechanism has yet to be updated to use anything other than SHA1, making it potentially vulnerable to cryptographic analysis.
0
0
0
0
2009-01-31T10:46:00.000
7
0.028564
false
498,630
0
0
1
7
Is Django a good choice for a security critical application? I am asking this because most of the online banking software is built using Java. Is there any real reason for this?
Can I log into a web application automatically using a users windows logon?
500,260
0
3
4,695
0
python,authentication,web-applications,windows-authentication
To the best of my knowledge the only browser that automatically passes your login credentials is Internet Explorer. To enable this feature select "Enable Integrated Windows Authentication" in the advanced Internet options dialog under the security section. This is usually enabled by default. The web server will have to have the Anonymous user permission removed from the web application and enable windows authentication option checked. Simply add the users you want to have access to the web application to the file/folder permissions. I have only tried this with IIS so I'm not sure if it will work on other web servers.
0
0
0
0
2009-02-01T03:37:00.000
3
0
false
500,134
0
0
1
1
On the intranet at my part time job (not IT related) there are various web applications that we use that do not require logging in explicitly. We are required to login to Windows obviously, and that then authenticates us some how. I'm wondering how this is done? Without worrying about security TOO much, how would I go about authenticating a user to a web application, utilizing the windows login information? I'd be using Python (and Django). Are there limitations on how this can be achieved? For instance, would a specific browser be required? Would the application and intranet backend have to be hosted at the same location or at least have to communicate? Or is it simply getting the users Windows credentials, and passing that to the authentication software of the web application?
Using web.py as non blocking http-server
501,570
1
17
7,054
0
python,multithreading,web-services,web.py
Wouldn't is be simpler to re-write your main-loop code to be a function that you call over and over again, and then call that from the function that you pass to runsimple... It's guaranteed not to fully satisfy your requirements, but if you're in a rush, it might be easiest.
0
0
1
0
2009-02-01T14:47:00.000
4
0.049958
false
500,935
0
0
1
1
while learning some basic programming with python, i found web.py. i got stuck with a stupid problem: i wrote a simple console app with a main loop that proccesses items from a queue in seperate threads. my goal is to use web.py to add items to my queue and report status of the queue via web request. i got this running as a module but can´t integrate it into my main app. my problem is when i start the http server with app.run() it blocks my main loop. also tried to start it with thread.start_new_thread but it still blocks. is there an easy way to run web.py´s integrated http server in the background within my app. in the likely event that i am a victim of a fundamental missunderstanding, any attempt to clarify my error in reasoning would help ;.) ( please bear with me, i am a beginner :-)
pure web based versioning system
513,899
0
2
1,960
0
php,python,version-control,web-applications
Why dont you want a client..? A simple client that you can run on your production machine which then syncs to your repository running on another server somewhere. SVN is available over HTTP so writing a client that is able to sync your code is really easy in python or php.
0
0
0
1
2009-02-04T20:34:00.000
8
0
false
513,173
0
0
1
6
My hosting service does not currently run/allow svn, git, cvs on their server. I would really like to be able to 'sync' my current source on my development machine with my production server. I am looking for a pure php/python/ruby version control system (not just a client for a version control system) that does not require any services running on the server machine, something that could use the http interface to upload/download and sync files - basically offering a back end into my 'live' site for version control. Additionally, I would think that such a system would be easy to develop an 'online' ide for, so that I could develop directly on the production server. (issues of testing aside of course) Does anyone know if such a system exists? ==Edit== Really, I want a wiki front end for a version control / development system - Basically look like a wiki and edit development files so that I could easily make and roll back changes via the web. I doubt this exists, but it would be easy to extend an existing php port of svn...
pure web based versioning system
513,366
1
2
1,960
0
php,python,version-control,web-applications
I think it's actually a pretty good idea, but don't believe such a versioning system exists (yet) so hopefully you'll go ahead and make one. I don't think adapting an existing solution is going to be easy, but it's probably worth looking into because if you use an existing solution you'll have all the client support done, and most of the versioning difficulties taken care of. Starting from scratch is not going to be trivial. -Adam
0
0
0
1
2009-02-04T20:34:00.000
8
0.024995
false
513,173
0
0
1
6
My hosting service does not currently run/allow svn, git, cvs on their server. I would really like to be able to 'sync' my current source on my development machine with my production server. I am looking for a pure php/python/ruby version control system (not just a client for a version control system) that does not require any services running on the server machine, something that could use the http interface to upload/download and sync files - basically offering a back end into my 'live' site for version control. Additionally, I would think that such a system would be easy to develop an 'online' ide for, so that I could develop directly on the production server. (issues of testing aside of course) Does anyone know if such a system exists? ==Edit== Really, I want a wiki front end for a version control / development system - Basically look like a wiki and edit development files so that I could easily make and roll back changes via the web. I doubt this exists, but it would be easy to extend an existing php port of svn...
pure web based versioning system
513,231
7
2
1,960
0
php,python,version-control,web-applications
Get a better hosting service. Seriously. Even if you found something that worked in PHP/Ruby/Perl/Whatever, it would still be a sub-par solution. It most likely wouldn't integrate with any IDE you have, and wouldn't have a good tool set available for working with it. It would be really clunky to do correctly. The other option is to get a free SVN host, or host SVN on your own machine, and then just push updates from your SVN host to your web site via ftp.
0
0
0
1
2009-02-04T20:34:00.000
8
1
false
513,173
0
0
1
6
My hosting service does not currently run/allow svn, git, cvs on their server. I would really like to be able to 'sync' my current source on my development machine with my production server. I am looking for a pure php/python/ruby version control system (not just a client for a version control system) that does not require any services running on the server machine, something that could use the http interface to upload/download and sync files - basically offering a back end into my 'live' site for version control. Additionally, I would think that such a system would be easy to develop an 'online' ide for, so that I could develop directly on the production server. (issues of testing aside of course) Does anyone know if such a system exists? ==Edit== Really, I want a wiki front end for a version control / development system - Basically look like a wiki and edit development files so that I could easily make and roll back changes via the web. I doubt this exists, but it would be easy to extend an existing php port of svn...
pure web based versioning system
513,253
0
2
1,960
0
php,python,version-control,web-applications
you could try the reverse way use e.g. a free online svn/git Service to version control the sources on your dev machine use usual ways to update the "production" machine aka site, like FTP
0
0
0
1
2009-02-04T20:34:00.000
8
0
false
513,173
0
0
1
6
My hosting service does not currently run/allow svn, git, cvs on their server. I would really like to be able to 'sync' my current source on my development machine with my production server. I am looking for a pure php/python/ruby version control system (not just a client for a version control system) that does not require any services running on the server machine, something that could use the http interface to upload/download and sync files - basically offering a back end into my 'live' site for version control. Additionally, I would think that such a system would be easy to develop an 'online' ide for, so that I could develop directly on the production server. (issues of testing aside of course) Does anyone know if such a system exists? ==Edit== Really, I want a wiki front end for a version control / development system - Basically look like a wiki and edit development files so that I could easily make and roll back changes via the web. I doubt this exists, but it would be easy to extend an existing php port of svn...
pure web based versioning system
515,956
1
2
1,960
0
php,python,version-control,web-applications
Use Bazaar: Lightweight. No dedicated server with Bazaar installed is needed, just FTP access to a web server. A smart server is available for those requiring additional performance or security but it is not required in many cases - Bazaar 1.x over plain http performs well.
0
0
0
1
2009-02-04T20:34:00.000
8
0.024995
false
513,173
0
0
1
6
My hosting service does not currently run/allow svn, git, cvs on their server. I would really like to be able to 'sync' my current source on my development machine with my production server. I am looking for a pure php/python/ruby version control system (not just a client for a version control system) that does not require any services running on the server machine, something that could use the http interface to upload/download and sync files - basically offering a back end into my 'live' site for version control. Additionally, I would think that such a system would be easy to develop an 'online' ide for, so that I could develop directly on the production server. (issues of testing aside of course) Does anyone know if such a system exists? ==Edit== Really, I want a wiki front end for a version control / development system - Basically look like a wiki and edit development files so that I could easily make and roll back changes via the web. I doubt this exists, but it would be easy to extend an existing php port of svn...
pure web based versioning system
513,322
2
2
1,960
0
php,python,version-control,web-applications
Don't host your repository on your web server. Deploy from your server to the ftp/sftp - whatever.
0
0
0
1
2009-02-04T20:34:00.000
8
0.049958
false
513,173
0
0
1
6
My hosting service does not currently run/allow svn, git, cvs on their server. I would really like to be able to 'sync' my current source on my development machine with my production server. I am looking for a pure php/python/ruby version control system (not just a client for a version control system) that does not require any services running on the server machine, something that could use the http interface to upload/download and sync files - basically offering a back end into my 'live' site for version control. Additionally, I would think that such a system would be easy to develop an 'online' ide for, so that I could develop directly on the production server. (issues of testing aside of course) Does anyone know if such a system exists? ==Edit== Really, I want a wiki front end for a version control / development system - Basically look like a wiki and edit development files so that I could easily make and roll back changes via the web. I doubt this exists, but it would be easy to extend an existing php port of svn...
Mixed language source directory layout
518,493
2
5
1,166
0
java,python,sql,directory
I think the best thing to do would be to ensure that your various modules don't depend upon being in the same directory (i.e. separate by component). A lot of people seem to be deathly afraid of this idea, but a good set of build scripts should be able to automate away any pain. The end goal would be to make it easy to install the infrastructure, and then really easy to work on a single component once the environment is setup. (It's important to note that I come from the Perl and CL worlds, where we install "modules" into some global location, like ~/perl or ~/.sbcl, rather than including each module with each project, like Java people do. You'd think this would be a maintenance problem, but it ends up not being one. With a script that updates each module from your git repository (or CPAN) on a regular basis, it is really the best way.) Edit: one more thing: Projects always have external dependencies. My projects need Postgres and a working Linux install. It would be insane to bundle this with the app code in version control -- but a script to get everything setup on a fresh workstation is very helpful. I guess what I'm trying to say, in a roundabout way perhaps, is that I don't think you should treat your internal modules differently from external modules.
0
0
0
1
2009-02-05T16:57:00.000
2
0.197375
false
516,798
1
0
1
1
We are running a large project with several different languages: Java, Python, PHP, SQL and Perl. Until now people have been working in their own private repositories, but now we want to merge the entire project in a single repository. The question now is: how should the directory structure look? Should we have separate directories for each language, or should we separate it by component/project? How well does python/perl/java cope with a common directory layout?
How to work with unsaved many-to-many relations in django?
518,290
6
8
4,822
0
python,django,django-models,many-to-many
I would add a field which indicates whether the objects are "draft" or "live". That way they are persisted across requests, sessions, etc. and django stops complaining. You can then filter your objects to only show "live" objects in public views and only show "draft" objects to the user that created them. This can also be extended to allow "archived" objects (or any other state that makes sense).
0
0
0
0
2009-02-05T22:01:00.000
3
1
false
518,162
0
0
1
1
I have a couple of models in django which are connected many-to-many. I want to create instances of these models in memory, present them to the user (via custom method-calls inside the view-templates) and if the user is satisfied, save them to the database. However, if I try to do anything on the model-instances (call rendering methods, e.g.), I get an error message that says that I have to save the instances first. The documentation says that this is because the models are in a many-to-many relationship. How do I present objects to the user and allowing him/her to save or discard them without cluttering my database? (I guess I could turn off transactions-handling and do them myself throughout the whole project, but this sounds like a potentially error-prone measure...) Thx!
How to externally populate a Django model?
524,414
2
8
7,525
0
python,django,django-models
I've used cron to update my DB using both a script and a view. From cron's point of view it doesn't really matter which one you choose. As you've noted, though, it's hard to beat the simplicity of firing up a browser and hitting a URL if you ever want to update at a non-scheduled interval. If you go the view route, it might be worth considering a view that accepts the XML file itself via an HTTP POST. If that makes sense for your data (you don't give much information about that XML file), it would still work from cron, but could also accept an upload from a browser -- potentially letting the person who produces the XML file update the DB by themselves. That's a big win if you're not the one making the XML file, which is usually the case in my experience.
0
0
0
0
2009-02-07T17:54:00.000
4
0.099668
false
524,214
0
0
1
1
What is the best idea to fill up data into a Django model from an external source? E.g. I have a model Run, and runs data in an XML file, which changes weekly. Should I create a view and call that view URL from a curl cronjob (with the advantage that that data can be read anytime, not only when the cronjob runs), or create a python script and install that script as a cron (with DJANGO _SETTINGS _MODULE variable setup before executing the script)?
How would you set up a python web server with multiple vhosts?
537,504
1
1
1,401
0
python,webserver,environment,wsgi
I'd recommend Nginx for the web server. Fast and easy to set up. You'd probably want to have one unix user per vhost - so every home directory holds its own application, python environment and server configuration. This allows you to restart a particular app safely, simply by killing worker processes that your vhost owns. Just a tip, hope it helps.
0
0
0
0
2009-02-11T15:46:00.000
3
0.066568
false
537,399
1
0
1
1
I've been told wsgi is the way to go and not mod_python. But more specifically, how would you set up your multi website server environment? Choice of web server, etc?
Are there any good build frameworks written in Python?
3,838,805
2
16
2,630
0
python,build-process,build-automation
My Rapid Throughts: SCons is quite mature and oriented also to other languages (es C++) Waf is very simlar to ant/maven, so you will prefer it if you are used to ant/maven Paver is very pythonic oriented, and seems a good option if you do not know how to start.
0
0
0
1
2009-02-12T16:59:00.000
5
0.07983
false
542,289
0
0
1
1
I switched from NAnt to using Python to write build automation scripts. I am curious if whether any build frameworks worth using that are similar to Make, Ant, and NAnt, but, instead, are Python-based. For example, Ruby has Rake. What about Python?
Should I use Django's contrib applications or build my own?
542,685
7
3
297
0
python,django,django-contrib
It all depends. We had a need for something that was 98% similar to contrib.flatpages. We could have monkeypatched it, but we decided that the code was so straightforward that we would just copy and fork it. It worked out fine. Doing this with contrib.auth, on the other hand, might be a bad move given its interaction with contrib.admin & contrib.session.
0
0
0
0
2009-02-12T18:10:00.000
3
1.2
true
542,594
0
0
1
2
The Django apps come with their own features and design. If your requirements don't match 100% with the features of the contib app, you end up customizing and tweaking the app. I feel this involves more effort than just building your own app to fit your requirements. What do you think?
Should I use Django's contrib applications or build my own?
543,335
4
3
297
0
python,django,django-contrib
Most of the apps in django.contrib are written very well and are highly extensible. Don't like quite how comments works? Subclass the models and forms within it, adding your own functionality and you have a working comment system that fits your sites schema, with little effort. I think the best part when you extend the contrib apps is you're not really doing anything hacky, you're just writing (mostly) regular Python code to add the functionality.
0
0
0
0
2009-02-12T18:10:00.000
3
0.26052
false
542,594
0
0
1
2
The Django apps come with their own features and design. If your requirements don't match 100% with the features of the contib app, you end up customizing and tweaking the app. I feel this involves more effort than just building your own app to fit your requirements. What do you think?
Tool (or combination of tools) for reproducible environments in Python
545,839
0
9
1,538
0
python,continuous-integration,installation,development-environment,automated-deploy
I do exactly this with a combination of setuptools and Hudson. I know Hudson is a java app, but it can run Python stuff just fine.
0
1
0
0
2009-02-13T12:20:00.000
7
0
false
545,730
0
0
1
1
I used to be a java developer and we used tools like ant or maven to manage our development/testing/UAT environments in a standardized way. This allowed us to handle library dependencies, setting OS variables, compiling, deploying, running unit tests, and all the required tasks. Also, the scripts generated guaranteed that all the environments were almost equally configured, and all the task were performed in the same way by all the members of the team. I'm starting to work in Python now and I'd like your advice in which tools should I use to accomplish the same as described for java.
Simple unique non-priority queue system
549,555
1
1
2,069
0
python,queue
Why not use a list if you need order (or even a heapq, as was formerly suggested by zacherates before a set was suggested instead) and also use a set to check for duplicates?
0
0
1
0
2009-02-14T18:44:00.000
5
0.039979
false
549,536
0
0
1
1
I'm working on a simple web crawler in python and I wan't to make a simple queue class, but I'm not quite sure the best way to start. I want something that holds only unique items to process, so that the crawler will only crawl each page once per script run (simply to avoid infinite looping). Can anyone give me or point me to a simple queue example that I could run off of?
Favorite Django Tips & Features?
551,499
35
308
62,526
0
python,django,hidden-features
Add assert False in your view code to dump debug information.
0
0
0
0
2009-02-15T10:06:00.000
55
1
false
550,632
0
0
1
1
Inspired by the question series 'Hidden features of ...', I am curious to hear about your favorite Django tips or lesser known but useful features you know of. Please, include only one tip per answer. Add Django version requirements if there are any.
Python or Ruby for a .NET developer?
552,734
16
12
1,835
0
python,ruby-on-rails,ruby,comparison
Both languages are powerful and fun. Either would be a useful addition to your tool box. Python has a larger community and probably more mature documentation and libraries. Its object-orientation is a little inconsistent and feels (to me, IMHO) like something that was bolted on to the language. You can alter class behaviour at runtime (monkey-patching) but not for the precompiled classes and it's generally frowned-upon. Ruby might be a little more different to your current experience: it has some flavour of Smalltalk (method-calling is more correctly message-sending for example). Its object-orientation is built-in from scratch, all classes are open to modification and it's an accepted - if slightly scary - practise. The community is smaller, the libraries less mature and documentation coverage is less. Both languages will have some level of broken backward compatibility in their next majopr releases, both have .Net implementations (IronPython is production, IronRuby getting there). Both have web frameworks that reflect their strengths (search SO for the Django/Rails debate). If I'd never seen Ruby, I'd be very happy working in Python, and have done so without suffering when necessary. I always found myself wishing I could do the work in Ruby. But that's my opinion, YMMV. Edit: Come to think of it, and even though it pains me, if you're seeking to leverage your knowledge of the .Net framework, you might be best off looking at IronPython, as it's more mature than the Ruby equivalent.
0
0
0
1
2009-02-15T19:45:00.000
8
1.2
true
551,465
1
0
1
5
I'm a C# .NET developer and I work on mostly ASP.NET projects. I want to learn a new programming language, to improve my programming skills by experiencing a new language, to see something different then microsoft environment, and maybe to think in a different way. I focus on two languages for my goal. Python and Ruby. Which one do you offer for me ? Pros and cons of them on each other? Is it worth learning them ? EDIT : Sorry I editted my post but not inform here, Ruby on Rails replaced with Ruby.
Python or Ruby for a .NET developer?
551,484
6
12
1,835
0
python,ruby-on-rails,ruby,comparison
First... good for you for wanting to broaden your knowledge! Second, you are comparing a language (Python) with a web framework (Ruby on Rails). I think your best option is to try a few different frameworks in both Python and Ruby, do the same fairly simple task in each, and only then pick which one you'd like to learn more about. Rails is nice for Ruby, but it's not the only one out there. For Python I like Pylons and Django. Pros and cons: Ruby is a little cleaner, language-wise, than Python. Python has a much larger set of modules. Is it worth learning? Yes, to both Python and Ruby.
0
0
0
1
2009-02-15T19:45:00.000
8
1
false
551,465
1
0
1
5
I'm a C# .NET developer and I work on mostly ASP.NET projects. I want to learn a new programming language, to improve my programming skills by experiencing a new language, to see something different then microsoft environment, and maybe to think in a different way. I focus on two languages for my goal. Python and Ruby. Which one do you offer for me ? Pros and cons of them on each other? Is it worth learning them ? EDIT : Sorry I editted my post but not inform here, Ruby on Rails replaced with Ruby.
Python or Ruby for a .NET developer?
552,177
2
12
1,835
0
python,ruby-on-rails,ruby,comparison
Rule of thumb - Python if you like strict rules and Ruby if you hate them. Another one: if you adore JavaScript - Ruby is your choice :)
0
0
0
1
2009-02-15T19:45:00.000
8
0.049958
false
551,465
1
0
1
5
I'm a C# .NET developer and I work on mostly ASP.NET projects. I want to learn a new programming language, to improve my programming skills by experiencing a new language, to see something different then microsoft environment, and maybe to think in a different way. I focus on two languages for my goal. Python and Ruby. Which one do you offer for me ? Pros and cons of them on each other? Is it worth learning them ? EDIT : Sorry I editted my post but not inform here, Ruby on Rails replaced with Ruby.
Python or Ruby for a .NET developer?
555,166
2
12
1,835
0
python,ruby-on-rails,ruby,comparison
What? No mention of IronPython? IronPython is the flagship language of the DLR. It allows you to use all the familiar .NET libraries, but through Python. I would definitely try Python and IronPython. You'll learn a lot and might even sneak it into your current projects (you can embed an IronPython engine in a .NET application).
0
0
0
1
2009-02-15T19:45:00.000
8
0.049958
false
551,465
1
0
1
5
I'm a C# .NET developer and I work on mostly ASP.NET projects. I want to learn a new programming language, to improve my programming skills by experiencing a new language, to see something different then microsoft environment, and maybe to think in a different way. I focus on two languages for my goal. Python and Ruby. Which one do you offer for me ? Pros and cons of them on each other? Is it worth learning them ? EDIT : Sorry I editted my post but not inform here, Ruby on Rails replaced with Ruby.
Python or Ruby for a .NET developer?
552,126
0
12
1,835
0
python,ruby-on-rails,ruby,comparison
I'd get in on Ruby. Seems to have a larger (or at least more active) community, the pace of new projects & continued development is second-to-none, and the learning resources seem to outnumber & outpace those of Python. I could be wrong, but these are my impressions.
0
0
0
1
2009-02-15T19:45:00.000
8
0
false
551,465
1
0
1
5
I'm a C# .NET developer and I work on mostly ASP.NET projects. I want to learn a new programming language, to improve my programming skills by experiencing a new language, to see something different then microsoft environment, and maybe to think in a different way. I focus on two languages for my goal. Python and Ruby. Which one do you offer for me ? Pros and cons of them on each other? Is it worth learning them ? EDIT : Sorry I editted my post but not inform here, Ruby on Rails replaced with Ruby.
How to get distinct Django apps on same subdomain to share session cookie?
659,606
8
8
6,592
0
python,django,deployment,session,cookies
I agree that sharing sessions between Django instances is probably not a good idea. If you really wanted to, you could: make sure the two django applications share the same SECRET_KEY make sure the two django applications share the same SeSSON_COOKIE_NAME make sure the SESSION_COOKIE_DOMAIN is set to something that lets the two instances share cookies. (If they really share the same subdomain, your current setting is probably fine.) make sure both Django instances use the same session backend (the same database, the same file directory, the same memcached config, etc.) make sure that anything put into the session makes sense in both Django databases: at the very least, that'll include the user id, since Django auth uses that to remember which user is logged in. All that said, I haven't actually tried all this, so you may still have trouble!
0
0
0
0
2009-02-17T13:58:00.000
2
1
false
556,907
0
0
1
2
We have a couple of Django applications deployed on the same subdomain. A few power users need to jump between these applications. I noticed that each time they bounce between applications their session cookie receives a new session ID from Django. I don't use the Django session table much except in one complex workflow. If the user bounces between applications while in this workflow they lose their session and have to start over. I dug through the Django session code and discovered that the: django.conf.settings.SECRET_KEY is used to perform an integrity check on the sessions on each request. If the integrity check fails, a new session is created. Realizing this, I changed the secret key in each of these applications to use the same value, thinking this would allow the integrity check to pass and allow them to share Django sessions. However, it didn't seem to work. Is there a way to do this? Am I missing something else? Thanks in advance
How to get distinct Django apps on same subdomain to share session cookie?
557,020
18
8
6,592
0
python,django,deployment,session,cookies
I would instead advise you to set SESSION_COOKIE_NAME to different values for the two apps. Your users will still have to log in twice initially, but their sessions won't conflict - if they log in to app A, then app B, and return to A, they'll still have their A session. Sharing sessions between Django instances is probably not a good idea. If you want some kind of single-sign-on, look into something like django-cas. You'll still have 2 sessions (as you should), but the user will only log in once.
0
0
0
0
2009-02-17T13:58:00.000
2
1.2
true
556,907
0
0
1
2
We have a couple of Django applications deployed on the same subdomain. A few power users need to jump between these applications. I noticed that each time they bounce between applications their session cookie receives a new session ID from Django. I don't use the Django session table much except in one complex workflow. If the user bounces between applications while in this workflow they lose their session and have to start over. I dug through the Django session code and discovered that the: django.conf.settings.SECRET_KEY is used to perform an integrity check on the sessions on each request. If the integrity check fails, a new session is created. Realizing this, I changed the secret key in each of these applications to use the same value, thinking this would allow the integrity check to pass and allow them to share Django sessions. However, it didn't seem to work. Is there a way to do this? Am I missing something else? Thanks in advance
How to re-use a reusable app in Django
3,710,136
2
22
3,945
0
python,django,code-reuse
An old question, but here's what I do: If you're using a version control system (VCS), I suggest putting all of the reusable apps and libraries (including django) that your software needs in the VCS. If you don't want to put them directly under your project root, you can modify settings.py to add their location to sys.path. After that deployment is as simple as cloning or checking out the VCS repository to wherever you want to use it. This has two added benefits: Version mismatches; your software always uses the version that you tested it with, and not the version that was available at the time of deployment. If multiple people work on the project, nobody else has to deal with installing the dependencies. When it's time to update a component's version, update it in your VCS and then propagate the update to your deployments via it.
0
0
0
0
2009-02-17T14:50:00.000
2
0.197375
false
557,171
0
0
1
1
I am trying to create my first site in Django and as I'm looking for example apps out there to draw inspiration from, I constantly stumble upon a term called "reusable apps". I understand the concept of an app that is reusable easy enough, but the means of reusing an app in Django are quite lost for me. Few questions that are bugging me in the whole business are: What is the preferred way to re-use an existing Django app? Where do I put it and how do I reference it? From what I understand, the recommendation is to put it on your "PYTHONPATH", but that breaks as soon as I need to deploy my app to a remote location that I have limited access to (e.g. on a hosting service). So, if I develop my site on my local computer and intend to deploy it on an ISP where I only have ftp access, how do I re-use 3rd party Django apps so that if I deploy my site, the site keeps working (e.g. the only thing I can count on is that the service provider has Python 2.5 and Django 1.x installed)? How do I organize my Django project so that I could easily deploy it along with all of the reusable apps I want to use?
Eclipse PyDev: setting breakpoints in site-packages source
561,957
5
5
4,282
0
python,django,eclipse,pydev
Have you imported the Django source as a project? To do that you just create a new PyDev project and set it's location to the Django source folder.
0
0
0
0
2009-02-17T22:25:00.000
4
1.2
true
558,999
0
0
1
2
I am debugging a problem in Django with Pydev. I can set breakpoint in my django project code with out a problem. However I can't set breakpoints in the Django library source code (in site-packages). The PyDev debugger user interface in this case simply does nothing when I click to set the breakpoint and does not break at that location when I run the debugger. Am I missing some PyDev configuration? In other debuggers I have used, this behavior indicates a problem relating the debug information with the source code. Any ideas on next steps would be a help. I also have the site-packages configured in PyDev to be in my PYTHONPATH I am using Eclipse on Max OS X if that helps. Thanks
Eclipse PyDev: setting breakpoints in site-packages source
2,516,750
0
5
4,282
0
python,django,eclipse,pydev
PyDev 1.5.5 seems to have an issue with Eclipse. Uninstall 1.5.5 and install the 1.5.4 version
0
0
0
0
2009-02-17T22:25:00.000
4
0
false
558,999
0
0
1
2
I am debugging a problem in Django with Pydev. I can set breakpoint in my django project code with out a problem. However I can't set breakpoints in the Django library source code (in site-packages). The PyDev debugger user interface in this case simply does nothing when I click to set the breakpoint and does not break at that location when I run the debugger. Am I missing some PyDev configuration? In other debuggers I have used, this behavior indicates a problem relating the debug information with the source code. Any ideas on next steps would be a help. I also have the site-packages configured in PyDev to be in my PYTHONPATH I am using Eclipse on Max OS X if that helps. Thanks
Check whether a PDF-File is valid with Python
584,225
0
22
32,854
0
python,file,pdf
By valid do you mean that it can be displayed by a PDF viewer, or that the text can be extracted? They are two very different things. If you just want to check that it really is a PDF file that has been uploaded then the pyPDF solution, or something similar, will work. If, however, you want to check that the text can be extracted then you have found a whole world of pain! Using pdftotext would be a simple solution that would work in a majority of cases but it is by no means 100% successful. We have found many examples of PDFs that pdftotext cannot extract from but Java libraries such as iText and PDFBox can.
0
0
0
0
2009-02-17T22:53:00.000
7
0
false
559,096
0
0
1
1
I get a File via a HTTP-Upload and need to be sure its a pdf-file. Programing Language is Python, but this should not matter. I thought of the following solutions: Check if the first bytes of the string are "%PDF". This is not a good check but prevents the use from uploading other files accidentally. Try the libmagic (the "file" command on the bash uses it). This does exactly the same check as in (1) Take a lib and try to read the page-count out of the file. If the lib is able to read a pagecount it should be a valid pdf. Problem: I dont know a lib for python which can do this So anybody got any solutions for a lib or another trick?
Anybody tried mosso CloudFiles with Google AppEngine?
564,966
1
1
310
0
python,google-app-engine,storage,cloud,mosso
It appears to implement a simple RESTful API, so there's no reason you couldn't use it from App Engine. Previously, you'd have had to write your own library to do so, using App Engine's urlfetch API, but with the release of SDK 1.1.9, you can now use urllib and httplib instead.
0
1
0
0
2009-02-19T09:01:00.000
1
1.2
true
564,460
0
0
1
1
I'm wondering if anybody tried to integrate mosso CloudFiles with an application running on Google AppEngine (mosso does not provide testing sandbox so I cann't check for myself without registering)? Looking at the code it seems that this will not work due to httplib and urllib limitations in AppEngine environment, but maybe somebody has patched cloudfiles?
Parsing HTML generated from Legacy ASP Application to create ASP.NET 2.0 Pages
568,228
0
0
307
0
c#,.net,python,html
Just found HTML agility pack to be useful enough, as they understand C# better than python.
0
0
0
0
2009-02-19T13:19:00.000
3
0
false
565,264
0
0
1
2
One of my friends is working on having a good solution to generate aspx pages, out of html pages generated from a legacy asp application. The idea is to run the legacy app, capture html output, clean the html using some tool (say HtmlTidy) and parse it/transform it to aspx, (using Xslt or a custom tool) so that existing html elements, divs, images, styles etc gets converted neatly to an aspx page (too much ;) ). Any existing tools/scripts/utilities to do the same?
Parsing HTML generated from Legacy ASP Application to create ASP.NET 2.0 Pages
1,664,516
0
0
307
0
c#,.net,python,html
I know this is an old question, but in a similar situation (50k+ legacy ASP pages that need to display in a .NET framework), I did the following. Created a rewrite engine (HttpModule) which catches all incoming requests and looks for anything that is from the old site. (in a separate class - keep things organized!) use WebClient or HttpRequest, etc to open a connection to the old server and download the rendered HTML. Use the HTML agility toolkit (very slick) to extract the content that I'm interested in - in our case, this is always inside if a div with the class "bdy". Throw this into a cache - a SQL table in this example. Each hit checks the cache and either a)retrieves the page and builds the cache entry, or b) just gets the page from the cache. An aspx page built specifically for displaying legacy content receives the rewrite request and displays the relevant content from the legacy page inside of an asp literal control. The cache is there for performance - since the first request for a given page has a minimum of two hits - one from the browser to the new server, one from the new server to the old server - I store cachable data on the new server so that subsequent requests don't have to go back to the old server. We also cache images, css, scripts, etc. It gets messy when you have to handle forms, cookies, etc, but these can all be stored in your cache and passed through to the old server with each request if necessary. I also store content expiration dates and other headers that I get back from the legacy server and am sure to pass those back to the browser when rendering the cached page. Just remember to take as content-agnostic an approach as possible. You're effectively building an in-page web proxy that lets IIS render old ASP the way it wants, and manipulating the output. Works very well - I have all of the old pages working seamlessly within our ASP.NET app. This saved us a solid year of development time that would have been required if we had to touch every legacy asp page. Good luck!
0
0
0
0
2009-02-19T13:19:00.000
3
0
false
565,264
0
0
1
2
One of my friends is working on having a good solution to generate aspx pages, out of html pages generated from a legacy asp application. The idea is to run the legacy app, capture html output, clean the html using some tool (say HtmlTidy) and parse it/transform it to aspx, (using Xslt or a custom tool) so that existing html elements, divs, images, styles etc gets converted neatly to an aspx page (too much ;) ). Any existing tools/scripts/utilities to do the same?
Preventing BeautifulSoup from converting my XML tags to lowercase
568,081
4
10
1,662
0
python,xml,beautifulsoup
No, that's not a built-in option. The source is pretty straightforward, though. It looks like you want to change the value of encodedName in Tag.__str__.
0
0
1
0
2009-02-20T01:52:00.000
2
1.2
true
567,999
0
0
1
1
I am using BeautifulStoneSoup to parse an XML document and change some attributes. I noticed that it automatically converts all XML tags to lowercase. For example, my source file has <DocData> elements, which BeautifulSoup converts to <docdata>. This appears to be causing problems since the program I am feeding my modified XML document to does not seem to accept the lowercase versions. Is there a way to prevent this behavior in BeautifulSoup?
Django: multiple models in one template using forms
569,763
3
124
119,625
0
python,django,django-forms
"I want to hide some of the fields and do some complex validation." I start with the built-in admin interface. Build the ModelForm to show the desired fields. Extend the Form with the validation rules within the form. Usually this is a clean method. Be sure this part works reasonably well. Once this is done, you can move away from the built-in admin interface. Then you can fool around with multiple, partially related forms on a single web page. This is a bunch of template stuff to present all the forms on a single page. Then you have to write the view function to read and validated the various form things and do the various object saves(). "Is it a design issue if I break down and hand-code everything?" No, it's just a lot of time for not much benefit.
0
0
0
0
2009-02-20T12:50:00.000
7
0.085505
false
569,468
0
0
1
1
I'm building a support ticket tracking app and have a few models I'd like to create from one page. Tickets belong to a Customer via a ForeignKey. Notes belong to Tickets via a ForeignKey as well. I'd like to have the option of selecting a Customer (that's a whole separate project) OR creating a new Customer, then creating a Ticket and finally creating a Note assigned to the new ticket. Since I'm fairly new to Django, I tend to work iteratively, trying out new features each time. I've played with ModelForms but I want to hide some of the fields and do some complex validation. It seems like the level of control I'm looking for either requires formsets or doing everything by hand, complete with a tedious, hand-coded template page, which I'm trying to avoid. Is there some lovely feature I'm missing? Does someone have a good reference or example for using formsets? I spent a whole weekend on the API docs for them and I'm still clueless. Is it a design issue if I break down and hand-code everything?
Set up a scheduled job?
7,287,891
2
567
206,437
0
python,django,web-applications,scheduled-tasks
I had something similar with your problem today. I didn't wanted to have it handled by the server trhough cron (and most of the libs were just cron helpers in the end). So i've created a scheduling module and attached it to the init . It's not the best approach, but it helps me to have all the code in a single place and with its execution related to the main app.
0
0
0
0
2009-02-21T19:39:00.000
24
0.016665
false
573,618
0
0
1
1
I've been working on a web app using Django, and I'm curious if there is a way to schedule a job to run periodically. Basically I just want to run through the database and make some calculations/updates on an automatic, regular basis, but I can't seem to find any documentation on doing this. Does anyone know how to set this up? To clarify: I know I can set up a cron job to do this, but I'm curious if there is some feature in Django that provides this functionality. I'd like people to be able to deploy this app themselves without having to do much config (preferably zero). I've considered triggering these actions "retroactively" by simply checking if a job should have been run since the last time a request was sent to the site, but I'm hoping for something a bit cleaner.
How do YOU deploy your WSGI application? (and why it is the best way)
612,622
3
42
14,313
0
python,deployment,wsgi
Apache httpd + mod_fcgid using web.py (which is a wsgi application). Works like a charm.
0
0
0
1
2009-02-22T00:58:00.000
9
0.066568
false
574,068
0
0
1
4
Deploying a WSGI application. There are many ways to skin this cat. I am currently using apache2 with mod-wsgi, but I can see some potential problems with this. So how can it be done? Apache Mod-wsgi (the other mod-wsgi's seem to not be worth it) Pure Python web server eg paste, cherrypy, Spawning, Twisted.web as 2 but with reverse proxy from nginx, apache2 etc, with good static file handling Conversion to other protocol such as FCGI with a bridge (eg Flup) and running in a conventional web server. More? I want to know how you do it, and why it is the best way to do it. I would absolutely love you to bore me with details about the whats and the whys, application specific stuff, etc. I will upvote any non-insane answer.
How do YOU deploy your WSGI application? (and why it is the best way)
612,607
1
42
14,313
0
python,deployment,wsgi
We are using pure Paste for some of our web services. It is easy to deploy (with our internal deployment mechanism; we're not using Paste Deploy or anything like that) and it is nice to minimize the difference between production systems and what's running on developers' workstations. Caveat: we don't expect low latency out of Paste itself because of the heavyweight nature of our requests. In some crude benchmarking we did we weren't getting fantastic results; it just ended up being moot due to the expense of our typical request handler. So far it has worked fine. Static data has been handled by completely separate (and somewhat "organically" grown) stacks, including the use of S3, Akamai, Apache and IIS, in various ways.
0
0
0
1
2009-02-22T00:58:00.000
9
0.022219
false
574,068
0
0
1
4
Deploying a WSGI application. There are many ways to skin this cat. I am currently using apache2 with mod-wsgi, but I can see some potential problems with this. So how can it be done? Apache Mod-wsgi (the other mod-wsgi's seem to not be worth it) Pure Python web server eg paste, cherrypy, Spawning, Twisted.web as 2 but with reverse proxy from nginx, apache2 etc, with good static file handling Conversion to other protocol such as FCGI with a bridge (eg Flup) and running in a conventional web server. More? I want to know how you do it, and why it is the best way to do it. I would absolutely love you to bore me with details about the whats and the whys, application specific stuff, etc. I will upvote any non-insane answer.
How do YOU deploy your WSGI application? (and why it is the best way)
616,720
1
42
14,313
0
python,deployment,wsgi
Apache+mod_wsgi, Simple, clean. (only four lines of webserver config), easy for other sysadimns to get their head around.
0
0
0
1
2009-02-22T00:58:00.000
9
0.022219
false
574,068
0
0
1
4
Deploying a WSGI application. There are many ways to skin this cat. I am currently using apache2 with mod-wsgi, but I can see some potential problems with this. So how can it be done? Apache Mod-wsgi (the other mod-wsgi's seem to not be worth it) Pure Python web server eg paste, cherrypy, Spawning, Twisted.web as 2 but with reverse proxy from nginx, apache2 etc, with good static file handling Conversion to other protocol such as FCGI with a bridge (eg Flup) and running in a conventional web server. More? I want to know how you do it, and why it is the best way to do it. I would absolutely love you to bore me with details about the whats and the whys, application specific stuff, etc. I will upvote any non-insane answer.
How do YOU deploy your WSGI application? (and why it is the best way)
635,680
6
42
14,313
0
python,deployment,wsgi
Nginx reverse proxy and static file sharing + XSendfile + uploadprogress_module. Nothing beats it for the purpose. On the WSGI side either Apache + mod_wsgi or cherrypy server. I like to use cherrypy wsgi server for applications on servers with less memory and less requests. Reasoning: I've done benchmarks with different tools for different popular solutions. I have more experience with lower level TCP/IP than web development, especially http implementations. I'm more confident that I can recognize a good http server than I can recognize a good web framework. I know Twisted much more than Django or Pylons. The http stack in Twisted is still not up to this but it will be there.
0
0
0
1
2009-02-22T00:58:00.000
9
1
false
574,068
0
0
1
4
Deploying a WSGI application. There are many ways to skin this cat. I am currently using apache2 with mod-wsgi, but I can see some potential problems with this. So how can it be done? Apache Mod-wsgi (the other mod-wsgi's seem to not be worth it) Pure Python web server eg paste, cherrypy, Spawning, Twisted.web as 2 but with reverse proxy from nginx, apache2 etc, with good static file handling Conversion to other protocol such as FCGI with a bridge (eg Flup) and running in a conventional web server. More? I want to know how you do it, and why it is the best way to do it. I would absolutely love you to bore me with details about the whats and the whys, application specific stuff, etc. I will upvote any non-insane answer.
Python web programming
582,467
1
12
2,349
0
python,cherrypy
When you use mod_python on a threaded Apache server (the default on Windows), CherryPy runs in the same process as Apache. In that case, you almost certainly don't want CP to restart the process. Solution: use mod_rewrite or mod_proxy so that CherryPy runs in its own process. Then you can autoreload to your heart's content. :)
0
0
0
0
2009-02-24T09:15:00.000
5
0.039979
false
581,038
0
0
1
2
Good morning. As the title indicates, I've got some questions about using python for web development. What is the best setup for a development environment, more specifically, what webserver to use, how to bind python with it. Preferably, I'd like it to be implementable in both, *nix and win environment. My major concern when I last tried apache + mod_python + CherryPy was having to reload webserver to see the changes. Is it considered normal? For some reason cherrypy's autoreload didn't work at all. What is the best setup to deploy a working Python app to production and why? I'm now using lighttpd for my PHP web apps, but how would it do for python compared to nginx for example? Is it worth diving straight with a framework or to roll something simple of my own? I see that Django has got quite a lot of fans, but I'm thinking it would be overkill for my needs, so I've started looking into CherryPy. How exactly are Python apps served if I have to reload httpd to see the changes? Something like a permanent process spawning child processes, with all the major file includes happening on server start and then just lazy loading needed resources? Python supports multithreading, do I need to look into using that for a benefit when developing web apps? What would be that benefit and in what situations? Big thanks!
Python web programming
581,356
8
12
2,349
0
python,cherrypy
What is the best setup for a development environment? Doesn't much matter. We use Django, which runs in Windows and Unix nicely. For production, we use Apache in Red Hat. Is having to reload webserver to see the changes considered normal? Yes. Not clear why you'd want anything different. Web application software shouldn't be dynamic. Content yes. Software no. In Django, we develop without using a web server of any kind on our desktop. The Django "runserver" command reloads the application under most circumstances. For development, this works great. The times when it won't reload are when we've damaged things so badly that the app doesn't properly. What is the best setup to deploy a working Python app to production and why? "Best" is undefined in this context. Therefore, please provide some qualification for "nest" (e.g., "fastest", "cheapest", "bluest") Is it worth diving straight with a framework or to roll something simple of my own? Don't waste time rolling your own. We use Django because of the built-in admin page that we don't have to write or maintain. Saves mountains of work. How exactly are Python apps served if I have to reload httpd to see the changes? Two methods: Daemon - mod_wsgi or mod_fastcgi have a Python daemon process to which they connect. Change your software. Restart the daemon. Embedded - mod_wsgi or mod_python have an embedded mode in which the Python interpreter is inside the mod, inside Apache. You have to restart httpd to restart that embedded interpreter. Do I need to look into using multi-threaded? Yes and no. Yes you do need to be aware of this. No, you don't need to do very much. Apache and mod_wsgi and Django should handle this for you.
0
0
0
0
2009-02-24T09:15:00.000
5
1
false
581,038
0
0
1
2
Good morning. As the title indicates, I've got some questions about using python for web development. What is the best setup for a development environment, more specifically, what webserver to use, how to bind python with it. Preferably, I'd like it to be implementable in both, *nix and win environment. My major concern when I last tried apache + mod_python + CherryPy was having to reload webserver to see the changes. Is it considered normal? For some reason cherrypy's autoreload didn't work at all. What is the best setup to deploy a working Python app to production and why? I'm now using lighttpd for my PHP web apps, but how would it do for python compared to nginx for example? Is it worth diving straight with a framework or to roll something simple of my own? I see that Django has got quite a lot of fans, but I'm thinking it would be overkill for my needs, so I've started looking into CherryPy. How exactly are Python apps served if I have to reload httpd to see the changes? Something like a permanent process spawning child processes, with all the major file includes happening on server start and then just lazy loading needed resources? Python supports multithreading, do I need to look into using that for a benefit when developing web apps? What would be that benefit and in what situations? Big thanks!
What are good ways to upload bulk .csv data into a webapp using Django/Python?
588,212
1
2
2,198
0
jquery,python,django,django-models,csv
Look at csv module from stdlib. It contains presets for popualr CSV dialects like one produced by Excel. Reader class support field mapping and if file contains column header it coes not depend on column order. For more complex logic, like looking up several alternative names for a field, you'll need to write your own implementation.
0
0
0
0
2009-02-25T15:39:00.000
6
0.033321
false
586,517
0
0
1
2
I have a very basic CSV file upload module working to bulk upload my user's data into my site. I process the CSV file in the backend with a python script that runs on crontab and then email the user the results of the bulk upload. This process works ok operationally, but my issue is with the format of the csv file. Are there good tools or even basic rules on how to accept different formats of the csv file? The user may have a different order of data columns, slightly different names for the column headers (I want the email column to be entitled "Email", but it may say "Primary Email", "Email Address"), or missing additional data columns. Any good examples of CSV upload functionality that is very permissive and user friendly? Also, how do I tell the user to export as CSV data? I'm importing address book information, so this data often comes from Outlook, Thunderbird, other software packages that have address books. Are there other popular data formats that I should accept?
What are good ways to upload bulk .csv data into a webapp using Django/Python?
586,694
1
2
2,198
0
jquery,python,django,django-models,csv
If you'll copy excel table into clipboard and then paste results into notepad, you'll notice that it's tab separated. I once used it to make bulk import from most of table editors by copy-pasting data from the editor into textarea on html page. You can use a background for textarea as a hint for number of columns and place your headers at the top suggesting the order for a user. Javascript will process pasted data and display them to the user immediately with simple prevalidation making it easy to fix an error and repaste. Then import button is clicked, data is validated again and import results are displayed. Unfortunately, I've never heard any feedback about whenever this was easy to use or not. Anyway, I still see it as an option when implementing bulk import.
0
0
0
0
2009-02-25T15:39:00.000
6
0.033321
false
586,517
0
0
1
2
I have a very basic CSV file upload module working to bulk upload my user's data into my site. I process the CSV file in the backend with a python script that runs on crontab and then email the user the results of the bulk upload. This process works ok operationally, but my issue is with the format of the csv file. Are there good tools or even basic rules on how to accept different formats of the csv file? The user may have a different order of data columns, slightly different names for the column headers (I want the email column to be entitled "Email", but it may say "Primary Email", "Email Address"), or missing additional data columns. Any good examples of CSV upload functionality that is very permissive and user friendly? Also, how do I tell the user to export as CSV data? I'm importing address book information, so this data often comes from Outlook, Thunderbird, other software packages that have address books. Are there other popular data formats that I should accept?
Is there a Django apps pattern equivalent in Google App Engine?
591,169
3
3
715
0
python,django,design-patterns,google-app-engine,django-apps
The Django implementation of apps is closely tied to Django operation as a framework - I mean plugging application using Django url mapping features (for mapping urls to view functions) and Django application component discovery (for discovering models and admin configuration). There is no such mechanisms in WebApp (I guess you think of WebApp framework when you refer to AppEngine, which is rather platform) itself - you have to write them by yourself then persuade people to write such applications in a way that will work with your url plugger and component discovery after plugging app to the rest of site code. There are generic pluggable modules, ready to use with AppEngine, like sharded counters or GAE utilities library, but they do not provide such level of functionality like Django apps (django-registration for example). I thing this comes from much greater freedom of design (basically, on GAE you can model your app after Django layout or after any other you might think of) and lack of widely used conventions.
0
1
0
0
2009-02-25T23:09:00.000
2
1.2
true
588,342
0
0
1
1
Django has a very handy pattern known as "apps". Essentially, a self-contained plug-in that requires a minimal amount of wiring, configuring, and glue code to integrate into an existing project. Examples are tagging, comments, contact-form, etc. They let you build up large projects by gathering together a collection of useful apps, rather than writing everything from scratch. The apps you do end up writing can be made portable so you can recycle them in other projects. Does this pattern exist in Google App Engine? Is there any way to create self-contained apps that can be easily be dropped into an App Engine project? Right off the bat, the YAML url approach looks like it could require a significant re-imagining to the way its done in Django. Note: I know I can run Django on App Engine, but that's not what I'm interested in doing this time around.
Does the stack limit of Symbian also apply to PyS60?
595,330
3
3
417
0
python,symbian,nokia,pys60
Yes, PyS60 is based on CPython, thus uses the C stack.
1
0
0
0
2009-02-27T15:48:00.000
4
0.148885
false
595,296
0
0
1
4
Symbian has a stack limit of 8kB. Does this also apply to the function calling in PyS60 apps?
Does the stack limit of Symbian also apply to PyS60?
606,180
1
3
417
0
python,symbian,nokia,pys60
Increasing the Symbian stack size is done through a parameter in the mmp file. This is valid when you create a native application that the toolchain will turn into an exe file. If you were to upgrade the Python runtime on your phone, with a version you built yourself, you could increase the stack size of the runtime process itself.
1
0
0
0
2009-02-27T15:48:00.000
4
0.049958
false
595,296
0
0
1
4
Symbian has a stack limit of 8kB. Does this also apply to the function calling in PyS60 apps?
Does the stack limit of Symbian also apply to PyS60?
685,145
0
3
417
0
python,symbian,nokia,pys60
I would assume that PyS60 should be doing the memory management for you, as your program will probably be constrained by the resources of PyS60.
1
0
0
0
2009-02-27T15:48:00.000
4
0
false
595,296
0
0
1
4
Symbian has a stack limit of 8kB. Does this also apply to the function calling in PyS60 apps?
Does the stack limit of Symbian also apply to PyS60?
915,134
1
3
417
0
python,symbian,nokia,pys60
There is a difference between python runtime and python apps. Also from PyS60 app developer point of view, it's the heapsize that's more interesting... Version 1.9.5 comes by default with heapsize 100k min and 4M max. Of course you can define those by yourself when creating the SIS package to release and distribute your application. Sorry if I answered right question with wrong answer (stack vs heap). Stack is usually "enough", but with deep enough recursion you can run out of it. Have done it - and fixed some endless loops :) Never had any real stack problems. Usually it's the heap that runs out, esp with graphics manipulation.
1
0
0
0
2009-02-27T15:48:00.000
4
1.2
true
595,296
0
0
1
4
Symbian has a stack limit of 8kB. Does this also apply to the function calling in PyS60 apps?
FOSS HTML to PDF in Python, .Net or command line?
597,840
0
0
1,517
0
c#,.net,python,html-to-pdf
You can also try different approach like using virtual printers.
0
0
0
0
2009-02-28T01:56:00.000
5
0
false
597,348
0
0
1
1
I have google as much as I possible, checked stackoverflow several times, and yet I can not find a good html to pdf converter that can handle css. Is there a free and open source solution (even for commercial usage)? There are many solutions, with huge variety of price ranges, but I was looking for something open source and free. I have tried PISA for Python and it works fairly well, but is not free for commercial usage. Is there anything for .Net? I have not had success with iTextSharp.
What SHOULDN'T Django's admin interface be used for?
599,054
5
4
352
0
python,django,administration
Generally, you shouldn't use the admin for access by people you don't really trust. Even though there's plenty of flexibility in terms of locking things down and controlling access (much more so since Django 1.0), the admin is still designed on the assumption that the people using it are trusted members of your staff.
0
0
0
0
2009-02-28T20:00:00.000
2
0.462117
false
598,577
0
0
1
2
I've been applying Django's automatic administration capabilities to some applications who had previously been very difficult to administer. I'm thinking of a lot of ways to apply it to other applications we use (including using it to replace some internal apps altogether). Before I go overboard though, is there anything in particular I shouldn't use it for?
What SHOULDN'T Django's admin interface be used for?
598,580
7
4
352
0
python,django,administration
User-specific privileges. I myself had been trying to work it into that-- some of the new (and at least at the time, undocumented) features (from newforms-admin) make it actually possible. Depending on how fine you want the control to be, though, you can end up getting very, very deep into the Django/admin internals. Just because you can doesn't mean you should-- it's easier and less fragile to do so with a custom admin app.
0
0
0
0
2009-02-28T20:00:00.000
2
1.2
true
598,577
0
0
1
2
I've been applying Django's automatic administration capabilities to some applications who had previously been very difficult to administer. I'm thinking of a lot of ways to apply it to other applications we use (including using it to replace some internal apps altogether). Before I go overboard though, is there anything in particular I shouldn't use it for?
How to make Satchmo work in Google App Engine
833,823
2
4
1,984
0
python,google-app-engine,e-commerce,satchmo
Nothing is impossible - this will just require lots of effort - if there will be somebody wishing to do so - why not? But it might be easier (cheaper) to get Django friendly hosting instead of spending hours on hacking the code.
0
0
0
0
2009-03-01T18:22:00.000
3
0.132549
false
600,225
0
0
1
1
I understand that there are big differences in data-store, but surely since django is bundled and it abstracts data-store away from Satchmo, something can be done? Truth is that I am not a Python guy, been mostly Java/PHP thus far, but I am willing to learn. Plus, if this is not possible today, lets band together and form a new Open Source project to "extend" satchmo or perhaps branch it, for compatibility?
Should I use GeoDjango for mapping a floor plan?
614,489
1
7
3,422
0
python,django,mapping,geodjango
How often will the floor plan change? From your description a simple image with a imagemap would suffice.
0
0
0
0
2009-03-02T06:34:00.000
4
0.049958
false
601,442
0
0
1
2
I want to create a floor plan map of an interior space that has clickable regions. My first thought was to investigate GeoDjango since its the mapping app for Django. But considering the dependencies, the learning curve and overall complexity, I'm concerned that I may be trying to swat a fly with a bazooka. Should I use GeoDjango for this, or should I just store integer lists in a database field? EDIT: The floor plan would be fairly simple; a collection of walls and workstations with the ability to define regions for how much space the workstation occupies, thus allowing offices to be defined as well as open plan layouts.
Should I use GeoDjango for mapping a floor plan?
613,955
5
7
3,422
0
python,django,mapping,geodjango
I'd say that using GeoDjango for this purpose is definitely overkill. It could be implemented simply with an image map, or Canvas/SVG or Flash for extra pretty-points :)
0
0
0
0
2009-03-02T06:34:00.000
4
1.2
true
601,442
0
0
1
2
I want to create a floor plan map of an interior space that has clickable regions. My first thought was to investigate GeoDjango since its the mapping app for Django. But considering the dependencies, the learning curve and overall complexity, I'm concerned that I may be trying to swat a fly with a bazooka. Should I use GeoDjango for this, or should I just store integer lists in a database field? EDIT: The floor plan would be fairly simple; a collection of walls and workstations with the ability to define regions for how much space the workstation occupies, thus allowing offices to be defined as well as open plan layouts.
Store last created model's row in memory
603,637
0
0
127
1
python,django
You'd either have to use a cache, or fetch the most recent change on each request (since you can't persist objects between requests in-memory). From what you describe, it sounds as if it's being hit fairly frequently, so the cache is probably the way to go.
0
0
0
0
2009-03-02T11:46:00.000
4
0
false
602,030
1
0
1
1
I am working on ajax-game. The abstract: 2+ gamers(browsers) change a variable which is saved to DB through json. All gamers are synchronized by javascript-timer+json - periodically reading that variable from DB. In general, all changes are stored in DB as history, but I want the recent change duplicated in memory. So the problem is: i want one variable to be stored in memory instead of DB.
Differential AJAX updates for HTML table?
602,381
1
2
981
0
jquery,python,html,dhtml
Without thinking of deltas: You can use JSON quite easily to do this sort of thing. You can roll out your own compressed format, too. I think compressing the data using gzip would help a lot. Most browsers nowadays support it, and it will greatly reduce the size of your responses.
0
0
0
0
2009-03-02T13:17:00.000
3
0.066568
false
602,322
0
0
1
1
I have a game that's based on a 25x20 HTML table (the game board). Every 3 seconds the user can "move," which sends an AJAX request to the server, at which time the server rerenders the entire HTML table and sends it to the user. This was easy to write, but it wastes a lot of bandwidth. Are there any libraries, client (preferably jquery) or server-side, that help send differential instead of full updates for large tables? Usually only 5-10 tiles change on a given reload, so I feel like I could cut bandwidth use by an order of magnitude by sending just those tiles instead of all 500 every 3 seconds. I'm also open to "you idiot, why are you using HTML tables"-type comments if you can suggest a better alternative. For example are there any CSS/DOM manipulation techniques I should be considering instead of using an HTML table? Should I use a table but give each td coordinates for an id (like "12x08") and then use jquery to replace cells by id? A clarification: the tiles are text, not images.
IronPython memory usage
613,533
0
2
1,344
0
performance,ironpython
Turns out, after aspnet_wp goes to about 500mb, the garbage collector kicks in and cleans out the mess. The memory usage then drops to about 20mb and steadily starts increasing again during load testing. So there's no memory 'leak' as such.
1
0
0
1
2009-03-04T11:11:00.000
3
1.2
true
610,128
0
0
1
2
I'm hosting IronPython in a c#-based WebService to be able to provide custom extension scripts. However, I'm finding that memory usage sharply increases when I do simple load testing by executing the webservice repeatedly in a loop. IronPython-1.1 implemented IDisposable on its objects so that you can dispose of them when they are done. The new IronPython-2 engine based on the DLR has no such concept. From what I understood, everytime you execute a script in the ScriptEngine a new assembly is injected in the appdomain and can't be unloaded. Is there any way around this?
IronPython memory usage
611,623
1
2
1,344
0
performance,ironpython
You could try creating a new AppDomain every time you run one of your IronPython scripts. Although assebmlies cannot be unloaded from memory you can unload an AppDomain and this will allow you to get the injected assembly out of memory.
1
0
0
1
2009-03-04T11:11:00.000
3
0.066568
false
610,128
0
0
1
2
I'm hosting IronPython in a c#-based WebService to be able to provide custom extension scripts. However, I'm finding that memory usage sharply increases when I do simple load testing by executing the webservice repeatedly in a loop. IronPython-1.1 implemented IDisposable on its objects so that you can dispose of them when they are done. The new IronPython-2 engine based on the DLR has no such concept. From what I understood, everytime you execute a script in the ScriptEngine a new assembly is injected in the appdomain and can't be unloaded. Is there any way around this?
Django Model Inheritance. Hiding or removing fields
611,725
4
10
6,399
0
python,python-3.x,django,django-models,django-admin
If you are inheriting the model then it is probably not wise to attempt to hide or disable any existing fields. The best thing you could probably do is exactly what you suggested: override save() and handle your logic in there.
0
0
0
0
2009-03-04T17:49:00.000
5
1.2
true
611,691
0
0
1
1
I want to inherit a model class from some 3rd party code. I won't be using some of the fields but want my client to be able to edit the model in Admin. Is the best bet to hide them from Admin or can I actually prevent them being created in the first place? Additionally - what can I do if one of the unwanted fields is required? My first thought is to override the save method and just put in a default value.
Can you give a Django app a verbose name for use throughout the admin?
612,955
6
151
84,109
0
python,django
No, but you can copy admin template and define app name there.
0
0
0
0
2009-03-04T20:51:00.000
14
1
false
612,372
0
0
1
1
In the same way that you can give fields and models verbose names that appear in the Django admin, can you give an app a custom name?
Tools to ease executing raw SQL with Django ORM
620,117
3
2
3,263
1
python,django,orm
Since the issue is "manually converting query results into objects," the simplest solution is often to see if your custom SQL can fit into an ORM .extra() call rather than being a pure-SQL query. Often it can, and then you let the ORM do all the work of building up objects as usual.
0
0
0
0
2009-03-06T16:11:00.000
3
1.2
true
619,384
0
0
1
1
I often need to execute custom sql queries in django, and manually converting query results into objects every time is kinda painful. I wonder how fellow Slackers deal with this. Maybe someone had written some kind of a library to help dealing with custom SQL in Django?
Choosing and deploying a comet server
622,509
5
13
7,360
0
python,django,comet,daemon
I would recommend looking into Twisted, their twisted.web server, and the comet work done on top of it at Divmod. They can handle far more concurrent connections than traditional thread or process based servers, which is exactly what you need for something like this. And, yes, I've architected systems using Twisted for COMET stuff, while using other things for the more front-facing web applications beside it. It works out well with each part doing what it does best.
0
1
0
0
2009-03-07T12:51:00.000
6
1.2
true
621,802
0
0
1
1
I want to push data to the browser over HTTP without killing my django/python application. I decided to use a comet server, to proxy requests between my application and the client (though I still haven't really figured it out properly). I've looked into the following engines: orbited cometd ejabberd jetty Has anyone had any experience working with these servers and deploying them? Any insight and links regarding the topics would be great. Thank you.
For my app, how many threads would be optimal?
623,070
13
3
2,509
0
python,multithreading
You will probably find your application is bandwidth limited not CPU or I/O limited. As such, add as many as you like until performance begins to degrade. You may come up against other limits depending on your network setup. Like if you're behind an ADSL router, there will be a limit on the number of concurrent NAT sessions, which may impact making too many HTTP requests at once. Make too many and your provider may treat you as being infected by a virus or the like. There's also the issue of how many requests the server you're crawling can handle and how much of a load you want to put on it. I wrote a crawler once that used just one thread. It took about a day to process all the information I wanted at about one page every two seconds. I could've done it faster but I figured this was less of a burden for the server. So really theres no hard and fast answer. Assuming a 1-5 megabit connection I'd say you could easily have up to 20-30 threads without any problems.
0
0
0
0
2009-03-08T04:44:00.000
7
1.2
true
623,054
1
0
1
3
I have a simple Python web crawler. It uses SQLite to store its output and also to keep a queue. I want to make the crawler multi-threaded so that it can crawl several pages at a time. I figured i would make a thread and just run several instances of the class at once, so they all run concurrently. But the question is, how many should i run at once? should i stick to two? can i go higher? what would be a reasonable limit for a number of threads? Keep in mind that each thread goes out to a web page, downloads the html, runs a few regex searches through it, stores the info it finds in a SQLite db, and then pops the next url off the queue.
For my app, how many threads would be optimal?
623,064
3
3
2,509
0
python,multithreading
It's usually simpler to make multiple concurrent processes. Simply use subprocess to create as many Popens as you feel it necessary to run concurrently. There's no "optimal" number. Generally, when you run just one crawler, your PC spends a lot of time waiting. How much? Hard to say. When you're running some small number of concurrent crawlers, you'll see that they take about the same amount of time as one. Your CPU switches among the various processes, filling up the wait time on one with work on the others. You you run some larger number, you see that the overall elapsed time is longer because there's now more to do than your CPU can manage. So the overall process takes longer. You can create a graph that shows how the process scales. Based on this you can balance the number of processes and your desirable elapsed time. Think of it this way. 1 crawler does it's job in 1 minute. 100 pages done serially could take a 100 minutes. 100 crawlers concurrently might take on hour. Let's say that 25 crawlers finishes the job in 50 minutes. You don't know what's optimal until you run various combinations and compare the results.
0
0
0
0
2009-03-08T04:44:00.000
7
0.085505
false
623,054
1
0
1
3
I have a simple Python web crawler. It uses SQLite to store its output and also to keep a queue. I want to make the crawler multi-threaded so that it can crawl several pages at a time. I figured i would make a thread and just run several instances of the class at once, so they all run concurrently. But the question is, how many should i run at once? should i stick to two? can i go higher? what would be a reasonable limit for a number of threads? Keep in mind that each thread goes out to a web page, downloads the html, runs a few regex searches through it, stores the info it finds in a SQLite db, and then pops the next url off the queue.
For my app, how many threads would be optimal?
623,515
1
3
2,509
0
python,multithreading
One thing you should keep in mind is that some servers may interpret too many concurrent requests from the same IP address as a DoS attack and abort connections or return error pages for requests that would otherwise succeed. So it might be a good idea to limit the number of concurrent requests to the same server to a relatively low number (5 should be on the safe side).
0
0
0
0
2009-03-08T04:44:00.000
7
0.028564
false
623,054
1
0
1
3
I have a simple Python web crawler. It uses SQLite to store its output and also to keep a queue. I want to make the crawler multi-threaded so that it can crawl several pages at a time. I figured i would make a thread and just run several instances of the class at once, so they all run concurrently. But the question is, how many should i run at once? should i stick to two? can i go higher? what would be a reasonable limit for a number of threads? Keep in mind that each thread goes out to a web page, downloads the html, runs a few regex searches through it, stores the info it finds in a SQLite db, and then pops the next url off the queue.
What should I be aware of when moving from asp.net to python for web development?
624,119
4
3
390
0
asp.net,python
I second the note by Out Into Space on how python is a language versus a web framework; it's an important observation that underlies pretty much everything you will experience in moving from ASP.NET to Python. On a similar note, you will also find that the differences in language style and developer community between C#/VB.NET and Python influence the basic approach to developing web frameworks. This would be the same whether you were moving from web frameworks written in java, php, ruby, perl or any other language for that matter. The old "when you have a hammer, everything looks like a nail" adage really shows in the basic design of the frameworks :-) Because of this, though, you will find yourself with a few paradigm shifts to make when you substitute that hammer for a screwdriver. For example, Python web frameworks rely much less on declarative configuration than ASP.NET. Django, for example, has only a single config file that really has only a couple dozen lines (once you strip out the comments :-) ). Similarly, URL configuration and the page lifecycle are quite compact compared to ASP.NET, while being just as powerful. There's more "convention" over configuration (though much less so that Rails), and heavy use of the fact that modules in Python are top-level objects in the language... not everything has to be a class. This cuts down on the amount of code involved, and makes the application flow highly readable. As Out Into Space mentioned, zope's page templates are "somewhat" similar to ASP.NET master page, but not exactly. Django also offers page templates that inherit from each other, and they work very well, but not if you're trying to use them like an ASP.NET template. There also isn't a tradition of user controls in Python web frameworks a la .NET. The configuration machinery, request/response process indirection, handler complexity, and code-library size is just not part of the feel that python developers have for their toolset. We all argue that you can build the same web application, with probably less code, and more easily debuggable/maintainable using pythonic-tools :-) The main benefit here being that you also get to take advantage of the python language, and a pythonic framework, which is what makes python developers happy to go to work in the morning. YMMV, of course. All of which to say, you'll find you can do everything you've always done, just differently. Whether or not the differences please or frustrate you will determine if a python web framework is the right tool for you in the long run.
0
0
0
0
2009-03-08T18:34:00.000
3
0.26052
false
624,062
1
0
1
2
I'm thinking about converting an app from Asp.net to python. I would like to know: what are the key comparisons to be aware of when moving a asp.net app to python(insert framework)? Does python have user controls? Master pages?
What should I be aware of when moving from asp.net to python for web development?
637,273
0
3
390
0
asp.net,python
Most frameworks for python has a 'templating' engine which provide similar functionality of ASP.NET's Master pages and User Controls. :) Thanks for the replies Out Of Space and Jarret Hardie
0
0
0
0
2009-03-08T18:34:00.000
3
0
false
624,062
1
0
1
2
I'm thinking about converting an app from Asp.net to python. I would like to know: what are the key comparisons to be aware of when moving a asp.net app to python(insert framework)? Does python have user controls? Master pages?
How can I customize the output from pygments?
624,717
1
1
3,304
0
python,html,css,pygments
Pass full=True to the HtmlFormatter constructor.
0
0
0
0
2009-03-08T21:37:00.000
4
0.049958
false
624,345
0
0
1
1
If I run a python source file through pygments, it outputs html code whose elements class belong to some CSS file pygments is using. Could the style attributes be included in the outputted html so that I don't have to provide a CSS file?
Using Django admin look and feel in my own application
625,235
4
1
1,834
0
python,django,django-admin,styles,look-and-feel
Are you sure you want to take every bit of admin-site's look & feel?? I think you would need to customize some, as in header footer etc. To do that, just copy base.html from "djangosrc/contrib/admin/templates/admin/" and keep it in "your_template_dir/admin/base.html" or "your_template_dir/admin/mybase.html" Just change whatever HTML you want to customize and keep rest as it is (like CSS and Javascript) and keep on extending this template in other templates of your application. Your view should provide what it needs to render (take a look at any django view from source) and you'll have everything what admin look & feel had. More you can do by extending base_site.html in same manner. (Note: if you keep the name 'base.html' the changes made in html will affect Django Admin too. As this is the way we change how Django Admin look itself.)
0
0
0
0
2009-03-08T23:22:00.000
2
1.2
true
624,535
0
0
1
1
I like the very simple but still really elegant look and feel of the django admin and I was wondering if there is a way to apply it to my own application. (I think that I've read something like that somewhere, but now I cannot find the page again.) (edited: what I am looking for is a way to do it automatically by extending templates, importing modules, or something similar, not just copy&paste the css and javascript code)
Why aren't signals simply called events?
624,865
24
4
676
0
python,signals,django-signals
Actually, "signals" have been around longer than events have. In the earliest usage, a signal was an asynchronous way for processes to get notified that events had occurred. Since Unix is much older than Django (and since a lot of the Django work came from pydispatcher, where the original stuff was done), the name has stuck. Events are really signals, you might say!
0
0
0
0
2009-03-09T02:42:00.000
4
1.2
true
624,844
0
0
1
3
From what I can tell, in Python and and Django, signals are simply delegated events. Is there anything that functionally differentiates them from the typical notion of events in C#, Java, ActionScript, etc?
Why aren't signals simply called events?
624,860
1
4
676
0
python,signals,django-signals
You might as well ask "Why aren't events simply called signals?". Differences in terminology happen.
0
0
0
0
2009-03-09T02:42:00.000
4
0.049958
false
624,844
0
0
1
3
From what I can tell, in Python and and Django, signals are simply delegated events. Is there anything that functionally differentiates them from the typical notion of events in C#, Java, ActionScript, etc?
Why aren't signals simply called events?
624,855
4
4
676
0
python,signals,django-signals
Signals typically have an association with an operating system facility and events are typically application-defined. In some technology stacks, the OS-level stuff may be hidden well enough that there isn't a difference in the API, but in others perhaps not.
0
0
0
0
2009-03-09T02:42:00.000
4
0.197375
false
624,844
0
0
1
3
From what I can tell, in Python and and Django, signals are simply delegated events. Is there anything that functionally differentiates them from the typical notion of events in C#, Java, ActionScript, etc?
What will be the upgrade path to Python 3.x for Google App Engine Applications?
625,632
1
9
4,490
0
python,google-app-engine
The app.yaml syntax already supports multiple languages and multiple API versions, though only one of each (Python, API version 1) is currently supported. Presumably, one of those extension mechanisms will be used to specify that you want Python 3, and it'll be up to you to port your app over to work in Python 3, then change that setting.
0
1
0
0
2009-03-09T04:43:00.000
4
0.049958
false
625,042
1
0
1
2
What is required to make the transition to Python 3.x for Google App Engine? I know Google App Engine requires the use of at least Python 2.5. Is it possible to use Python 3.0 already on Google App Engine?
What will be the upgrade path to Python 3.x for Google App Engine Applications?
625,130
1
9
4,490
0
python,google-app-engine
At least at the being, Guido was working closely with the team at Google who is building AppEngine. When this option does become available, you will have to edit your main XAML file. I agree with Chris B. that Python 3.0 support may not be forthcoming too soon, but I'm not sure I agree that it will come sooner than Perl or PHP. At the Google I/O conference last year, they were very mum on what future languages they would support on AppEngine but they were pretty clear on the fact that they're actively exploring how to safely allow other code to run. One of the main reason they chose to support Python is that they due to it's dynamically compiled nature, they could support 3rd party library extensions with the minimal restriction that all add-ons must be in pure Python. I wouldn't be surprised if Python 3.0 support was introduced sooner than new languages.
0
1
0
0
2009-03-09T04:43:00.000
4
0.049958
false
625,042
1
0
1
2
What is required to make the transition to Python 3.x for Google App Engine? I know Google App Engine requires the use of at least Python 2.5. Is it possible to use Python 3.0 already on Google App Engine?
Dump memcache keys from GAE SDK Console?
626,559
8
1
2,662
0
python,google-app-engine,memcached
People ask for this on the memcached list a lot, sometimes with the same type of "just in case I want to look around to debug something" sentiment. The best way to handle this is to know how you generate your keys, and just go look stuff up when you want to know what's stored for a given value. If you have too many things using memcached to do that within the scope of your debugging session, then start logging access. But keep in mind -- memcached is fast because it doesn't allow for such things in general. The community server does have limited functionality to get a subset of the keys available within a given slab class, but it's probably not what you really want, and hopefully google doesn't implement it in theirs. :)
0
1
0
0
2009-03-09T07:49:00.000
5
1.2
true
625,314
0
0
1
4
In the "Memcache Viewer", is there any way to dump a list of existing keys? Just for debugging, of course, not for use in any scripts! I ask because it doesn't seem like the GAE SDK is using a "real" memcache server, so I'm guessing it's emulated in Python (for simplicity, as it's just a development server).. This would mean there is a dict somewhere with the keys/values..
Dump memcache keys from GAE SDK Console?
625,331
4
1
2,662
0
python,google-app-engine,memcached
No. I did not found such functionality in memcached too. Thinking about this issue, I found this limitation understandable - it would require keeping a registry of keys with all related problems like key expiration, invalidation and of course locking. Such system would not be as fast as memcaches are intended to be.
0
1
0
0
2009-03-09T07:49:00.000
5
0.158649
false
625,314
0
0
1
4
In the "Memcache Viewer", is there any way to dump a list of existing keys? Just for debugging, of course, not for use in any scripts! I ask because it doesn't seem like the GAE SDK is using a "real" memcache server, so I'm guessing it's emulated in Python (for simplicity, as it's just a development server).. This would mean there is a dict somewhere with the keys/values..
Dump memcache keys from GAE SDK Console?
626,458
0
1
2,662
0
python,google-app-engine,memcached
Memcache is designed to be quick and there's no convincing use case for this functionality which would justify the overhead required for a command that is so at odds with the rest of memcached. The GAE SDK is simulating memcached, so it doesn't offer this functionality either.
0
1
0
0
2009-03-09T07:49:00.000
5
0
false
625,314
0
0
1
4
In the "Memcache Viewer", is there any way to dump a list of existing keys? Just for debugging, of course, not for use in any scripts! I ask because it doesn't seem like the GAE SDK is using a "real" memcache server, so I'm guessing it's emulated in Python (for simplicity, as it's just a development server).. This would mean there is a dict somewhere with the keys/values..
Dump memcache keys from GAE SDK Console?
660,458
0
1
2,662
0
python,google-app-engine,memcached
The easiest way that I could think of, would be to maintain a memcache key at a known ID, and then append to it every time you insert a new key. This way you could just query for the single key to get a list of existing keys.
0
1
0
0
2009-03-09T07:49:00.000
5
0
false
625,314
0
0
1
4
In the "Memcache Viewer", is there any way to dump a list of existing keys? Just for debugging, of course, not for use in any scripts! I ask because it doesn't seem like the GAE SDK is using a "real" memcache server, so I'm guessing it's emulated in Python (for simplicity, as it's just a development server).. This would mean there is a dict somewhere with the keys/values..
Is there a way to configure the Application Pool's "Idle timeout" in web.config?
627,740
5
15
13,542
0
iis,web-config,application-pool,python-idle
Not in IIS 6. In IIS 6, Application Pools are controlled by Worker Processes, which map to a Request Queue handled by HTTP.sys. HTTP.sys handles the communication with the WWW Server to determine when to start and stop Worker Processes. Since IIS 6 was created before .Net, there's no communication hooks between .Net and the low-level http handlers. ASP.net is implimented as an ISAPI filter, which is loaded by the Worker Process itself. You have a chicken-before-the-egg issue if you are looking at the web.config controlling a worker process. This is primarily why MS did the major re-write of IIS 7 which integrates .Net through the entire request life-cycle, not just the ISAPI filter portion.
0
0
0
0
2009-03-09T09:57:00.000
3
1.2
true
625,614
0
0
1
1
I know one can set the session timeout. But, if the application itself has received no requests for a given period of time, IIS shuts down the application. This behavior is configurable in the IIS management console, and I know how to do this. Still, I wonder if it is possible to configure this in web.config.
Python equivalent to java.util.SortedSet?
20,666,684
0
22
9,278
0
python,data-structures
Do you have the possibility of using Jython? I just mention it because using TreeMap, TreeSet, etc. is trivial. Also if you're coming from a Java background and you want to head in a Pythonic direction Jython is wonderful for making the transition easier. Though I recognise that use of TreeSet in this case would not be part of such a "transition". For Jython superusers I have a question myself: the blist package can't be imported because it uses a C file which must be imported. But would there be any advantage of using blist instead of TreeSet? Can we generally assume the JVM uses algorithms which are essentially as good as those of CPython stuff?
0
0
0
0
2009-03-09T21:58:00.000
7
0
false
628,192
1
1
1
1
Does anybody know if Python has an equivalent to Java's SortedSet interface? Heres what I'm looking for: lets say I have an object of type foo, and I know how to compare two objects of type foo to see whether foo1 is "greater than" or "less than" foo2. I want a way of storing many objects of type foo in a list L, so that whenever I traverse the list L, I get the objects in order, according to the comparison method I define. Edit: I guess I can use a dictionary or a list and sort() it every time I modify it, but is this the best way?
Deploying Google Analytics With Django
629,888
2
38
19,916
0
python,django,deployment,google-analytics
I mostly agree with Ned, although I have a single setting called IS_LIVE_SITE which toggles analytics code, adverts and a few other things. This way I can keep all the keys in subversion (as it is a pain to look them up) and still toggle them on or off easily.
0
0
0
0
2009-03-10T11:09:00.000
10
0.039979
false
629,696
0
0
1
2
We're about to deploy a new Django website, and we want to use Google Analytics to keep track of traffic on the site. However, we don't want all of the hits on development instances to contribute to the Google Analytics statistics. There are a few ways we could deal with this: have a configuration option in settings.py which the base template uses to decide whether or not to include the appropriate <script> elements, maintain a branch which we pull into before deploying to the production server, which we ensure includes the <script> elements, do something with Google Analytics to block hits to 127.0.0.1 or localhost, or something else. The first option seems the most sensible, but I'm not sure if it is. For example, would we have to start passing a google_analytics variable into all of our views? What are your thoughts?
Deploying Google Analytics With Django
633,029
2
38
19,916
0
python,django,deployment,google-analytics
Instead of including the script tag directly in your html, just change the analytics javascript so it only runs if the href does not contain your prod site's name. This will work without any extra configuration.
0
0
0
0
2009-03-10T11:09:00.000
10
0.039979
false
629,696
0
0
1
2
We're about to deploy a new Django website, and we want to use Google Analytics to keep track of traffic on the site. However, we don't want all of the hits on development instances to contribute to the Google Analytics statistics. There are a few ways we could deal with this: have a configuration option in settings.py which the base template uses to decide whether or not to include the appropriate <script> elements, maintain a branch which we pull into before deploying to the production server, which we ensure includes the <script> elements, do something with Google Analytics to block hits to 127.0.0.1 or localhost, or something else. The first option seems the most sensible, but I'm not sure if it is. For example, would we have to start passing a google_analytics variable into all of our views? What are your thoughts?
Ruby on Rails versus Python
639,650
16
13
26,861
0
python,ruby
Ruby gets more attention than Python simply because Ruby has one clear favourite when it comes to web apps while Python has traditionally had a very splintered approach (Zope, Plone, Django, Pylons, Turbogears). The critical mass of having almost all developers using one system as opposed to a variety of individual ones does a lot for improving documentation, finding and removing bugs, building hype and buzz, and so on. In actual language terms the two are very similar in all but syntax, and Python is more popular generally. Python's perhaps been hindered by being popular in its own right before web frameworks became a big deal, making it harder for the community to agree to concentrate on any single approach.
0
0
0
0
2009-03-12T11:06:00.000
4
1
false
638,150
0
0
1
2
I am in the field of data crunching and very soon might make a move to the world of web programming. Although I am fascinated both by Python and Ruby as both of them seem to be having every similar styles when it comes to writing business logic or data crunching logic. But when I start googling for web development I start inclining towards Ruby on Rails my question is why is the web world obsessed with ruby on rails and active records so much? There seem to be so many screencasts to learn Ruby on Rails and plethora of good books too why is Python not able to pull the crowd when it comes to creating screencasts or ORM's like active record.
Ruby on Rails versus Python
639,045
3
13
26,861
0
python,ruby
Ruby and Python have more similarities than differences; the same is true for Rails and Django, which are the leading web frameworks in the respective languages. Both languages and both frameworks are likely to be rewarding to work with - in personal, "fun" terms at least - I don't know what the job markets are like in the specific areas. There are some similar questions in StackOverflow: you could do worse than clicking around the "Related" list in the right-hand sidebar to get more feel. Best thing is to get and try both: pick a small project and build it both ways. Decide which you like better and go for it!
0
0
0
0
2009-03-12T11:06:00.000
4
0.148885
false
638,150
0
0
1
2
I am in the field of data crunching and very soon might make a move to the world of web programming. Although I am fascinated both by Python and Ruby as both of them seem to be having every similar styles when it comes to writing business logic or data crunching logic. But when I start googling for web development I start inclining towards Ruby on Rails my question is why is the web world obsessed with ruby on rails and active records so much? There seem to be so many screencasts to learn Ruby on Rails and plethora of good books too why is Python not able to pull the crowd when it comes to creating screencasts or ORM's like active record.
Architecture for social multiplayer browser game (backend choice + frontend choice [flash/silverlight])
1,255,224
6
4
5,154
0
.net,silverlight,multiplayer,python-stackless
I spent a year working on a massively multiplayer online game using Silverlight for the frontend and Python for the backend (I actually used IronPython in Silverlight so as to simplify development) Silverlight is very well suited for this, I wouldn't do a serious online game in anything else. It already has 35% of the market, by the time you're done developing it should be high enough not to matter much anymore. For serious games, most people really won't mind installing a 4MB browser plugin. If you just want a little asteroids clone, use flash. If I had to do it over, I think I would keep Python for the server, because it's the server technology I'm most skilled with, but I think I'd use C# on the frontend and use JSON for passing data. The best advice I can give you is: Make use of existing libraries and code as much as possible Don't think about performance prematurely The toughest part is going to be finishing the game, use technology you know well, and optimize for your time, not the code. Hopefully you can do what I could not - finish the damn game :) Edit Regarding why I'd use C# if I had to do it over: IronPython had it's advantages and disadvantages. It was great that I could share code files (constants, models, etc) across server and client. Making a change and refreshing the browser to see it was awesome. Debugging was not as friendly as C#. But in some ways it's a second class citizen to C#, data binding didn't work, and you can't use IronPython classes in xaml. Loading time was a problem, so I actually spent a great deal of effort to set up importing in parallel on background threads to speed it up. Because of the second citizen status where xaml is concerned, I used a template language to generate the xaml as if it were html, which actually worked out better than data binding, but no python template languages worked in IronPython, so I wrote my own (another time sink.) To enable sharing models I had to write my own ORM. That was easy enough. But to transfer them I passed on JSON and made an optimized binary format instead that worked between IronPython and Python. That was another time sink. In hindsight I shouldn't have gotten distracted by all those rabbit trails.
0
0
0
0
2009-03-12T11:48:00.000
3
1
false
638,272
0
0
1
1
I'm thinking about developing online multiplayer social game. The shared state of the world would require something fast on the backend, so the potential solutions seem to be: fast game engine on server (eg. c++ ) and some frontend language (php/python/ruby) + flash whole stack in python (using twisted or stackless python) + flash .NET (asp.net or asp.net mvc) + flash .NET + silverlight first one may be an overkill from productivity point of view (3 heterogenous layers) Nr. 4 may be programmer's heaven (common environment on all layers), but: No such thing has been ever built with Silverlight, maybe there are some showstoppers hiding around the corner It may be hard to find silverlight designers Despite Flash movie/clip model being criticized when compared to SL full OO architecture isn't it an advantage when it comes to designing extra parts of the virtual world by external designers? They can just prepare .swf with eg. 4 perspectives of an item on 4 frames - wouldn't it be harder with SL? Silvelight apparently lacks in some gaming features (like collision detection) what do you think? [EDIT] The game itself would be part of the bigger portal - hence it would be nice to integrate the engine with some web framework.
PHP vs. long-running process (Python, Java, etc.)?
639,435
1
5
1,789
0
php,python
PHP is fine for either use in my opinion, the performance overheads are rarely noticed. It's usually other processes which will delay the program. It's easy to cache PHP programs with something like eAccelerator.
0
0
0
1
2009-03-12T16:22:00.000
5
0.039979
false
639,409
0
0
1
3
I'd like to have your opinion about writing web apps in PHP vs. a long-running process using tools such as Django or Turbogears for Python. As far as I know: - In PHP, pages are fetched from the hard-disk every time (although I assume the OS keeps files in RAM for a while after they've been accessed) - Pages are recompiled into opcode every time (although tools from eg. Zend can keep a compiled version in RAM) - Fetching pages every time means reading global and session data every time, and re-opening connections to the DB So, I guess PHP makes sense on a shared server (multiple sites sharing the same host) to run apps with moderate use, while a long-running process offers higher performance with apps that run on a dedicated server and are under heavy use? Thanks for any feedback.
PHP vs. long-running process (Python, Java, etc.)?
639,537
3
5
1,789
0
php,python
After you apply memcache, opcode caching, and connection pooling, the only real difference between PHP and other options is that PHP is short-lived, processed based, while other options are, typically, long-lived multithreaded based. The advantage PHP has is that its dirt simple to write scripts. You don't have to worry about memory management (its always released at the end of the request), and you don't have to worry about concurrency very much. The major disadvantage, I can see anyways, is that some more advanced (sometimes crazier?) things are harder: pre-computing results, warming caches, reusing existing data, request prioritizing, and asynchronous programming. I'm sure people can think of many more. Most of the time, though, those disadvantages aren't a big deal. You can scale by adding more machines and using more caching. The average web developer doesn't need to worry about concurrency control or memory management, so taking the minuscule hit from removing them isn't a big deal.
0
0
0
1
2009-03-12T16:22:00.000
5
0.119427
false
639,409
0
0
1
3
I'd like to have your opinion about writing web apps in PHP vs. a long-running process using tools such as Django or Turbogears for Python. As far as I know: - In PHP, pages are fetched from the hard-disk every time (although I assume the OS keeps files in RAM for a while after they've been accessed) - Pages are recompiled into opcode every time (although tools from eg. Zend can keep a compiled version in RAM) - Fetching pages every time means reading global and session data every time, and re-opening connections to the DB So, I guess PHP makes sense on a shared server (multiple sites sharing the same host) to run apps with moderate use, while a long-running process offers higher performance with apps that run on a dedicated server and are under heavy use? Thanks for any feedback.
PHP vs. long-running process (Python, Java, etc.)?
640,138
0
5
1,789
0
php,python
As many others have noted, PHP nor Django are going to be your bottlenecks. Hitting the hard disk for the bytecode on PHP is irrelevant for a heavily trafficked site because caching will take over at that point. The same is true for Django. Model/View and user experience design will have order of magnitude benefits to performance over the language itself.
0
0
0
1
2009-03-12T16:22:00.000
5
0
false
639,409
0
0
1
3
I'd like to have your opinion about writing web apps in PHP vs. a long-running process using tools such as Django or Turbogears for Python. As far as I know: - In PHP, pages are fetched from the hard-disk every time (although I assume the OS keeps files in RAM for a while after they've been accessed) - Pages are recompiled into opcode every time (although tools from eg. Zend can keep a compiled version in RAM) - Fetching pages every time means reading global and session data every time, and re-opening connections to the DB So, I guess PHP makes sense on a shared server (multiple sites sharing the same host) to run apps with moderate use, while a long-running process offers higher performance with apps that run on a dedicated server and are under heavy use? Thanks for any feedback.
Can anyone point out the pros and cons of TG2 over Django?
703,311
15
7
2,475
0
python,django,turbogears,turbogears2
TG2 has several advantages that I think are important: Multi-database support sharding/data partitioning support longstanding support for aggregates, multi-column primary keys a transaction system that handles multi-database transactions for you an admin system that works with all of the above out of the box support for reusable template snipits an easy method for creating reusable template tag-libraries more flexibility in using non-standard components There are more, but I think it's also important to know that Django has some advantages over TG2: Larger, community, more active IRC channel more re-usable app-components a bit more developed documentation All of this means that it's a bit easier to get started in Django than TG2, but I personally think the added power and flexibility that you get is worth it. But your needs may always be different.
0
0
0
0
2009-03-12T23:26:00.000
8
1
false
640,877
0
0
1
4
Django is my favorite python web framework. I've tried out others like pylons, web2py, nevow and others. But I've never looked into TurboGears with much enthusiasm. Now with TG2 out of beta I may give it a try. I'd like to know what are some of the pros and cons compared to Django.
Can anyone point out the pros and cons of TG2 over Django?
1,387,123
5
7
2,475
0
python,django,turbogears,turbogears2
Pros. SQLAlchemy > django ORM Multiple template languages out of the box (genshi,mako,jinja2) more WSGI friendly Object Dispatch > routes > regexp routing. You can get the first 2 with TG2 Almost all components are optional you can keep the core and use any ORM, template, auth library, etc. Sprox > django forms Cons. - Admin is more basic (no inline objects yet!) - less third party apps - "app" system still in the making. - given it's modularity you need to read documentation from different sources (SQLAlchemy, Genshi or Mako, repoze.who, Pylons, etc.)
0
0
0
0
2009-03-12T23:26:00.000
8
0.124353
false
640,877
0
0
1
4
Django is my favorite python web framework. I've tried out others like pylons, web2py, nevow and others. But I've never looked into TurboGears with much enthusiasm. Now with TG2 out of beta I may give it a try. I'd like to know what are some of the pros and cons compared to Django.
Can anyone point out the pros and cons of TG2 over Django?
642,874
0
7
2,475
0
python,django,turbogears,turbogears2
Last I checked, django has a very poor data implementation. And that's a huge weakness in my book. Django's orm doesn't allow me to use the power of the underlying database. For example I can't use compound primary keys, which are important to good db design. It also doesn't support more than a single database, which is not a big deal until you really need it and find that you can't do it without resorting to doing it manually. Lastly if you have to make changes to your database structure in a team-friendly way, you have to try to choose between a set of 3rd party migration tools. Turbogears seems to be more architecturally sound, doing its best to integrate individual tools that are awesome in their own right. And because TG is more of an integrator, you're able to switch out pieces to suit your preferences. Don't like SQL Alchemy? You can use SQLObject. Don't like Genshi templates? You can use Mako or even django's, although you're not exactly stuck with the default on django either. Time for tg2's cons: TG has a much smaller community, and community usually has its benefit. Django has a much better name. I really like that name ;-) Django seems simpler for the beginning web developer, with pretty cool admin tools. TG has decent documentation, but you also need to go to Genshi's site to learn Genshi, SQL Alchemy's site to learn that, etc. Django has great docs. My 2 cents.
0
0
0
0
2009-03-12T23:26:00.000
8
0
false
640,877
0
0
1
4
Django is my favorite python web framework. I've tried out others like pylons, web2py, nevow and others. But I've never looked into TurboGears with much enthusiasm. Now with TG2 out of beta I may give it a try. I'd like to know what are some of the pros and cons compared to Django.
Can anyone point out the pros and cons of TG2 over Django?
641,046
0
7
2,475
0
python,django,turbogears,turbogears2
Because Django uses its own ORM it limits you to learn that ORM for that specific web framework. I think using an web framework with a more popular ORM (like SqlAlchemy which TG uses) increases your employability chances. Just my 2 cents ..
0
0
0
0
2009-03-12T23:26:00.000
8
0
false
640,877
0
0
1
4
Django is my favorite python web framework. I've tried out others like pylons, web2py, nevow and others. But I've never looked into TurboGears with much enthusiasm. Now with TG2 out of beta I may give it a try. I'd like to know what are some of the pros and cons compared to Django.
Email integration
641,004
7
12
1,824
0
python,django,email
Generally: 1) Set up a dedicated email account for the purpose. 2) Have a programm monitor the mailbox (let's say fetchmail, since that's what I do). 3) When an email arrives at the account, fetchmail downloads the email, writes it to disk, and calls script or program you have written with the email file as an argument. 4) Your script or program parses the email and takes an appropriate action. The part that's usually mysterious to people is the fetchmail part (#2). Specifically on Mail Servers (iff you control the mailserver enough to redirect emails to scripts): 1-3) Configure an address to be piped to a script you have written. 4) Same as above.
0
0
0
0
2009-03-13T00:09:00.000
6
1
false
640,970
0
0
1
1
I was wondering if someone could help me out. In some web application, the app will send out emails, say when a new message has been posted. Then instead of signing into the application to post a reply you can just simply reply to the email and it will automatically update the web app with your response. My question is, how is this done and what is it called? Thanks
Anyone use Pyjamas (pyjs) python to javascript compiler (like GWT..)
3,030,515
1
18
5,067
0
javascript,python,gwt
yes it works fine on windows (it's a compiler: you just need python, to run the conversion to javascript). but if you're thinking of pyjamas-desktop, 0.6 added support for MSHTML as one of the engines, so that works too.
0
0
0
0
2009-03-13T16:33:00.000
4
0.049958
false
643,565
1
0
1
2
Has any one used this? I don't have a large background in Javascript and this lib looks like it may speed things along. www.pyjs.org
Anyone use Pyjamas (pyjs) python to javascript compiler (like GWT..)
730,960
10
18
5,067
0
javascript,python,gwt
yep. me. i'm the lead developer. drop by on groups.google.com "pyjamas-dev" and say hello.
0
0
0
0
2009-03-13T16:33:00.000
4
1
false
643,565
1
0
1
2
Has any one used this? I don't have a large background in Javascript and this lib looks like it may speed things along. www.pyjs.org
How do you make a case for Django [or Ruby on Rails] to non-technical clients
644,312
1
14
2,100
0
python,ruby-on-rails,ruby,django
The problem with a "brochure" approach is that it doesn't address the clients needs. Putting the language/platform of choice into a presentation that addresses the clients goals is much more likely to sell them - both on the tools you want to use, as well as you as a provider. As long as you can show that your approach will solve the problem (preferably with the least amount of expense), you'll have fewer objections and less of the "but I've heard that xxx is the best".
0
0
0
0
2009-03-13T19:25:00.000
7
0.028564
false
644,237
0
0
1
5
Businessmen typically want a web application developed. They are aware of .net or J2EE by names, without much knowledge about either. Altho' Rails and Django offer for a much better and faster development stack, it is a big task to convince businessmen to use these platforms. The task begins with introducing Django (or Rails), quoting some blog/research. Then making a case for the use of the framework for the specific project. Lot of the task is repetitive. What are the sources/blogs/whitepapers and other materials you use to make a case for django (or Rails) Don't you think there should be a common brochure developed that many development agencies could use to make the same case, over and again. Are there any such ones, now? There seems to be enough discussion on Django vs Rails. Whereas the need is (Django and Rails) vs (.net and J2EE), at least so, while making a business case. Both represent a faster pragmatic web development in a dynamic language.
How do you make a case for Django [or Ruby on Rails] to non-technical clients
644,291
2
14
2,100
0
python,ruby-on-rails,ruby,django
The first 2 arguments from the top of my mind: Easier and faster development = cheaper product, less time to market. SO optimization out of the box.
0
0
0
0
2009-03-13T19:25:00.000
7
0.057081
false
644,237
0
0
1
5
Businessmen typically want a web application developed. They are aware of .net or J2EE by names, without much knowledge about either. Altho' Rails and Django offer for a much better and faster development stack, it is a big task to convince businessmen to use these platforms. The task begins with introducing Django (or Rails), quoting some blog/research. Then making a case for the use of the framework for the specific project. Lot of the task is repetitive. What are the sources/blogs/whitepapers and other materials you use to make a case for django (or Rails) Don't you think there should be a common brochure developed that many development agencies could use to make the same case, over and again. Are there any such ones, now? There seems to be enough discussion on Django vs Rails. Whereas the need is (Django and Rails) vs (.net and J2EE), at least so, while making a business case. Both represent a faster pragmatic web development in a dynamic language.
How do you make a case for Django [or Ruby on Rails] to non-technical clients
644,279
1
14
2,100
0
python,ruby-on-rails,ruby,django
The best case to be made for either of these frameworks is their ability to automate repetitive and time-consuming tasks. This allows developers to be faster and more productive which in turn means projects are delivered faster.
0
0
0
0
2009-03-13T19:25:00.000
7
0.028564
false
644,237
0
0
1
5
Businessmen typically want a web application developed. They are aware of .net or J2EE by names, without much knowledge about either. Altho' Rails and Django offer for a much better and faster development stack, it is a big task to convince businessmen to use these platforms. The task begins with introducing Django (or Rails), quoting some blog/research. Then making a case for the use of the framework for the specific project. Lot of the task is repetitive. What are the sources/blogs/whitepapers and other materials you use to make a case for django (or Rails) Don't you think there should be a common brochure developed that many development agencies could use to make the same case, over and again. Are there any such ones, now? There seems to be enough discussion on Django vs Rails. Whereas the need is (Django and Rails) vs (.net and J2EE), at least so, while making a business case. Both represent a faster pragmatic web development in a dynamic language.
How do you make a case for Django [or Ruby on Rails] to non-technical clients
644,310
16
14
2,100
0
python,ruby-on-rails,ruby,django
You need to speak the language of business: money. "If we do it Rails, it will cost you 50% less than the same functionality in Java." Your percentage may vary, and you might need to also include hosting and upkeep costs, to show how it balances out. When you're convincing other programmers, sure, talk about development speed and automation of repetitive tasks. But talk bottom-line cost to a business person.
0
0
0
0
2009-03-13T19:25:00.000
7
1
false
644,237
0
0
1
5
Businessmen typically want a web application developed. They are aware of .net or J2EE by names, without much knowledge about either. Altho' Rails and Django offer for a much better and faster development stack, it is a big task to convince businessmen to use these platforms. The task begins with introducing Django (or Rails), quoting some blog/research. Then making a case for the use of the framework for the specific project. Lot of the task is repetitive. What are the sources/blogs/whitepapers and other materials you use to make a case for django (or Rails) Don't you think there should be a common brochure developed that many development agencies could use to make the same case, over and again. Are there any such ones, now? There seems to be enough discussion on Django vs Rails. Whereas the need is (Django and Rails) vs (.net and J2EE), at least so, while making a business case. Both represent a faster pragmatic web development in a dynamic language.