Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 31 additions & 2 deletions .github/workflows/continuous_integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,41 @@ jobs:

- name: Install selenoprofiles4 in Conda environment
run: |
conda install -n sp4 -y -c mmariotti -c anaconda -c bioconda -c biobuilds selenoprofiles4
conda install -n sp4 -y -c mmariotti -c anaconda -c bioconda -c biobuilds selenoprofiles4 blast
pip install -e .[addons]

- name: Check BLAST+ backend is available
run: |
which makeblastdb
which psiblast
which tblastn
makeblastdb -version
psiblast -version
tblastn -version
conda list -n sp4 | grep -E '^(blast|blast-legacy|selenoprofiles4)\s'

- name: Run selenoprofiles test
run: |
echo "Running selenoprofiles test..."
selenoprofiles -setup
yes "" | selenoprofiles -download || true
selenoprofiles test
selenoprofiles test || {
status=$?
echo "::group::selenoprofiles test logs"
for log in log_test*; do
if [ -f "$log" ]; then
echo "===== $log ====="
tail -n 300 "$log"
fi
done
echo "::endgroup::"
exit "$status"
}

- name: Upload selenoprofiles test logs
if: failure()
uses: actions/upload-artifact@v4
with:
name: selenoprofiles-test-logs
path: log_test*
if-no-files-found: ignore
8 changes: 3 additions & 5 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,6 @@ RUN apt-get update && apt-get install -y \

RUN pip install selenoprofiles4[addons]

ENV PATH=$PATH:/blast-2.2.26/bin

RUN wget https://ftp.ncbi.nlm.nih.gov/blast/executables/legacy.NOTSUPPORTED/2.2.26/blast-2.2.26-x64-linux.tar.gz && \
tar -xzvf blast-2.2.26-x64-linux.tar.gz

# Run selenoprofiles setup and download commands
RUN selenoprofiles -setup && \
yes "" | selenoprofiles -download
Expand All @@ -38,4 +33,7 @@ RUN conda install -c anaconda gawk

RUN conda install bioconda::wise2

# BLAST+ backend: provides makeblastdb, psiblast and tblastn.
RUN conda install bioconda::blast

RUN conda install -c mmariotti -c conda-forge -c etetoolkit ncbi_db
12 changes: 11 additions & 1 deletion docs/installation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,12 @@ Then **install selenoprofiles4** and its dependencies in the sp4 environment::

conda install -c mmariotti -c anaconda -c bioconda -c biobuilds selenoprofiles4

Selenoprofiles 4.6 uses the BLAST+ package by default. If you install from
source or maintain your own environment, make sure BLAST+ is present; it
provides ``makeblastdb``, ``psiblast`` and ``tblastn``::

conda install -c bioconda blast

If everything worked correctly, the selenoprofiles command is now available, but it is still not setup.
Run this and follow instructions::

Expand Down Expand Up @@ -97,5 +103,9 @@ Check the :doc:`get_started` page to start using selenoprofiles.

CONDA_SUBDIR=osx-64 conda install -c mmariotti -c anaconda -c bioconda -c biobuilds selenoprofiles4

After this, installation should succeed and *selenoprofiles4* will work normally on Apple Silicon.
For source/development installs, also ensure BLAST+ is installed in the
osx-64 environment::

CONDA_SUBDIR=osx-64 conda install -c bioconda blast

After this, installation should succeed and *selenoprofiles4* will work normally on Apple Silicon.
3 changes: 2 additions & 1 deletion meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,8 @@ requirements:
run:
- python >=3.12, <3.13
- requests
- bioconda::blast-legacy
# BLAST+ binaries: makeblastdb, psiblast and tblastn.
- bioconda::blast
- bioconda::wise2
- bioconda::exonerate
- bioconda::mafft
Expand Down
2 changes: 1 addition & 1 deletion src/selenoprofiles4/_version.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__="4.5.7"
__version__="4.6.0"
7 changes: 5 additions & 2 deletions src/selenoprofiles4/blaster_parser.awk
Original file line number Diff line number Diff line change
Expand Up @@ -168,8 +168,11 @@ if (in_target_line){


if ( /^>/) {
if (FULL_TARGET){ subject = substr($0, 2) }
else{ subject = substr($1, 2) }
# BLAST+ may print subject lines as "> subject" (space after >),
# for which $1 is just ">". Parse from the full line first.
subject = substr($0, 2)
gsub(/^ +/, "", subject)
if (!FULL_TARGET){ split(subject, SUBJECT_SPLIT, " "); subject = SUBJECT_SPLIT[1] }

if (line_start==-1)
{line_start = NR }
Expand Down
1 change: 1 addition & 0 deletions src/selenoprofiles4/load_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
selenoprofiles_data_dir = ~/selenoprofiles_data/
ncpus = 1
temp = /tmp/
blast_backend = blastplus

profiles_folder = {selenoprofiles_data_dir}/selenoprotein_profiles
bin_folder =
Expand Down
Loading
Loading