Skip to content

Commit 66a8283

Browse files
Merge pull request #296 from volkamerlab/base-ci-env-fix
Base branch for CI/env fixes
2 parents f4f4e8c + bbd7f9b commit 66a8283

File tree

7 files changed

+55
-26
lines changed

7 files changed

+55
-26
lines changed

.github/workflows/ci.yml

+11-4
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,10 @@ on:
44
push:
55
branches:
66
- "master"
7-
- "maintenance/.+"
87
pull_request:
98
branches:
109
- "master"
11-
- "maintenance/.+"
10+
- "base-ci-env-fix"
1211
schedule:
1312
# Run a cron job once weekly on Monday
1413
- cron: "0 3 * * 1"
@@ -76,10 +75,18 @@ jobs:
7675
shell: bash -l {0}
7776
run: |
7877
PYTEST_ARGS="--nbval-lax --current-env --dist loadscope --numprocesses 2"
78+
79+
# Ignore T019 under Windows, see https://github.com/volkamerlab/teachopencadd/issues/313
80+
PYTEST_IGNORE_T019="--ignore=teachopencadd/talktorials/T019_md_simulation/talktorial.ipynb"
81+
82+
# Temporarily ignored notebooks, see https://github.com/volkamerlab/teachopencadd/issues/303
83+
PYTEST_IGNORE_T008="--ignore=teachopencadd/talktorials/T008_query_pdb/talktorial.ipynb"
84+
7985
if [ "$RUNNER_OS" != "Windows" ]; then
80-
pytest $PYTEST_ARGS teachopencadd/talktorials/T*/talktorial.ipynb
86+
# Temporarily ignore T019
87+
pytest $PYTEST_ARGS teachopencadd/talktorials/ $PYTEST_IGNORE_T008 $PYTEST_IGNORE_T019
8188
else
82-
pytest $PYTEST_ARGS teachopencadd/talktorials/ --ignore=teachopencadd/talktorials/T008_md_simulation/talktorial.ipynb --ignore=teachopencadd/talktorials/T019_md_simulation/talktorial.ipynb
89+
pytest $PYTEST_ARGS teachopencadd/talktorials/ $PYTEST_IGNORE_T008 $PYTEST_IGNORE_T019
8390
fi
8491
8592
format:

devtools/test_env.yml

+9-12
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,24 @@
1-
name: teachopencadd
1+
name: teachopencadd
22
channels:
33
- conda-forge
44
- defaults
55
dependencies:
66
- python>=3.8
77
- pip
8-
- jupyter
98
- jupyterlab>=3
9+
# Workaround for jupyterlab, see https://github.com/volkamerlab/teachopencadd/issues/310
10+
- jsonschema>=4.3.0
1011
- nglview>=3
11-
# https://github.com/volkamerlab/teachopencadd/issues/262
12+
# Workaround for nglview, see https://github.com/volkamerlab/teachopencadd/issues/262
1213
- ipywidgets<8
13-
# Explicitly add numpy because of https://github.com/volkamerlab/teachopencadd/issues/150
14-
- numpy
14+
# New numpy version 1.2.4 too young, e.g. caused
15+
# https://github.com/volkamerlab/teachopencadd/issues/299
16+
- numpy<1.24
1517
- scikit-learn
1618
# API changed after v2.6, see https://github.com/volkamerlab/teachopencadd/issues/265
1719
- tensorflow<=2.6
1820
- seaborn
1921
- matplotlib-venn
20-
# Remove jsonschema once this issue is fixed: https://github.com/Yelp/bravado/issues/478
21-
- jsonschema<4.0.0
2222
- bravado
2323
- requests
2424
- requests-cache
@@ -38,15 +38,14 @@ dependencies:
3838
- mdtraj
3939
- plip
4040
- openmm
41-
# depends on openff-toolkit->ambertools -> not available on Windows yet!
41+
# Dependency not included, see https://github.com/volkamerlab/teachopencadd/issues/313
4242
# - openmmforcefields
4343
- pdbfixer
4444
- tqdm
4545
- lxml
4646
- kissim
4747
## CI tests
48-
# Workaround for https://github.com/computationalmodelling/nbval/issues/153
49-
- pytest 5.*
48+
- pytest
5049
- pytest-xdist
5150
- pytest-cov
5251
- nbval
@@ -62,8 +61,6 @@ dependencies:
6261
- sphinx-copybutton
6362
- sphinx-gallery
6463
- autodocsumm
65-
## temporary fix for rdkit on MacOS
66-
- fontconfig==2.13.1
6764
- pip:
6865
- black-nb
6966
- nbsphinx-link

teachopencadd/talktorials/T008_query_pdb/README.md

+9
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,12 @@
1+
<div class="alert alert-block alert-danger">
2+
3+
<b>TeachOpenCADD note</b>: This notebook uses the Ligand Expo website (http://ligand-expo.rcsb.org/), which will be offline in January 2023. During that time, T008 will not work in its entirety. Please check the following issue to track when this notebook will be available again: https://github.com/volkamerlab/teachopencadd/issues/303
4+
5+
<b>Ligand Expo website note</b>: "Ligand Expo will be down from January 1-31, 2023. Requests to this service will return a 410 http error code (“Gone”) and a message to contact RCSB PDB."
6+
7+
</div>
8+
9+
110
# T008 · Protein data acquisition: Protein Data Bank (PDB)
211

312
**Note:** This talktorial is a part of TeachOpenCADD, a platform that aims to teach domain-specific skills and to provide pipeline templates as starting points for research projects.

teachopencadd/talktorials/T008_query_pdb/talktorial.ipynb

+13
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,18 @@
11
{
22
"cells": [
3+
{
4+
"cell_type": "markdown",
5+
"metadata": {},
6+
"source": [
7+
"<div class=\"alert alert-block alert-danger\">\n",
8+
"\n",
9+
"<b>TeachOpenCADD note</b>: This notebook uses the Ligand Expo website (http://ligand-expo.rcsb.org/), which will be offline in January 2023. During that time, T008 will not work in its entirety. Please check the following issue to track when this notebook will be available again: https://github.com/volkamerlab/teachopencadd/issues/303\n",
10+
" \n",
11+
"<b>Ligand Expo website note</b>: \"Ligand Expo will be down from January 1-31, 2023. Requests to this service will return a 410 http error code (“Gone”) and a message to contact RCSB PDB.\"\n",
12+
"\n",
13+
"</div>"
14+
]
15+
},
316
{
417
"cell_type": "markdown",
518
"metadata": {},

teachopencadd/talktorials/T018_automated_cadd_pipeline/talktorial.ipynb

+1-2
Original file line numberDiff line numberDiff line change
@@ -2348,8 +2348,7 @@
23482348
}
23492349
],
23502350
"source": [
2351-
"project1.BindingSiteDetection.dogsitescorer_binding_sites_df.head()\n",
2352-
"# NBVAL_CHECK_OUTPUT"
2351+
"project1.BindingSiteDetection.dogsitescorer_binding_sites_df.head()"
23532352
]
23542353
},
23552354
{

teachopencadd/talktorials/T019_md_simulation/talktorial.ipynb

+11-8
Original file line numberDiff line numberDiff line change
@@ -353,7 +353,11 @@
353353
"source": [
354354
"import sys\n",
355355
"if not on_colab and sys.platform.startswith((\"linux\", \"darwin\")):\n",
356-
" !conda install -q -y -c conda-forge openmmforcefields"
356+
" !mamba install -q -y -c conda-forge openmmforcefields\n",
357+
" # Notes:\n",
358+
" # - If you do not have mamba installed, install it or use conda instead\n",
359+
" # - Under MacOS with an M1 chip you may need to use\n",
360+
" # CONDA_SUBDIR=osx-64 in front of the above command"
357361
]
358362
},
359363
{
@@ -394,9 +398,9 @@
394398
"from rdkit.Chem import AllChem\n",
395399
"import mdtraj as md\n",
396400
"import pdbfixer\n",
397-
"import simtk.openmm as mm\n",
398-
"import simtk.openmm.app as app\n",
399-
"from simtk.openmm import unit\n",
401+
"import openmm as mm\n",
402+
"import openmm.app as app\n",
403+
"from openmm import unit\n",
400404
"from openff.toolkit.topology import Molecule, Topology\n",
401405
"from openmmforcefields.generators import GAFFTemplateGenerator"
402406
]
@@ -718,10 +722,9 @@
718722
" mol_topology = off_mol_topology.to_openmm()\n",
719723
" mol_positions = off_mol.conformers[0]\n",
720724
"\n",
721-
" # convert units from Ångström to Nanometers\n",
722-
" for atom in mol_positions:\n",
723-
" coords = atom / atom.unit\n",
724-
" atom = (coords / 10.0) * unit.nanometers # since openmm works in nm\n",
725+
" # convert units from Ångström to nanometers\n",
726+
" # since OpenMM works in nm\n",
727+
" mol_positions = mol_positions.to(\"nanometers\")\n",
725728
"\n",
726729
" # combine topology and positions in modeller object\n",
727730
" omm_mol = app.Modeller(mol_topology, mol_positions)\n",

teachopencadd/talktorials/T022_ligand_based_screening_neural_network/talktorial.ipynb

+1
Original file line numberDiff line numberDiff line change
@@ -375,6 +375,7 @@
375375
"import numpy as np\n",
376376
"from rdkit import Chem\n",
377377
"from rdkit.Chem import MACCSkeys, Draw\n",
378+
"from rdkit.Chem.AllChem import GetMorganFingerprintAsBitVect\n",
378379
"from sklearn.model_selection import train_test_split\n",
379380
"import matplotlib.pyplot as plt\n",
380381
"from sklearn import metrics\n",

0 commit comments

Comments
 (0)