>From: Dattatreya Mellacheruvu
>Sent: Sat, January 2, 2010 5:19:06 PM
>

> Hi Dave,
> 
> I am using your program(generateDS.py) to generate a python class
> file and import XML files into sqlite.
> 
> Here is the schema file. mzXML schema - SourceForge.net: Find and
> Develop Open Source Software
> 
> I ran the following command and got the following error.
> 
> $python generateDS.py -o mzXML.py -s mzXMLSubs.py 
> ../../Desktop/mzXML_idx_2.1.xsd 
> Traceback (most recent call last):
>   File "generateDS.py", line 4527, in <module>
>     main()
>   File "generateDS.py", line 4521, in main
>     processIncludes, superModule=superModule)
>   File "generateDS.py", line 4262, in parseAndGenerate
>     process_includes.process_include_files(infile, outfile)
>   File 
> "/Users/dattatreyamellacheruvu/Downloads/generateDS-1.20c/process_includes.py",
>  line 91, in process_include_files
>     process_include_statements(root)
>   File 
> "/Users/dattatreyamellacheruvu/Downloads/generateDS-1.20c/process_includes.py",
>  line 141, in process_include_statements
>     raise IOError(msg)
> IOError: Can't find include file 
> http://sashimi.sourceforge.net/schema_revision/mzXML_2.1/mzXML_2.1.xsd.  
> Aborting.
> 
> I can't quite figure out what's wrong with my schema. 
> I can access 
> "http://sashimi.sourceforge.net/schema_revision/mzXML_2.1/mzXML_2.1.xsd"; .

> The documentation says "The include file processing is capable of
> retrieve included files via FTP and HTTP internet protocols as
> well as from the local file system."

Datta -

I suspect (but am not sure) that the error is caused by my
confusion about the difference between XML Schema "include" and
"import" elements.  At one time I believed that the difference was
that "include" is used to access schemas on your local disk and
"import" is used to access schemas across the net with ftp or http. 
I suspect that I'm wrong about that.  Your schema suggests that the
"include" element can also be used for remote files.

So, until I've had time to study it a bit more, I've attached a
version of process_includes.py that supports the use of "include" to
access remote files.  It generates bindings successfully.  Replace
process_includes.py in the same directory where generateDS.py
is installed.

Please let me know how this works for you.  If it goes well, and if
I can't find any reason for my previous belief, and when I've done a
bit more testing and clean up, I'll include this change in the next
release.

Thanks for letting me know about this.  I appreciate the help.

I'll answer the questions in your other email tomorrow when I have
more time.

- Dave


-- 


Dave Kuhlman
http://www.rexx.com/~dkuhlman

Attachment: process_includes.py
Description: Binary data

------------------------------------------------------------------------------
This SF.Net email is sponsored by the Verizon Developer Community
Take advantage of Verizon's best-in-class app development support
A streamlined, 14 day to market process makes app distribution fast and easy
Join now and get one step closer to millions of Verizon customers
http://p.sf.net/sfu/verizon-dev2dev 
_______________________________________________
generateds-users mailing list
generateds-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/generateds-users

Reply via email to