473,748 Members | 2,300 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

What YAML engine do you use?

Hello,

I know that there are different YAML engines for Python out there (Syck,
PyYaml, more?).

Which one do you use, and why?

For those of you who don't know what YAML is: visit http://yaml.org/!
You will be amazed, and never think of XML again. Well, almost.

Reinhold
Jul 18 '05 #1
30 3480
> I know that there are different YAML engines for Python out there (Syck,
PyYaml, more?).

Which one do you use, and why?
I first used yaml, tried to migrate to syck. What I like about syck is that
it is faster and doesn't try to create objects but only dicts - but it
crashed if the number of yaml objects grew larger. So I still use yaml.

For those of you who don't know what YAML is: visit http://yaml.org/!
You will be amazed, and never think of XML again. Well, almost.


It is certainly nice.

--
Regards,

Diez B. Roggisch
Jul 18 '05 #2
Diez B. Roggisch wrote:
I first used yaml, tried to migrate to syck. What I like about
syck is that it is faster and doesn't try to create objects but
only dicts - but it crashed if the number of yaml objects grew
larger. So I still use yaml.


Hmm.. I've never had any problems with syck. In fact, I'm using it in
a small project now where I store a helluva of data in yaml files...

Strange.
Jul 18 '05 #3
Reinhold Birkenfeld wrote:
You will be amazed, and never think of XML again.


XML with elementtree is what makes me never have think about XML again.

Istvan.
Jul 18 '05 #4
Istvan Albert wrote:
XML with elementtree is what makes me never have think about XML again.


+1 QOTW

-Irmen
Jul 18 '05 #5
Reinhold Birkenfeld <re************ ************@wo lke7.net> writes:
For those of you who don't know what YAML is: visit http://yaml.org/!
You will be amazed, and never think of XML again. Well, almost.


Oh please no, not another one of these. We really really don't need it.
Jul 18 '05 #6
rm
Paul Rubin wrote:
Reinhold Birkenfeld <re************ ************@wo lke7.net> writes:
For those of you who don't know what YAML is: visit http://yaml.org/!
You will be amazed, and never think of XML again. Well, almost.

Oh please no, not another one of these. We really really don't need it.


well, I did look at it, and as a text format is more readable than XML
is. Furthermore, XML's verbosity is incredible. This format is not.
People are abusing the genericity of XML to put everything into it.

Parsing and working with XML are highly optimized, so there's not really
a problem in that sector. But to transfer the same data in a YAML
format, rather than a XML format is much more economic. But networks are
getting faster, right?

Nowadays, people are trying to create binary XML, XML databases,
graphics in XML (btw, I'm quite impressed by SVG), you have XSLT, you
have XSL-FO, ... .

And I think, YAML is a nice initiative.

bye,
rm
Jul 18 '05 #7
"rm" wrote:
well, I did look at it, and as a text format is more readable than XML is.


judging from http://yaml.org/spec/current.html (750k), the YAML designers are
clearly insane. that's the most absurd software specification I've ever seen. they
need help, not users.

</F>

Jul 18 '05 #8
On Fri, 21 Jan 2005 18:30:47 +0100,
rm <rm@rm.net> wrote:
Nowadays, people are trying to create binary XML, XML databases,
graphics in XML (btw, I'm quite impressed by SVG), you have XSLT, you
have XSL-FO, ... .


Which is an argument in favor of XML -- it's where the activity is, so it's
quite likely you'll encounter the need to know XML. Few projects use YAML,
so the chance of having to know its syntactic details is small.

--amk
Jul 18 '05 #9
On Fri, 21 Jan 2005 18:54:50 +0100,
Fredrik Lundh <fr*****@python ware.com> wrote:
judging from http://yaml.org/spec/current.html (750k), the YAML designers are
clearly insane. that's the most absurd software specification I've ever seen. they
need help, not users.


IMHO that's a bit extreme. Specifications are written to be detailed, so
consequently they're torture to read. Seen the ReStructured Text spec
lately?

The basic idea -- a data dumping format that's human-readable -- isn't a bad
one. OTOH, I can't recall wanting such a thing -- when I want readable
output I'm happy using
unreadable pickle files, unpickling the object and calling a .dump() or
..as_text() method.)

But YAML seems to have started out with the goal of being human-writable,
something you would write in Emacs, and that seems to have gotten lost; the
format is now just as complicated as Restructured Text, but more cryptic
(the URI namespacing for tags, for example), not really simpler than
XML and in some ways weaker (e.g. only two encodings supported, more
complicated escaping rules).

For a pure Python application, I can't see a need for YAML; use
pickle/cPickle instead, because they're already there. Exchanging
serialized objects between Python/Perl/Ruby scripts might be a good use case
for YAML, but XML has wider software support and S-expressions are simpler,
so my inclination would be to use them instead of YAML.

--amk
Jul 18 '05 #10

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
3685
by: Peter Maas | last post by:
Hi, currently I'm trying to create a pgsql backend for the roundup issue tracker using the mysql backend as a template (is somebody aware of such a thing? I couldn't find one). The author has written a config.py as many authors do. From the programmer's perspective this is a satis- factory solution: he can use his favourite language and put complex structures into the configuration. From the sysadmin's perspective this is not so...
2
1790
by: Wilk | last post by:
Hi, It seems that the link for python-yaml on the http://yaml.org main page is loose (http://iron.cx/yaml) :-( Anybody knows what's append ? What do you use ? pure python-yaml or syck ? --
0
2889
by: Phlip | last post by:
YAML? YAML YAML? Yet Another Missing Library? Is there a YAML implementation for C++? Need I remind y'all how easily one can implement YAML using Brand X?
0
1176
by: Stephen Moore | last post by:
hello I have a situation where I have quite a large python object which I want to convert to yaml so I can then send it to a flex application using pyamf. I've managed to create a yaml document using the python object (http://flashbsm.googlecode.com/svn/testing/yamlTest/tester.yaml) (using pyyaml)
0
1192
by: Kirill Simonov | last post by:
Stephen Moore wrote: Try yaml.safe_dump(). !!python/tuple
0
1383
by: Kirill Simonov | last post by:
======================== Announcing PyYAML-3.06 ======================== A new bug fix release of PyYAML is now available: http://pyyaml.org/wiki/PyYAML Changes
0
1325
by: Matthew Wilson | last post by:
I suspect the solution to my problem is something really trivial. I wrote a module called pitz that contains a class Issue: u'ditz.rubyforge.org,2008-03-06/issue' Then I try to load a document with that same tag, but I get a ConstructorError: ConstructorError: could not determine a constructor for the tag
2
2976
by: sshub | last post by:
I am using YAML module(Config:YAML) for one of the perl script. When i run the script, i get an error saying like ' Can't locate YAML.pm in ..........'. The error is pointing to a line 7 of the YAML.pm module itself and that line is 'use YAML; '. How can a module use itself and expect to be in the path. Am new to perl, pls someone help on for this issue
2
2015
sagacious
by: sagacious | last post by:
Hello TO All.. It Been Just Some Years That I Have Worked With WML, Html, Php, Css, Ajax And My SQL.. Now New Entered in Perl, Python ; World... I Have 2 Search Engine Script Which Starts with index.yaml and another indexer.cgi and indexer.pl So I Have Egarly Want to Know That How Could I Will Work with THese.. I Mean How Could I Can Show this On My Server like index.php or index.htm Please Help
0
8831
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9552
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9376
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
9326
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9249
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
6796
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
4607
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4877
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
2787
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.