pacemaker2828 / pykml

Automatically exported from code.google.com/p/pykml
BSD 3-Clause "New" or "Revised" License
0 stars 0 forks source link

No module named kml_gx #3

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Checkout source via hg
2. Setup virtual environment per 
http://schwehr.org/blog/archives/2011-07.html#e2011-07-15T17_39_10.txt
3. easy_install pykml
4. cd pykml/src/examples/misc
5.  python virtual_base_jump.py 

What is the expected output? What do you see instead?

I can't figure out where kml_gx is.

$ python virtual_base_jump.py 
Traceback (most recent call last):
  File "virtual_base_jump.py", line 6, in <module>
    from pykml.kml_gx import schema
ImportError: No module named kml_gx
(virt1)

What version of the product are you using? On what operating system?

I'm using hg clone and easy_install on July 15.

Please provide any additional information below.

If I am in the top level directory, I'm not finding any files except in the hg 
store for gx...

find . | grep -i gx
./.hg/store/data/pykml/kml__gx
./.hg/store/data/pykml/kml__gx/____init____.py.i
./.hg/store/data/pykml/kml__gx/factory.py.i
./.hg/store/data/pykml/kml__gx/helpers.py.i
./.hg/store/data/pykml/kml__gx/parser.py.i
./.hg/store/data/pykml/kml__gx/schemas
./.hg/store/data/pykml/kml__gx/schemas/kml22gx.xsd.i
./.hg/store/data/pykml/kml__gx/test
./.hg/store/data/pykml/kml__gx/test/____init____.py.i
./.hg/store/data/pykml/kml__gx/test/test__factory.py.i
./.hg/store/data/pykml/kml__gx/test/test__parse.py.i
./.hg/store/data/pykml/kml__gx/test/testfiles
./.hg/store/data/pykml/kml__gx/test/testfiles/google__kml__developers__guide
./.hg/store/data/pykml/kml__gx/test/testfiles/google__kml__developers__guide/com
plete__tour__example.kml.i
./.hg/store/data/pykml/schemas/kml22gx.xsd.i
./.hg/store/data/src/pykml/schemas/kml22gx.xsd.i
./build/lib/pykml/schemas/kml22gx.xsd
./src/pykml/schemas/kml22gx.xsd

Original issue reported on code.google.com by schw...@gmail.com on 16 Jul 2011 at 1:57

GoogleCodeExporter commented 8 years ago
Acknowledged.  The virtual_base_jump example does not work with the current 
version of pykml, in which the objects representing the different popular 
versions of KML (KML OGC 2.2 and the Google Extensions) have been replaced by a 
generic KML authoring object. 

Original comment by tylerick...@gmail.com on 18 Jul 2011 at 12:56

GoogleCodeExporter commented 8 years ago
This is the first time that I've created a mercurial patch, so pardon if I got 
it wrong.  This should fix the issues that I reported.  My change log entry:

Cleanup of example code.
  - Emit a KML file with the same name as the python script
  - Handle the refactor of schema, have the right schema for gx
  - Remove the kml_gx from imports
  - Add "#!/usr/bin/env python" to all scripts

All the items are pretty minor.

Original comment by schw...@gmail.com on 20 Jul 2011 at 1:45

Attachments:

GoogleCodeExporter commented 8 years ago
Fixed in changeset 45:9c5793e79047

Original comment by tylerick...@gmail.com on 21 Jul 2011 at 9:24