Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #88412

Re: New to Programming - XML Processing

Path csiph.com!usenet.pasdenom.info!gegeweb.org!usenet-fr.net!nerim.net!novso.com!newsfeed.xs4all.nl!newsfeed3.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail
Return-Path <python-python-list@m.gmane.org>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.020
X-Spam-Evidence '*H*': 0.96; '*S*': 0.00; 'tutorial': 0.03; 'schema': 0.05; 'xml,': 0.05; 'elements.': 0.07; 'hierarchical': 0.09; 'parsing': 0.09; 'received:80.91': 0.09; 'received:80.91.229': 0.09; 'received:gmane.org': 0.09; 'received:list': 0.09; 'python': 0.11; 'wrote': 0.14; 'exist;': 0.16; 'finney': 0.16; 'rarely': 0.16; 'received:80.91.229.3': 0.16; 'received:plane.gmane.org': 0.16; 'relevant.': 0.16; 'subject:Programming': 0.16; 'subject:XML': 0.16; 'url:guide': 0.16; 'url:standards': 0.16; 'language': 0.16; 'module': 0.19; 'first.': 0.19; 'comfortable': 0.22; 'header:User-Agent:1': 0.23; 'format,': 0.24; 'parse': 0.24; 'fine': 0.24; 'suggested': 0.26; 'tutorials': 0.26; 'header:X -Complaints-To:1': 0.27; 'point': 0.28; 'xml': 0.29; 'document.': 0.30; 'then.': 0.30; "i'm": 0.30; 'getting': 0.31; 'markup': 0.31; 'url:category': 0.31; 'writes:': 0.31; 'file': 0.32; 'worked': 0.33; 'used,': 0.33; 'sense': 0.34; 'problem': 0.35; 'basic': 0.35; 'created': 0.35; 'possible.': 0.35; 'beyond': 0.35; 'but': 0.35; 'there': 0.35; 'really': 0.36; 'choosing': 0.36; 'programming,': 0.36; 'url:org': 0.36; 'behind': 0.37; 'subject:New': 0.37; 'clear': 0.37; 'being': 0.38; 'ben': 0.38; 'whatever': 0.38; 'to:addr:python-list': 0.38; 'expect': 0.39; 'does': 0.39; 'though,': 0.39; 'to:addr:python.org': 0.39; 'enough': 0.39; 'received:org': 0.40; 'how': 0.40; 'skip:u 10': 0.60; 'read': 0.60; 'consists': 0.60; 'new': 0.61; "you'll": 0.62; 'myself': 0.63; 'more': 0.64; 'skip:\xe2 10': 0.65; 'teach': 0.65; 'here': 0.66; 'between': 0.67; 'sound': 0.68; 'hoping': 0.75; '\xe2\x80\x93': 0.77; '8bit%:46': 0.78; 'computers.': 0.84; 'experiment': 0.84; 'noise': 0.84; 'principles.': 0.84; 'received:125': 0.84; 'standards,': 0.84; 'tasked': 0.84; 'terrible': 0.84; 'simple!': 0.91; 'url:core': 0.91
X-Injected-Via-Gmane http://gmane.org/
To python-list@python.org
From Ben Finney <ben+python@benfinney.id.au>
Subject Re: New to Programming - XML Processing
Date Wed, 01 Apr 2015 15:08:37 +1100
References <upomhad4fj6sulnr5so8088fdqpo0nk6mu@4ax.com>
Mime-Version 1.0
Content-Type text/plain; charset=utf-8
Content-Transfer-Encoding 8bit
X-Gmane-NNTP-Posting-Host jigong.madmonks.org
X-Public-Key-ID 0xAC128405
X-Public-Key-Fingerprint 517C F14B B2F3 98B0 CB35 4855 B8B2 4C06 AC12 8405
X-Public-Key-URL http://www.benfinney.id.au/contact/bfinney-pubkey.asc
X-Post-From Ben Finney <bignose+hates-spam@benfinney.id.au>
User-Agent Gnus/5.13 (Gnus v5.13) Emacs/24.4 (gnu/linux)
Cancel-Lock sha1:PSXAOuDo31BGPFnekI5BU6nRiW8=
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.20
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <https://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list/>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <https://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Newsgroups comp.lang.python
Message-ID <mailman.4.1427861313.12925.python-list@python.org> (permalink)
Lines 53
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1427861313 news.xs4all.nl 2878 [2001:888:2000:d::a6]:47271
X-Complaints-To abuse@xs4all.nl
Xref csiph.com comp.lang.python:88412

Show key headers only | View raw


catperson <me@anonymous.invalid> writes:

> I am new to programming, though not new to computers. I'm looking to
> teach myself Python 3 and am working my way through a tutorial.

Congratulations! Python 3 is a fine language to be your first.

Which tutorial are you following? It may be relevant.

> At the point I'm at in the tutorial I am tasked with parsing out an
> XML file created with a Garmin Forerunner and am just having a
> terrible time getting my head around the concepts.

Have you worked with manipulating XML documents in the past?

If I describe XML as a machine-readable hierarchical data serialisation
format, does that sound like noise or are you comfortable that you
understand that description?

> What I'm looking for is some suggested reading that might give me some
> of the theory of operation behind ElementTree and then how to parse
> out specific elements.

You'll need to understand the principles behind XML, then. Warning: it
is not simple! XML is machine-readable, but rarely pleasant for *humans*
to read or understand.

> I'm hoping with enough reading I can experiment and work my way
> through the problem and end up with a hopefully clear understanding of
> the ElementTree module and Dictionairies.

XML is a standard – a large number of standards, really – from the W3
Consortium. They have a good overview of the “core” of XML
<URL:http://www.w3.org/standards/xml/core>.

There are countless XML formats though; XML is a markup language to use
as a basis for constructing data serialisation formats. You need to know
what the specific format (called a “schema”) is before you can expect to
make sense of it, and so in order to understand what's in the document
you need a description of the specific schema from whoever wrote the
document.

General XML tutorials do exist; here is one comprehensive one
<URL:http://www.xmlobjective.com/category/guide/>. You'll likely want to
learn more about the specifics of whatever XML format is being used,
though, before going much beyond the basic principles.

-- 
 \            “Politics is not the art of the possible. It consists in |
  `\       choosing between the disastrous and the unpalatable.” —John |
_o__)                                    Kenneth Galbraith, 1962-03-02 |
Ben Finney

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

New to Programming - XML Processing catperson <me@anonymous.invalid> - 2015-03-31 20:27 -0700
  Re: New to Programming - XML Processing Ben Finney <ben+python@benfinney.id.au> - 2015-04-01 15:08 +1100
  Re: New to Programming - XML Processing Rustom Mody <rustompmody@gmail.com> - 2015-03-31 21:17 -0700
    Re: New to Programming - XML Processing Andrew Farrell <amfarrell@mit.edu> - 2015-03-31 23:27 -0500
    Re: New to Programming - XML Processing Mark Lawrence <breamoreboy@yahoo.co.uk> - 2015-04-01 09:00 +0100
    Re: New to Programming - XML Processing catperson <me@anonymous.invalid> - 2015-04-01 15:33 -0700
      Re: New to Programming - XML Processing sohcahtoa82@gmail.com - 2015-04-01 17:46 -0700
  Re: New to Programming - XML Processing Rustom Mody <rustompmody@gmail.com> - 2015-03-31 21:49 -0700
  Re: New to Programming - XML Processing Andrew Farrell <amfarrell@mit.edu> - 2015-03-31 23:26 -0500
  Re: New to Programming - XML Processing Burak Arslan <burak.arslan@arskom.com.tr> - 2015-04-01 16:44 +0300

csiph-web