Skip to content

Commit

Permalink
replace export_to_level(2,@_) in each module called by AGAT::AGAT by …
Browse files Browse the repository at this point in the history
…AGAT::Module->export_to_level(1,@_) from AGAT::AGAT. This fix issiue related to replace export_to_level(2,@_) introduced in perl 5.36. Fix #416 #392
  • Loading branch information
Juke34 committed Dec 3, 2024
1 parent 01677bf commit 9e3951d
Show file tree
Hide file tree
Showing 10 changed files with 9 additions and 42 deletions.
10 changes: 9 additions & 1 deletion lib/AGAT/AGAT.pm
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,15 @@ our $VERSION = "v1.4.1";
our @ISA = qw(Exporter);
our @EXPORT = qw(get_agat_header print_agat_version get_agat_config handle_levels);
sub import {
AGAT::AGAT->export_to_level(1, @_); # to be able to load the EXPORT functions when direct call; (normal case)
AGAT::AGAT->export_to_level(1, @_); # to be able to load the EXPORT functions when direct call; (normal case)
AGAT::OmniscientI->export_to_level(1, @_);
AGAT::OmniscientO->export_to_level(1, @_);
AGAT::OmniscientTool->export_to_level(1, @_);
AGAT::Config->export_to_level(1, @_);
AGAT::Levels->export_to_level(1, @_);
AGAT::OmniscientStat->export_to_level(1, @_);
AGAT::Utilities->export_to_level(1, @_);
AGAT::PlotR->export_to_level(1, @_);
}

=head1 SYNOPSIS
Expand Down
4 changes: 0 additions & 4 deletions lib/AGAT/Config.pm
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,6 @@ use Exporter;

our @ISA = qw(Exporter);
our @EXPORT = qw( load_config expose_config_file check_config get_config expose_config_hash );
sub import {
AGAT::Config->export_to_level(1, @_); # to be able to load the EXPORT functions when direct call; (normal case)
AGAT::Config->export_to_level(2, @_); # to be able to load the EXPORT functions when called from one level up;
}

=head1 SYNOPSIS
Expand Down
4 changes: 0 additions & 4 deletions lib/AGAT/Levels.pm
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,6 @@ use Exporter;

our @ISA = qw(Exporter);
our @EXPORT = qw( get_levels_info load_levels expose_levels get_feature_type_by_agat_value );
sub import {
AGAT::Levels->export_to_level(1, @_); # to be able to load the EXPORT functions when direct call; (normal case)
AGAT::Levels->export_to_level(2, @_); # to be able to load the EXPORT functions when called from one level up;
}

=head1 SYNOPSIS
Expand Down
4 changes: 0 additions & 4 deletions lib/AGAT/OmniscientI.pm
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,6 @@ our @ISA = qw(Exporter);
our @EXPORT = qw(get_level select_gff_format
modelate_utr_and_cds_features_from_exon_features_and_cds_start_stop
slurp_gff3_file_JD);
sub import {
AGAT::OmniscientI->export_to_level(1, @_); # to be able to load the EXPORT functions when direct call; (normal case)
AGAT::OmniscientI->export_to_level(2, @_); # to be able to load the EXPORT functions when called from one level up;
}

=head1 SYNOPSIS
Expand Down
5 changes: 0 additions & 5 deletions lib/AGAT/OmniscientO.pm
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,6 @@ our @EXPORT = qw(print_ref_list_feature print_omniscient print_omniscient_as_mat
print_omniscient_from_level1_id_list webapollo_compliant embl_compliant
convert_omniscient_to_ensembl_style write_top_features prepare_gffout prepare_fileout);

sub import {
AGAT::OmniscientO->export_to_level(1, @_); # to be able to load the EXPORT functions when direct call; (normal case)
AGAT::OmniscientO->export_to_level(2, @_); # to be able to load the EXPORT functions when called from one level up;
}

=head1 SYNOPSIS
This is the code to output data store in Omniscient.
Expand Down
5 changes: 0 additions & 5 deletions lib/AGAT/OmniscientStat.pm
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,6 @@ use Exporter;
our @ISA = qw(Exporter);
our @EXPORT = qw( print_omniscient_statistics );

sub import {
AGAT::OmniscientStat->export_to_level(1, @_); # to be able to load the EXPORT functions when direct call; (normal case)
AGAT::OmniscientStat->export_to_level(2, @_); # to be able to load the EXPORT functions when called from one level up;
}

=head1 SYNOPSIS
This is the code to perform statisctis of data store in Omniscient.
Expand Down
5 changes: 0 additions & 5 deletions lib/AGAT/OmniscientToGTF.pm
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,6 @@ use Exporter;
our @ISA = qw(Exporter);
our @EXPORT = qw(print_omniscient_as_gtf);

sub import {
AGAT::OmniscientToGTF->export_to_level(1, @_); # to be able to load the EXPORT functions when direct call; (normal case)
AGAT::OmniscientToGTF->export_to_level(2, @_); # to be able to load the EXPORT functions when called from one level up;
}

# --------------------------- INFO ---------------------------
# Set GTF version definitions
#my @GTF3 = ("gene", "transcript", "exon", "CDS", "Selenocysteine", "start_codon", "stop_codon", "three_prime_utr", "five_prime_utr");
Expand Down
5 changes: 0 additions & 5 deletions lib/AGAT/OmniscientTool.pm
Original file line number Diff line number Diff line change
Expand Up @@ -33,11 +33,6 @@ remove_l1_and_relatives remove_l2_and_relatives remove_l3_and_relatives get_long
check_mrna_positions check_features_overlap initialize_omni_from clean_clone
create_omniscient get_cds_from_l2 merge_overlap_loci get_uniq_id );

sub import {
AGAT::OmniscientTool->export_to_level(1, @_); # to be able to load the EXPORT functions when direct call; (normal case)
AGAT::OmniscientTool->export_to_level(2, @_); # to be able to load the EXPORT functions when called from one level up;
}

=head1 SYNOPSIS
This is the code to handle data store in Omniscient.
Expand Down
4 changes: 0 additions & 4 deletions lib/AGAT/PlotR.pm
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,6 @@ use AGAT::Utilities;

our @ISA = qw(Exporter);
our @EXPORT = qw(execute_R_command rcc_density_one_row_per_file rcc_plot_from_list may_i_plot);
sub import {
AGAT::PlotR->export_to_level(1, @_); # to be able to load the EXPORT functions when direct call; (normal case)
AGAT::PlotR->export_to_level(2, @_); # to be able to load the EXPORT functions when called from one level up;
}

=head1 SYNOPSIS
Expand Down
5 changes: 0 additions & 5 deletions lib/AGAT/Utilities.pm
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,6 @@ our @EXPORT = qw(exists_keys exists_undef_value get_proper_codon_table surround_
sizedPrint activate_warning_limit print_time dual_print file_text_line print_wrap_text
string_sep_to_hash);

sub import {
AGAT::Utilities->export_to_level(1, @_); # to be able to load the EXPORT functions when direct call; (normal case)
AGAT::Utilities->export_to_level(2, @_); # to be able to load the EXPORT functions when called from one level up;
}

=head1 SYNOPSIS
package containing utility tools
Expand Down

0 comments on commit 9e3951d

Please sign in to comment.