Closed turt2live closed 6 years ago
This seems quite useful, thanks! Can you have a look at the failing Windows build? Once I merge it please allow some time before a release, I want to add similar parse_url and parse_file methods which requires some refactoring.
It looks as though the test failed due to a problem in the coverage
package running on Python 3.2. I'm still fairly new to Python in general, but it looks like the version installed is not applicable to the Python version to be testing on.
Repository health decreased by 0.28% when pulling ef38ae2 on turt2live:long-document into fc2f7c8 on stchris:master.
Repository health decreased by 0.28% when pulling 57d56fc on turt2live:long-document into fc2f7c8 on stchris:master.
Repository health decreased by 0.28% when pulling 04911b2 on turt2live:long-document into fc2f7c8 on stchris:master.
@stchris I apologize for the spam of commits (testing locally proved difficult). The tests were failing because coveralls
recently updated to support coverage 4.x. On pypy coveralls does not list Python 3.2 as a supported version. Using a lesser version appears to resolve the issue.
Repository health decreased by 0.28% when pulling e1a1a3b on turt2live:long-document into fc2f7c8 on stchris:master.
Awesome, thanks for the fix @turt2live . I will merge this as soon as I find time to cut a release. I'd like to make the API more uniform, now that there's not just the parse method. I hope you can wait a bit longer. Sorry about that :|
No problem - having consistent and clean code is always a good thing :)
@stchris Have you had a chance to look at this? ;)
@stchris would be nice having this, or that the parse function is formatted that it sees longs strings as strings and not as filenames
I'm going to have to close this: It's been open for a pretty long time and the project I originally needed it for is no longer in development.
If someone else wants to take this on, by all means please do :)
In Windows environments the path length limitation causes a path too long exception to be raised from
parse()
. To combat this, I've written aparse_raw()
function that accepts an XML string and will not attempt to estimate what type of data it was given. This seemed like a better choice over adding a type parameter toparse()
because of the several options it could be given: filepath, url, xml string, stream, or some value to indicate that it needs to be figured out (likeNone
).This has been confirmed to work on Windows 7 with Python 3.4.3 using a document that exceeds 300+ characters.