Skip to content
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

DM-41312: Fix blockInfo parsing for minimal data #65

Merged
merged 4 commits into from
Oct 26, 2023

Conversation

mfisherlevine
Copy link
Contributor

No description provided.

Copy link
Contributor

@isullivan isullivan left a comment

Choose a reason for hiding this comment

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

Thanks for adding a comment explaining your use of log.exception.

@@ -236,6 +236,15 @@ def augmentData(self):
but is also much harder to maintain/debug, as the vectorized regexes
are hard to work with, and to know which row is causing problems.
"""
if 'lastCheckpoint' not in self.data.columns:
self.log.warning("No lastCheckpoint column in data, can't parse block data")
Copy link
Contributor

Choose a reason for hiding this comment

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

I would suggest 'lastCheckpoint' to make it explicit that that is the name of the column and not a description, and state that empty columns are being added. Also, is it possible to print any sort of informational message about the data that was being attempted, such as an identifier or just the number of rows?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done. (When this happens there are almost always warnings about how little data is being found for the TMA as well btw)

@@ -236,6 +236,15 @@ def augmentData(self):
but is also much harder to maintain/debug, as the vectorized regexes
are hard to work with, and to know which row is causing problems.
"""
if 'lastCheckpoint' not in self.data.columns:
Copy link
Contributor

Choose a reason for hiding this comment

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

Do you also need this check in augmentDataSlow?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I actually tested and didn't, but it was because I was getting zero rows of data, and thus the iterrows() there was meaning that line never got hit, so you're right, if I only got few but non-zero lines that would need be necessary! Thanks - added 👍

@mfisherlevine mfisherlevine merged commit 5211ad5 into main Oct 26, 2023
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants