Skip to content
This repository was archived by the owner on Jun 26, 2020. It is now read-only.

Cherry branch #25

Open
wants to merge 20 commits into
base: master
Choose a base branch
from
Open

Conversation

mbullmanFHCRC
Copy link

@mbullmanFHCRC mbullmanFHCRC commented Aug 9, 2019

All Submissions:

  • Have you followed the guidelines in our Contributing document?
  • [x ] Have you checked to ensure there aren't other open Pull Requests for the same update/change?

New Feature Submissions:

  1. Does your submission pass tests (if applicable)?
  2. [ x] Have you lint your code locally prior to submission (use flake8)?

Changes to Core Features:

  • Have you added an explanation of what your changes do and why you'd like us to include them?
  • Have you written new tests for your core changes, as applicable?
  • [x ] Have you successfully ran tests with your changes locally?

I only want to commit 27aeba4 / 989a237, I've tried cherry-picking the changes but can't seem to get it to work.

Basically, when you're using getContent / xml_element.findall(path), if you run into italics or bolds in the xml text you run into issues, since the xml parsers doesn't handle those edge cases correctly.

To fix this I'm removing , , , from the response string that _get returns before xml.fromstring(response) is called.

It seems to work on the quick test I did on my own system, I think there are other special characters which could be added to the regex if needed, but for now this works for my purposes. I saw issue #23 referenced incomplete abstract which was a symptom I saw on my end. The issue also arises in ArticleTitle if italics or bolds are used.

I didn't test this too extensively, hopefully it's not breaking anything else down the line.

Sorry for the extra commits! I'll try and figure out how to cherry-pick better in the future.

Michael Bullman and others added 20 commits July 24, 2019 13:54
…olves adding new _extract fucntions, __slots__ entries, and self.Field references for each added field
…n't working. I need to look up some XML stuff
…ORCID. Unfortunately, this meant removing the very clean list comprehesnion the original author was using.
…nown error where ORCIDs could end with an 'X' instead of a numerial. Should now be catching all ORCIDs properly... hopefully
…s rather than a single string of text values. This allows for more intuitive parsing of listed elements (IMO). I then used this new function in _extractArticleIDs to allow for easier extraction of articleIDs. And cleaner code I think. Overall, with this change. I think we're basically bringing in all the fields we may or may not need. So now we can start working on getting this formatted out and saved to disk somewhere
…MedType' method/field to both books and article. This is so we can filter out book types
…ut I think it is working such that it will always return something. Hopefully. Still needs to be validated against existing processes
@mbullmanFHCRC mbullmanFHCRC marked this pull request as ready for review August 9, 2019 23:44
@mbullmanFHCRC mbullmanFHCRC deleted the cherry-branch branch August 12, 2019 18:04
@mbullmanFHCRC mbullmanFHCRC restored the cherry-branch branch August 12, 2019 18:38
@mbullmanFHCRC mbullmanFHCRC reopened this Aug 12, 2019
@mbullmanFHCRC
Copy link
Author

accidently deleted branch / PR

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant