Skip to content

Commit

Permalink
Fix load of RNA ID that looks like a transcript ID
Browse files Browse the repository at this point in the history
"SPNCRNA.5" was confusing the code because it looks like the 5th transcript
of gene "SPNCRNA".  Fixed by adding special cases in the code.

Refs pombase/pombase-chado#904
  • Loading branch information
kimrutherford committed Jan 13, 2022
1 parent 5d94f69 commit 32e0372
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
3 changes: 2 additions & 1 deletion lib/PomBase/Chado/LoadFeat.pm
Original file line number Diff line number Diff line change
Expand Up @@ -682,7 +682,8 @@ sub store_transcript_parts {
my $introns = shift;

my $uniquename = ($bioperl_cds->get_tag_values('systematic_id'))[0];
if ($uniquename !~ /\.\d$/) {

if ($uniquename !~ /\.\d$/ || $uniquename =~ /^SPNCRNA\.\d+$/) {
$uniquename .= '.1';
}

Expand Down
6 changes: 4 additions & 2 deletions lib/PomBase/Role/Embl/SystematicID.pm
Original file line number Diff line number Diff line change
Expand Up @@ -101,8 +101,10 @@ sub get_uniquename {

# warn "BEFORE $so_type - systematic_id: $systematic_id\n";

if ($is_transcript && $systematic_id !~ /\.\d$/) {
$systematic_id .= '.1';
if ($is_transcript) {
if ($systematic_id =~ /^SPNCRNA\.\d+$/ || $systematic_id !~ /\.\d$/) {
$systematic_id .= '.1';
}
}

# warn "AFTER $so_type - systematic_id: $systematic_id\n";
Expand Down

0 comments on commit 32e0372

Please sign in to comment.