New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bug or intended? #7
Comments
Hi KleinerNull, I tried recreating this myself but your code seemed to work as expected, could you let me know more about your notebook setup so I can investigate further please. Here's my output from a non repl environment: from xmldataset import parse_using_profile
from sys import version
print(version)
xml2 = """<?xml version="1.0"?>
<data>
<colleagues>
<summary>
<min_colleagues>2</min_colleagues>
<current_colleagues>3</current_colleagues>
<max_colleagues>6</max_colleagues>
</summary>
<colleague>
<title>The Boss</title>
<phone>+1 202-663-9108</phone>
<email>boss@the_company.com</email>
</colleague>
<colleague>
<title>Admin Assistant</title>
<phone>+1 347-999-5454</phone>
<email>admin@the_company.com</email>
</colleague>
<colleague>
<title>Minion</title>
<phone>+1 792-123-4109</phone>
<email>minion@the_company.com</email>
</colleague>
</colleagues>
</data>"""
profile2 = """
data
colleagues
summary
min_colleagues = dataset:summary
current_colleagues = dataset:summary
max_colleagues = dataset:summary
colleague
title = dataset:colleagues
phone = dataset:colleagues
email = dataset:colleagues"""
print(parse_using_profile(xml2, profile2)) And output as follows
|
Very strange, it worked for me in python3, python2 and ipython. Just the jupyter notebook version 4.1.0 doesn't delivered any results. After upgrading it to 4.2.3 it worked as intended. Sry for not testing it on non notebooks, it is just my regular tinkering before production place ;) |
No problems, glad this is resolved :-) closing issue |
I've tested different structured xml tree and I found something unexpected. The code is in this notebook.
My problem is in cell 5.
Has that something to do with XML itselfs and the underlying elementtree implementation? So, bug or intended?
The text was updated successfully, but these errors were encountered: