Skip to content

CLN/DOC: Adjust xpath validation and error messaging in read_xml with IO tools doc note and example #48386

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

Merged
merged 4 commits into from
Sep 6, 2022

Conversation

ParfaitG
Copy link
Contributor

@ParfaitG ParfaitG commented Sep 4, 2022


shows the attribute sides on shape element was not parsed as expected
since this attribute resides on the child of row element and not row
element itself. In other words, sides attribute is a grandchild level
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
element itself. In other words, sides attribute is a grandchild level
element itself. In other words, the ``sides`` attribute is a grandchild level

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good to me. Will adjust.

df

shows the attribute sides on shape element was not parsed as expected
since this attribute resides on the child of row element and not row
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
since this attribute resides on the child of row element and not row
since this attribute resides on the child of a row element and not the row

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Articles are not needed here since note is specifically referring to element in XML which is literally named <row>.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see. Then put double backticks instead.

Copy link
Member

@gfyoung gfyoung left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pending CI, LGTM here. If another maintainer wants to have a look.

@ParfaitG ParfaitG added the IO XML read_xml, to_xml label Sep 5, 2022
@mroeschke mroeschke added this to the 1.6 milestone Sep 6, 2022
@mroeschke mroeschke merged commit d1d9b7f into pandas-dev:main Sep 6, 2022
@mroeschke
Copy link
Member

Thanks @ParfaitG

@mroeschke mroeschke modified the milestones: 1.6, 2.0 Oct 13, 2022
@ParfaitG ParfaitG deleted the xml_attrs branch October 29, 2022 17:39
noatamir pushed a commit to noatamir/pandas that referenced this pull request Nov 9, 2022
… IO tools doc note and example (pandas-dev#48386)

* CLN/DOC: Adjust xpath validation and error messaging in read_xml with IO tools doc note and example

* Fix xpath validation for child elements with added test

* Adjust IO tools docs for backticks on XML names
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Clean Docs IO XML read_xml, to_xml
Projects
None yet
3 participants