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 failing examples in gallery #720

Merged
merged 4 commits into from
Dec 20, 2024
Merged
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
2 changes: 1 addition & 1 deletion .github/workflows/test_and_deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ env:
# mussllinux takes 6+ hrs to build and test so ignore it
CIBW_TEST_SKIP: "*musllinux* *-macosx_arm64"
# Configuration for the architecture-agnostic jobs
PY_VERSION: "3.12" # Keep in sync with version in environment.yml
PY_VERSION: "3.11" # Keep in sync with version in environment.yml


jobs:
Expand Down
3 changes: 2 additions & 1 deletion doc/switcher.py
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,7 @@ def create_switcher_json(file_path, min_tag, n_versions):
}
)
# Mark the latest version as preferred
version_config[-1]["preferred"] = True
if len(version_config) > 0:
version_config[-1]["preferred"] = True
with open(file_path, "w") as file:
json.dump(version_config, file, indent=4)
4 changes: 2 additions & 2 deletions doc/tutorial/structure/io.rst
Original file line number Diff line number Diff line change
Expand Up @@ -211,9 +211,9 @@ automatically - from a single :class:`BinaryCIFData` to an entire
.. jupyter-execute::

uncompressed_data = pdbx.BinaryCIFData(np.arange(100))
print(f"Uncompressed size: {len(uncompressed_data.serialize()["data"])} bytes")
print(f"Uncompressed size: {len(uncompressed_data.serialize()['data'])} bytes")
compressed_data = pdbx.compress(uncompressed_data)
print(f"Compressed size: {len(compressed_data.serialize()["data"])} bytes")
print(f"Compressed size: {len(compressed_data.serialize()['data'])} bytes")


Using structures from a PDBx file
Expand Down
4 changes: 2 additions & 2 deletions environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ channels:
- salilab

dependencies:
- python =3.12
- python =3.11
# Package building
- cython >=3.0
- pip >=10.0
Expand All @@ -34,7 +34,7 @@ dependencies:
- dssp =3
- mafft
- muscle =3
- sra-tools
- sra-tools =3
- tantan
- viennarna >=2.5.0
# Documentation building
Expand Down
2 changes: 1 addition & 1 deletion src/biotite/sequence/io/genbank/file.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ class GenBankFile(TextFile):
>>> print(content)
['One line', 'A second line']
>>> print(subfields)
OrderedDict({'SUBFIELD1': ['Single Line'], 'SUBFIELD2': ['Two', 'lines']})
OrderedDict([('SUBFIELD1', ['Single Line']), ('SUBFIELD2', ['Two', 'lines'])])

Adding an additional field:

Expand Down
7 changes: 7 additions & 0 deletions tests/application/test_sra.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,12 @@
from biotite.application.sra import FastaDumpApp, FastqDumpApp
from biotite.sequence.io.fasta import FastaFile
from biotite.sequence.io.fastq import FastqFile
from tests.util import is_not_installed


@pytest.mark.skipif(
is_not_installed("fasterq-dump"), reason="sra-tools is not installed"
)
@pytest.mark.parametrize(
"app_class, custom_prefix",
itertools.product([FastqDumpApp, FastaDumpApp], [False, True]),
Expand Down Expand Up @@ -42,6 +46,9 @@ def test_objects(app_class, custom_prefix):
assert isinstance(fasta_file, FastaFile)


@pytest.mark.skipif(
is_not_installed("fasterq-dump"), reason="sra-tools is not installed"
)
@pytest.mark.parametrize(
"app_class, custom_prefix",
itertools.product([FastqDumpApp, FastaDumpApp], [False, True]),
Expand Down
Loading