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

Fix seqfeature strand arg #4

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

Conversation

Atishaysjain
Copy link

Issue:
The script fails with a TypeError upon calling the snapgene_file_to_seqrecord function. The error message is: TypeError: init() got an unexpected keyword argument 'strand'. This occurs because the 'strand' information is being directly passed to the SeqFeature constructor.

Proposed solution:
I have modified the snapgene_file_to_seqrecord function to correctly include the strand information within the FeatureLocation object, rather than as a direct argument to the SeqFeature constructor. I have done so by deleting the line:

strand=strand_dict[feature["strand"]]

This resolves the TypeError.

images showing the issue and its resolution:

Error:

Screenshot 2024-01-21 at 8 26 47 PM

Result after implementing the proposed solution:

Screenshot 2024-01-21 at 8 25 24 PM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant