Skip to content

Conversation

@odcambc
Copy link
Contributor

@odcambc odcambc commented Dec 4, 2024

Due to python 2 deprecation and lack of arm64 builds on conda, enrich2 is increasingly difficult to use. This PR updates enrich2 to run on python 3.

Besides general 2to3 changes, the major change is byte handling. Some functions work on bytes, others on strings. This attempts to make them generally operate on bytes, however some functions apparently still return strings. This includes a test for those cases.

This PR also fixes several bugs, primarily with writing a raw counts CSV file. This was prone to printing NA values. This should work properly now (fixes #44). Default Illumina headers have changed as well, so this updates that regex (possibly fixes #39)

This was tested on the example dataset (barcoded variants read from bzipped fastqs) as well as some of our own datasets (tsvs of identifier counts) and should be working. The example dataset doesn't include expected results to benchmark against, however, so I can't confirm it is identical.

@afrubin afrubin changed the base branch from main to release-2.0.0 December 7, 2024 02:30
@afrubin
Copy link
Member

afrubin commented Dec 7, 2024

Thanks for this! We made an attempt at this early in Python3 and it was a lot of work, so we really appreciate the PR.

We've been working on a replacement for Enrich2 but it won't fully replicate the old behavior and it's good to have an updated version for labs who want to reproduce old analysis.

I've re-targeted the PR at a new branch for a release 2.0.0 and will run a few checks on my side before merging it and making a new release.

@afrubin afrubin merged commit 8ff0cc8 into FowlerLab:release-2.0.0 Dec 7, 2024
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.

Unable to start analysis Counts tsv files on experiement level contain only NAs

2 participants