Re: Problem installing Python 2.5
Dnia Tue, 3 Apr 2007 11:52:55 -0300, Sebastian Bassi napisał(a): > I was trying to install Python 2.5 compiling from sources. I used: > ./compile > It run OK. > Then: > make altintall > After a lot of output, got this: > Listing /usr/local/lib/python2.5/xml/sax ... > Compiling /usr/local/lib/python2.5/xml/sax/__init__.py ... > Compiling /usr/local/lib/python2.5/xml/sax/_exceptions.py ... > Compiling /usr/local/lib/python2.5/xml/sax/expatreader.py ... > Compiling /usr/local/lib/python2.5/xml/sax/handler.py ... > Compiling /usr/local/lib/python2.5/xml/sax/saxutils.py ... > Compiling /usr/local/lib/python2.5/xml/sax/xmlreader.py ... > Compiling /usr/local/lib/python2.5/xmllib.py ... > Compiling /usr/local/lib/python2.5/xmlrpclib.py ... > Compiling /usr/local/lib/python2.5/zipfile.py ... > make: *** [libinstall] Error 1 > > It seems I am not the only one with this error: > http://www.thescripts.com/forum/thread613458.html > http://www.megasolutions.net/python/Python-installation-problem-(sorry-if-this-is-a-dup)-22624.aspx > http://ubuntuforums.org/showthread.php?p=1912370 > > System: Freespire 1.0.13 (based on Debian). After executing ./configure you have to edito Modules/Setup file and uncomment the following line: #zlib zlibmodule.c -I$(prefix)/include -L$(exec_prefix)/lib -lz Then continue with normal make; make install. -- Jaroslaw Zabiello http://blog.zabiello.com -- http://mail.python.org/mailman/listinfo/python-list
Re: ZSI, SOAP and .NET web services - problem
Dnia Mon, 26 Mar 2007 20:06:28 + (UTC), David E. Konerding DSD staff napisał(a): > Try fixing your WSDL, then try again. The problem is I see no errors in my WSDL. Pythonic implementation of SOAP is just crapy. -- Jaroslaw Zabiello http://blog.zabiello.com -- http://mail.python.org/mailman/listinfo/python-list
Re: ZSI, SOAP and .NET web services - problem
Dnia Thu, 22 Mar 2007 22:48:26 +0100, Jarek Zgoda napisał(a): > If you really must write client for this service, go and do it in Ruby, > if it works. I cannot. I am using Pylons framework so I have to use Python. Ruby solves this problem but not others, like its low speed. -- Jaroslaw Zabiello http://blog.zabiello.com -- http://mail.python.org/mailman/listinfo/python-list
Re: ZSI, SOAP and .NET web services - problem
Dnia Thu, 22 Mar 2007 18:44:31 +0100, Laszlo Nagy napisał(a): > However, it is an interesting question. Ruby has smaller community, > how could they implement a standard SOAP lib? Yes. It is interesting why it is so difficult to make it working for Python. > My personal opinion is that SOAP is a piece of shit itself. It is > hampered from the beginning. If you are interested why, read this: > > http://wanderingbarque.com/nonintersecting/2006/11/15/the-s-stands-for-simple/ > Hehe, it was good. :) > XML-RPC is a fantastic, often undervalued protocol. You can create a > new, secure XML-RPC server in Python within 5 minutes. You can write a > client for it within one minue. It is REALLY simple. I'm using it > continuously. > > In contrast, SOAP is overcomplicated and anything but simple. No one > should create new web services using SOAP. We have enough problems with > the existing ones. :-( I agree. The problem is, I have to live with this stupid, poor implemented M$ technology. Ruby and with its standard SOAP library is able to live. Why Python cannnot? -- Jaroslaw Zabiello http://blog.zabiello.com -- http://mail.python.org/mailman/listinfo/python-list
ZSI, SOAP and .NET web services - problem
I try to connect to web services (written in C#/.NET) with latest ZSI 2.0rc3 library. It just does not work. from ZSI.ServiceProxy import ServiceProxy wsdl = 'http://192.168.0.103/NewWebServices/TemplateInsert.asmx?wsdl' print ServiceProxy(wsdl, tracefile=sys.stdout) "C:\opt\Python25\lib\site-packages\zsi-2.0_rc3-py2.5.egg\ZSI\wstools\WSDLTools.py", line 1116, in getAddressBinding WSDLError: No address binding found in port. This pythonic library must be stupid, because I have no problem to connect with... Ruby: require 'soap/wsdlDriver' require 'rexml/document' wsdl = 'http://192.168.0.103/NewWebServices/TemplateInsert.asmx?wsdl' soap = SOAP::WSDLDriverFactory.new(wsdl).create_rpc_driver #soap.wiredump_file_base = 'soapresult' p soap.templateInsert('') It is a shame why Python still has so poor SOAP implementation. Ruby has SOAP in *standard library*, Python - not. Even PHP5 has very good SOAP library built in. I tried to use different library - SOAPpy, but I couldn't. It requires fpconst library which cannot be installed because its server does not respond at all. What a shit... Why nobody wants to add SOAP to standard Python library? XML-RPC was added and it works without any problems. -- Jarosław Zabiełło http://blog.zabiello.com -- http://mail.python.org/mailman/listinfo/python-list
Re: What happened to SPE?
Dnia 11 Jan 2007 17:02:49 +0100, Neil Cerutti napisał(a): > SPE lost its web host, and last I heard is looking for a new > home. For now you can get it here: > > http://sourceforge.net/projects/spe/ That is old addres. Never is http://developer.berlios.de/projects/python/ -- Jaroslaw Zabiello http://blog.zabiello.com -- http://mail.python.org/mailman/listinfo/python-list
Re: Pros/Cons of Turbogears/Rails?
On 31 Aug 2006 08:24:29 -0700, Adam Jones wrote: > In moving to SQLAlchemy it would pick up not only a migration system but > also a much more flexible abstraction system due to the use of a Data > Mapper pattern instead of the Active Record pattern. What is the advantage of Data Mapper? I cannot find.. >> And last but not least, TG is based on poor, unstable and buggy >> CherryPy server. We had huge problems with CherryPy. I think that >> Django or Pylons are much better frameworks. IMO TG is no competition >> for Rails at all. The only real competition is Django or Pylons. > > I have never had much in the way of problems with CherryPy. From what I > have heard the project has made a lot of improvements recently, so it > may have changed since you last took a look at it. We have created two quite big sites in CheerryPy in past and we have many issues with its bad implementation. Sessions were useless, forks were removed from early code without any warning. Maybe now it is better, but I have lost any confidence in CherryPy quality. -- Jarosław Zabiełło http://blog.zabiello.com -- http://mail.python.org/mailman/listinfo/python-list
Re: Pros/Cons of Turbogears/Rails?
On Thu, 31 Aug 2006 11:42:47 -0300, Jorge Godoy wrote: > TG supports SQL Alchemy as well. With SQL Alchemy I believe you'll have a > better experience than with Rails' ORM. I would not be so sure. I have tried to work with SQL Alchemy (using Pylons) and I have been disappointed. :( It's syntax for selects is ugly and not intuitive. Django ORM looks much better. SQLAlchemy has to be added to Django as alternative ORM but *without breaking* current, clean API: http://groups.google.com/group/django-developers/browse_thread/thread/5149e1c60dc65bff/a177bb34cfde1ec7 >> But rhtml is much more flexible because it can generate *any content*, >> not only xml. But Rails has THREE template systems: rhtml (main), rxml >> (for rss and xml generation) and rjs (for javascript and AJAX). > > Well, TG has a few templating systems... MarkUp, Kid, Cheetah, ZPT, and > others. You can choose the one that best fits your needs / brain. This is another topic. Rails can also use another third-party template system (like Liquid which was inspired by Django). For me using many, different template systems *for the same task* make no sense. Rails uses three templates, but for *different tasks*. Its RJS is perfect for AJAX. Really cool, simple, and almost no javascript is required. Just clean Ruby for everything. -- Jarosław Zabiełło http://blog.zabiello.com -- http://mail.python.org/mailman/listinfo/python-list
Re: Pros/Cons of Turbogears/Rails?
[EMAIL PROTECTED] wrote: > + SqlObject allows working with the DB tables without > using SQL itself. Rails has ActiveRecord ORM, which IMO has nicer and simpler syntax than SQLObject. Rails has migrations, TB - not (Migrations is versioning system for evolving database schema) > + Likely to be faster because as far as I'm aware, Python > is significantly faster. Python is maybe faster, but with YARM (which is not stable yet) Ruby will be about 10x faster. YARM is full virtual machine like Java. > + Easy access to other libraries (such as the Python > Imaging Library) that Ruby, being a relatively newer > language, doesn't have equivalents to. Ruby is not so young you think. It became more popular when Rails has appeared. > + Built-in default SQLite makes it easier to set up? What? :) YAML is much easier. > (as far as I can tell, Ruby requires MySql by default--don't > know how easy this is to change.) Change in config/database.yml driver: mysql to any you want, like db2, postgres, sqlserver, sqlite, firebird, oracle etc. You can change default settings as well. See: rails --help > + I find the templating system somewhat cleaner; code in > py: xml namespace allows pure .html templates, instead > of equivalent of .rhtml files. But rhtml is much more flexible because it can generate *any content*, not only xml. But Rails has THREE template systems: rhtml (main), rxml (for rss and xml generation) and rjs (for javascript and AJAX). And last but not least, TG is based on poor, unstable and buggy CherryPy server. We had huge problems with CherryPy. I think that Django or Pylons are much better frameworks. IMO TG is no competition for Rails at all. The only real competition is Django or Pylons. -- Jaroslaw Zabiello http://blog.zabiello.com -- http://mail.python.org/mailman/listinfo/python-list
Re: Need a compelling argument to use Django instead of Rails
On Wed, 26 Jul 2006 18:23:22 +0200, Bruno Desthuilliers wrote: >>>Care to write an external DSL in Ruby ? >> ? > > I mean : write a parser and interpreter for a DSL. In Ruby. I see. Nope. I do not like code generators. In this sense every template system is DSL. E.g. Smarty Templates for PHP. You can create "external DSL" even in C or assembler. This is not the point. The point is Ruby is much better suited to create internal DSL than Python or PHP. -- Jarosław Zabiełło http://blog.zabiello.com -- http://mail.python.org/mailman/listinfo/python-list
Re: Need a compelling argument to use Django instead of Rails
On Wed, 26 Jul 2006 18:20:44 +0200, Bruno Desthuilliers wrote: > May I suggest that you learn some Lisp dialect ? Nope. I hate Lisp syntax. >> Of course, I you like, you can freeze every object you want and nobody can >> be able to open and change it. You can also trace all activity for changing >> something to objects because Ruby has nice system hooks implemented. > > __getattribute__ / __setattr__ / __delattr__ This is not the same. Ruby can also lock access to attributes. Freezing is different. It can freeze any object so you will not be able to add or delete any method. Once freezed object cannot be unfrozen. So you can be sure that nobody will change you classes if you do not like. > And of course import hooks. Python?? Where? >> Ruby >> has nice security system (private, protected, public scopes for methods and >> attributes, > > This is not "security", this is data-hiding. No. Data hiding are in Python. Ruby uses security similiar to Java. If the class has method marked as private it cannot be used in children classes. > And IIRC, Ruby's attributes are always private Yes and no. Yes, because you cannot read them directly without accessors. And no, because you can read them if you set proper accessor. >> In past Python had Bastion module >> (http://www.python.org/doc/lib/module-Bastion.html) >> but it was rejected and now Python has nothing. > > Seems like Zope is not doing so bad... Zope is only a great application. Invision Power Board or ezPublish are also great application, but it does not mean that PHP is great language. :) Python has no security at all. I has only convention and mangling. Of course somebode can say, it is enough, and maybe it is. But I think, that this might be another reason why Java guys prefer Ruby to Python. -- Jaroslaw Zabiello http://blog.zabiello.com -- http://mail.python.org/mailman/listinfo/python-list
Re: Need a compelling argument to use Django instead of Rails
On Wed, 26 Jul 2006 18:01:50 +0200, Bruno Desthuilliers wrote: >>>I have difficulty imagining how a language could be more dynamic than >>>Python... >> >> E.g. try to extends or redefine builtin Python classes on fly. > > Ok, this is one of the few restrictions - builtin types. Yeah. Have > something more convincing ? Nope. Python has similiar dynamic. Or.. maybe real closures. > Care to write an external DSL in Ruby ? ? -- Jarosław Zabiełło http://blog.zabiello.com -- http://mail.python.org/mailman/listinfo/python-list
Re: Need a compelling argument to use Django instead of Rails
On 26 Jul 2006 08:16:21 -0700, [EMAIL PROTECTED] wrote: >> E.g. try to extends or redefine builtin Python classes on fly. Ruby is so >> flexible that it can be used to create Domain-specific Programming >> Languages. > > This, of course, is really cool if you are working > all by yourself on a dissertation or something, > but can be completely disasterous if you are > actually working with other people who need to > know what the expressions of the programming > language mean and do. This should not be problem in real life. Look at Ruby on Rails. This is excellent example of DSL in action. Rails uses customized Ruby to create very friendly web framework. So there is no possible to create such simple and friendly framework in other language than Ruby (and Smalltalk which has the same feature) Of course, I you like, you can freeze every object you want and nobody can be able to open and change it. You can also trace all activity for changing something to objects because Ruby has nice system hooks implemented. Ruby has nice security system (private, protected, public scopes for methods and attributes, objects freezing, system hooks). In past Python had Bastion module (http://www.python.org/doc/lib/module-Bastion.html) but it was rejected and now Python has nothing. Java guys can favor Ruby also because of its security. -- Jarosław Zabiełło http://blog.zabiello.com -- http://mail.python.org/mailman/listinfo/python-list
Re: Need a compelling argument to use Django instead of Rails
On Wed, 26 Jul 2006 16:25:48 +0200, Bruno Desthuilliers wrote: > I have difficulty imagining how a language could be more dynamic than > Python... E.g. try to extends or redefine builtin Python classes on fly. Ruby is so flexible that it can be used to create Domain-specific Programming Languages. -- Jarosław Zabiełło http://blog.zabiello.com -- http://mail.python.org/mailman/listinfo/python-list
Re: Need a compelling argument to use Django instead of Rails
On Mon, 24 Jul 2006 14:23:21 +0200, Sybren Stuvel wrote: > Another reason for me not to use Ruby, is that there is no distinction > between those two lines of code: > > x = somefunc > x = somefunc() It has no meaning. Just use always () if you like. But sometimes it is better to avoid them to have more beautifull code. E.g. class Article < Activerecord::Base belongs_to: author has_many: comments end -- Jarosław Zabiełło http://blog.zabiello.com -- http://mail.python.org/mailman/listinfo/python-list
Re: Need a compelling argument to use Django instead of Rails
On Mon, 24 Jul 2006 13:22:33 +0200, Sybren Stuvel wrote: >> "Nah, we're not interested in Python." > > Ask them why. I know why. In general Java guys can recognize Ruby as more friendly language than Python, more secured (there is almost no security in Python). There is also much more hype about Ruby on java blogs. > The behaviour of Ruby hasn't even properly been defined. No. Ruby uses different paradigm. The language can be extended with its open classes. There is many similarity between Ruby and Smalltak. No Perl or Java, but Smalltalk. Philosophy and object model is very similiar. Ruby is more dynamic than Python exactly like Smalltak is. The main reason for using Rails is: Rails is complete framework, much easier to learn and use than Django. The main reason for using Python: Python is more productive. It is easier to learn Python than Ruby. Python uses minimalistic approach. It contains less methods, structures than Ruby. It is easier to memorize. Ruby has messed namespace with many aliases to methods. And it has much more methods to every object. It is difficult to remember them. There is no Ruby docstrings as well. You have to read manual, book much more than in Python. Also modules are easier to use in Python. When I am doing import blah i know what was downloaded and I can see it by simply typing dir(blah). But when you do "require blah" in Ruby you know *nothing*. You have to look inside blah.rb file to see what was happened. "require" command can execute code, add many namespaces etc. etc. -- Jarosław Zabiełło http://blog.zabiello.com -- http://mail.python.org/mailman/listinfo/python-list
Re: Need a compelling argument to use Django instead of Rails
On Mon, 24 Jul 2006 12:23:12 +0100, Steve Holden wrote: > The impression I get is that Rails is relatively inflexible > on database schemas, Django has the same problem. E.g. both Django ORM and ActiveRecord cannot work with complex primary keys. But for Rails there is a solution for even very strange created databases: rBatis (http://jutopia.tirsen.com/articles/tag/rbatis) it is Ruby port of java Ibatis (http://ibatis.apache.org/) -- Jarosław Zabiełło http://blog.zabiello.com -- http://mail.python.org/mailman/listinfo/python-list
Re: What editor shall I use?
On 8 Feb 2006 06:48:30 -0800, Lad wrote: > What editor shall I use if my Python script must contain utf-8 > characters? > I use XP The best (and free) are: Eclipse http://www.eclipse.org/ with pydev http://pydev.sourceforge.net/ SPE http://pythonide.stani.be/ Eric3 http://www.die-offenbachs.de/detlev/eric3.html win32 binary: http://www.quadgames.com/download/pythonqt/ All of them contain cool debugger and a lot of usefull options. If you want only plain text editor, you can use SciTe, vim, Notepad++ or whatever. -- Jarosław Zabiełło http://blog.zabiello.com -- http://mail.python.org/mailman/listinfo/python-list
Re: IDE recommendation please
Dnia Sun, 23 Oct 2005 14:54:38 +1000, microsnot napisał(a): > Eclipse don't seem to support Python out of the box. It is very easy to add excelent python plugin http://pydev.sourceforge.net/ Fast install: just go to the update manager (inside the help menu) and add update site: http://pydev.sf.net/updates/ (eclipse should do the rest) An alternative is just getting the zip file and extracting it yourself in eclipse. If you choose to do it, just make sure the plugins folder is extracted on top of the eclipse plugins folder. -- JZ -- http://mail.python.org/mailman/listinfo/python-list
Re: IDE recommendation please
Dnia 23 Oct 2005 00:33:41 -0700, kery napisał(a): > Any suggestions for Linux, specifically SuSE or perhaps Red Hat? Eric3 http://www.die-offenbachs.de/detlev/eric3.html Eclipse http://www.eclipse.org/ + pydev plugin http://pydev.sourceforge.net/ SPE http://pythonide.stani.be/ -- JZ -- http://mail.python.org/mailman/listinfo/python-list
Re: Django Vs Rails
Dnia 24 Sep 2005 22:48:40 -0700, [EMAIL PROTECTED] napisał(a): > You should give TurboGears a try. http://www.turbogears.org/about/status.html "TurboGears should be considered *alpha* software. This means that there can be *breaking API* changes between now and 1.0." It uses CherryPy (beta!), SQLObject (beta) and Kid (which has a couple of bugs that need fixing) This project is good only for fun and playing not for enterprise. -- JZ -- http://mail.python.org/mailman/listinfo/python-list
Zope, ZPT and slots
I would like to lauch macro from another zpt file. It is easy, of course, but the problem is I would like the macro could has access to title_or_id attribute of its caller. I read API, tried template/id, context/id and container/id but without results. displays only own id, not its caller :( displays only id of the folder where this zpt file and its macro is located. The same is for tal:content="container/id"/> ;( -- JZ -- http://mail.python.org/mailman/listinfo/python-list
Re: ZPT and "incompatible version None" error :(
Dnia Mon, 12 Sep 2005 16:51:48 +0200, Jaroslaw Zabiello napisał(a): > Another ZPT file try to fill one slot: > > > Search|Read|Compare|History > > > When I try to open it, I get the error mentioned above. Any idea? Solution was trivial Search|Read|Compare|History -- JZ -- http://mail.python.org/mailman/listinfo/python-list
ZPT and "incompatible version None" error :(
I got strange errors in Zope 2.7. METALError macro 'context/base' has incompatible version None, at line 1, column 1 One ZPT file (named 'base') defines some simply slots: http://www.w3.org/1999/xhtml"; xml:lang="en-US" lang="en-US" i18n:domain="plone" metal:use-macro="here/main_template/macros/master"> [up] [middle] [bottom] Another ZPT file try to fill one slot: Search|Read|Compare|History When I try to open it, I get the error mentioned above. Any idea? -- JZ -- http://mail.python.org/mailman/listinfo/python-list
Re: Django Vs Rails
Dnia 5 Sep 2005 19:06:51 -0700, flamesrock napisał(a): > Firstly, this topic is NOT intended for trolling or starting any flame > wars. > > I want to know if anyone has experience with these frameworks, and if > so, how do they compare? Which one do you prefer? Django's ORM does not work with SQL Server (only Postgresql, MySQL and SQlite). it would be problem to use Django for m$ based intranets. Rails has more features, better docs and seems to be more mature than Django. And last but not least, Django has no official release up today. -- JZ -- http://mail.python.org/mailman/listinfo/python-list