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

Create locations DataFrame with a strain index #1066

Merged
merged 2 commits into from May 1, 2023

Conversation

victorlin
Copy link
Member

Description of proposed changes

Prior to that commit, DataFrames were not indexed by strain and used the
default counter index. The concat relied on both the locations and
metadata DataFrames having the same counter index. This was broken in
the linked commit when the metadata was switched to index on strain.

Solutions are to either (1) revert to using counter index for both, (2)
use strain index for both, or (3) ignore the index when concatenating.

A strain index has benefits and is used elsewhere in the script, so this
commit implements solution (2).

Related issue(s)

Follow-up to #1062

Testing

What steps should be taken to test the changes you've proposed?
If you added or changed behavior in the codebase, did you update the tests, or do you need help with this?

  • Added and modified a test to show new behavior.

Release checklist

If this pull request introduces backward incompatible changes, complete the following steps for a new release of the workflow:

  • Determine the version number for the new release by incrementing the most recent release (e.g., "v2" from "v1").
  • Update docs/src/reference/change_log.md in this pull request to document these changes and the new version number.
  • After merging, create a new GitHub release with the new version number as the tag and release title.

If this pull request introduces new features, complete the following steps:

  • Update docs/src/reference/change_log.md in this pull request to document these changes by the date they were added.

This is a follow-up fix to 2ec3135.

Prior to that commit, DataFrames were not indexed by strain and used the
default counter index. The concat relied on both the locations and
metadata DataFrames having the same counter index. This was broken in
the linked commit when the metadata was switched to index on strain.

Solutions are to either (1) revert to using counter index for both, (2)
use strain index for both, or (3) ignore the index when concatenating.

A strain index has benefits and is used elsewhere in the script, so this
commit implements solution (2).
@victorlin victorlin requested a review from a team April 27, 2023 23:31
@victorlin victorlin self-assigned this Apr 27, 2023
@victorlin
Copy link
Member Author

Merging because this works for myself and another user.

@victorlin victorlin merged commit 4c5fc8f into master May 1, 2023
9 checks passed
@victorlin victorlin deleted the victorlin/fix-sanitize-metadata branch May 1, 2023 17:10
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.

None yet

1 participant