From 378de65268a416ff21047ec74d1bdd27028df332 Mon Sep 17 00:00:00 2001 From: John SJ Anderson Date: Tue, 30 Apr 2024 10:53:35 -0700 Subject: [PATCH 1/5] Update ambiant install docs to specify Python version I also modified the overall intent of the instructions slightly, so that they direct the user to set up a new Conda environment. The old instructions were oriented more towards adding Nextstrain to an existing Conda enviroment, which (IMO) seems like a less common scenario, and also one more likely to be undertaken by a more experienced user who will be able to adapt these instructions on the fly. --- src/install.rst | 2 +- src/snippets/ambient-setup.rst | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/install.rst b/src/install.rst index 7b564991..a7001178 100644 --- a/src/install.rst +++ b/src/install.rst @@ -213,7 +213,7 @@ Set up a Nextstrain runtime The ambient runtime does not require a particular setup method; it will work as long as the programs you wish to use are available. - The following describes how to accomplish this using a custom Conda environment as an example. You should be familiar with the `basics of Conda `__ before proceeding. + The following describes how to accomplish this by creating a new custom Conda environment, as an example. You should be familiar with the `basics of Conda `__ before proceeding. If you want to add Nextstrain to an existing Conda environment, please make sure you're using a compatible Python version (we suggest v3.10.13) and activate that environment instead of creating a new one. .. tabs:: diff --git a/src/snippets/ambient-setup.rst b/src/snippets/ambient-setup.rst index eebd5421..0e3bf3d6 100644 --- a/src/snippets/ambient-setup.rst +++ b/src/snippets/ambient-setup.rst @@ -1,8 +1,11 @@ -1. Activate a Conda environment that you wish to use: +1. Create a new Conda environment and install Python 3.10.13: .. code-block:: bash + conda create -n conda activate + conda install --override-channels --strict-channel-priority \ + -c conda-forge --yes python=3.10.13 2. Install all the necessary software: From 8630b7cd1672260353152462172105516bcaec8a Mon Sep 17 00:00:00 2001 From: John SJ Anderson Date: Tue, 30 Apr 2024 14:14:38 -0700 Subject: [PATCH 2/5] Add comment as suggested in PR feedback --- src/install.rst | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/install.rst b/src/install.rst index a7001178..ed5adf3f 100644 --- a/src/install.rst +++ b/src/install.rst @@ -213,7 +213,8 @@ Set up a Nextstrain runtime The ambient runtime does not require a particular setup method; it will work as long as the programs you wish to use are available. - The following describes how to accomplish this by creating a new custom Conda environment, as an example. You should be familiar with the `basics of Conda `__ before proceeding. If you want to add Nextstrain to an existing Conda environment, please make sure you're using a compatible Python version (we suggest v3.10.13) and activate that environment instead of creating a new one. + .. Suggest Python 3.10.13 because Augur on Bioconda won't resolve dependencies on Python ≥3.11: + The following describes how to accomplish this by creating a new custom Conda environment, as an example. You should be familiar with the `basics of Conda `__ before proceeding. If you want to add Nextstrain to an existing Conda environment, please make sure you're using Python ≤3.10 and activate that environment instead of creating a new one. .. tabs:: From db6588da0459d5d93b9af11c2ba8a82954f948d7 Mon Sep 17 00:00:00 2001 From: John SJ Anderson Date: Tue, 30 Apr 2024 14:15:02 -0700 Subject: [PATCH 3/5] Revise conda bits based on PR feedback and further experimentation --- src/snippets/ambient-setup.rst | 20 +++++++++----------- 1 file changed, 9 insertions(+), 11 deletions(-) diff --git a/src/snippets/ambient-setup.rst b/src/snippets/ambient-setup.rst index 0e3bf3d6..bf0c9922 100644 --- a/src/snippets/ambient-setup.rst +++ b/src/snippets/ambient-setup.rst @@ -1,22 +1,20 @@ -1. Create a new Conda environment and install Python 3.10.13: +1. Create a new Conda environment and install all the necessary software: .. code-block:: bash - conda create -n - conda activate - conda install --override-channels --strict-channel-priority \ - -c conda-forge --yes python=3.10.13 - -2. Install all the necessary software: - - .. code-block:: bash - - conda install --override-channels --strict-channel-priority \ + conda create -n \ + --override-channels --strict-channel-priority \ -c conda-forge -c bioconda --yes \ augur auspice nextclade \ snakemake git epiweeks pangolin pangolearn \ ncbi-datasets-cli csvtk seqkit tsv-utils +2. Activate the runtime: + + .. code-black:: bash + + conda activate + 3. Set the runtime: .. code-block:: none From 990685041e42238eda142570b36d3aa6d47a736f Mon Sep 17 00:00:00 2001 From: John SJ Anderson Date: Tue, 30 Apr 2024 14:44:13 -0700 Subject: [PATCH 4/5] Tyop --- src/snippets/ambient-setup.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/snippets/ambient-setup.rst b/src/snippets/ambient-setup.rst index bf0c9922..c863e2da 100644 --- a/src/snippets/ambient-setup.rst +++ b/src/snippets/ambient-setup.rst @@ -11,7 +11,7 @@ 2. Activate the runtime: - .. code-black:: bash + .. code-block:: bash conda activate From c8d465252526474676f8c02ab50bc91f23671c70 Mon Sep 17 00:00:00 2001 From: John SJ Anderson Date: Tue, 30 Apr 2024 14:44:48 -0700 Subject: [PATCH 5/5] More PR feedback --- src/install.rst | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/install.rst b/src/install.rst index ed5adf3f..c966305c 100644 --- a/src/install.rst +++ b/src/install.rst @@ -213,7 +213,8 @@ Set up a Nextstrain runtime The ambient runtime does not require a particular setup method; it will work as long as the programs you wish to use are available. - .. Suggest Python 3.10.13 because Augur on Bioconda won't resolve dependencies on Python ≥3.11: + .. Suggest Python ≤3.10 because Augur on Bioconda won't resolve dependencies on Python ≥3.11: + The following describes how to accomplish this by creating a new custom Conda environment, as an example. You should be familiar with the `basics of Conda `__ before proceeding. If you want to add Nextstrain to an existing Conda environment, please make sure you're using Python ≤3.10 and activate that environment instead of creating a new one. .. tabs::