Skip to content

Commit

Permalink
Fix broken links + update pyproject for poetry 2 (#332)
Browse files Browse the repository at this point in the history
* closes #331

* closes #333

* use poetry 1.8 for python 3.8 tests

* update pyproject to work with poetry 1.8

* fix installation line in google collab

* fix pyproject.toml and README instructions for poetry

* clean notebooks

* fix author string for poetry 1.8
  • Loading branch information
manulera authored Jan 17, 2025
1 parent 2bf4f68 commit ff5ba41
Show file tree
Hide file tree
Showing 29 changed files with 122 additions and 127 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/pydna_test_and_coverage_workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ jobs:
uses: snok/install-poetry@v1
with:
virtualenvs.prefer-active-python: true

version: ${{ matrix.python-version == '3.8' && '1.8.2' || 'latest' }}
- name: 🔩 list Poetry settings
run: poetry config --list

Expand Down
19 changes: 11 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# ![icon](docs/_static/pydna.resized.png) pydna

| [![Tests & Coverage](https://github.com/BjornFJohansson/pydna/actions/workflows/pydna_test_and_coverage_workflow.yml/badge.svg?branch=dev_bjorn)](https://github.com/BjornFJohansson/pydna/actions/workflows/pydna_test_and_coverage_workflow.yml) | [![codecov](https://codecov.io/gh/BjornFJohansson/pydna/branch/master/graph/badge.svg)](https://codecov.io/gh/BjornFJohansson/pydna/branch/master) | [![PyPI version](https://badge.fury.io/py/pydna.svg)](https://badge.fury.io/py/pydna) | [![Google group : pydna](https://img.shields.io/badge/Google%20Group-pydna-blue.svg)](https://groups.google.com/g/pydna) |
| -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------- |
| [![Documentation Status](https://github.com/BjornFJohansson/pydna/actions/workflows/publish-docs.yml/badge.svg)](https://github.com/BjornFJohansson/pydna/actions/workflows/publish-docs.yml) | [![GitHub issues](https://img.shields.io/github/issues/BjornFJohansson/pydna.svg)](https://github.com/BjornFJohansson/pydna/issues) | [![Anaconda-Server Badge2](https://anaconda.org/bjornfjohansson/pydna/badges/license.svg)](https://anaconda.org/bjornfjohansson/pydna) | [![GitHub stars](https://img.shields.io/github/stars/BjornFJohansson/pydna.svg)](https://github.com/BjornFJohansson/pydna/stargazers) |
| [![Tests & Coverage](https://github.com/pydna-group/pydna/actions/workflows/pydna_test_and_coverage_workflow.yml/badge.svg?branch=dev_bjorn)](https://github.com/pydna-group/pydna/actions/workflows/pydna_test_and_coverage_workflow.yml) | [![codecov](https://codecov.io/gh/BjornFJohansson/pydna/branch/master/graph/badge.svg)](https://codecov.io/gh/BjornFJohansson/pydna/branch/master) | [![PyPI version](https://badge.fury.io/py/pydna.svg)](https://badge.fury.io/py/pydna) | [![Google group : pydna](https://img.shields.io/badge/Google%20Group-pydna-blue.svg)](https://groups.google.com/g/pydna) |
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | -------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------- |
| [![Documentation Status](https://github.com/pydna-group/pydna/actions/workflows/publish-docs.yml/badge.svg)](https://github.com/pydna-group/pydna/actions/workflows/publish-docs.yml) | [![GitHub issues](https://img.shields.io/github/issues/BjornFJohansson/pydna.svg)](https://github.com/pydna-group/pydna/issues) | [![Anaconda-Server Badge2](https://anaconda.org/bjornfjohansson/pydna/badges/license.svg)](https://anaconda.org/bjornfjohansson/pydna) | [![GitHub stars](https://img.shields.io/github/stars/BjornFJohansson/pydna.svg)](https://github.com/pydna-group/pydna/stargazers) |

<!-- docs/index.rst-start -->

Expand Down Expand Up @@ -42,7 +42,7 @@ Pereira, F., Azevedo, F., Carvalho, Â., Ribeiro, G. F., Budde, M. W., & Johanss

## Documentation and usage 📚

Full documentation of all modules and classes can be found at [https://bjornfjohansson.github.io/pydna](https://bjornfjohansson.github.io/pydna).
Full documentation of all modules and classes can be found at [https://pydna-group.github.io/pydna](https://pydna-group.github.io/pydna).

To get started, we recommend you to have a look at the [example notebooks](docs/notebooks). Start by having a look at [Dseq](docs/notebooks/Dseq.ipynb), [Dseq_Features](docs/notebooks/Dseq_Features.ipynb) and [Importing_Seqs](docs/notebooks/Importing_Seqs.ipynb), which cover the basics of working with sequences. The rest of the notebooks cover how to use pydna for different cloning strategies, such as Gibson assembly, Restriction-Ligation, etc.

Expand Down Expand Up @@ -435,7 +435,10 @@ poetry config virtualenvs.in-project true
# Install dependencies (extras are required for tests to pass)
poetry install --all-extras

# Activate virtual environment
# Activate virtual environment (poetry version 2)
poetry env activate

# Activate virtual environment (poetry version 1)
poetry shell

# Install pre-commit hooks
Expand Down Expand Up @@ -487,7 +490,7 @@ supported python versions.
### Building the documentation locally 📚

Documentation is built using [Sphinx](http://www.sphinx-doc.org/) from [docstrings](https://www.python.org/dev/peps/pep-0257/)
using a GitHub [action](https://github.com/BjornFJohansson/pydna/actions/workflows/publish-docs.yml).
using a GitHub [action](https://github.com/pydna-group/pydna/actions/workflows/publish-docs.yml).
The [numpy](https://www.numpy.org) [docstring format](https://numpy.org/doc/stable/dev/howto-docs.html#docstring-intro) is used.

Below the commands to run a local sphinx server that auto-updated when files are changed.
Expand All @@ -505,7 +508,7 @@ More info about how to contribute to the documentation can be found [here](docs/

## Release process 🚀

See the [releases](https://github.com/BjornFJohansson/pydna/releases) for changes and releases.
See the [releases](https://github.com/pydna-group/pydna/releases) for changes and releases.

The build workflow builds a PyPI packages using poetry. This workflow is triggered by publishing a Github release manually from the Github web interface.

Expand Down Expand Up @@ -535,4 +538,4 @@ In Cold Spring Harbor Laboratory (p. 2021.01.17.427048). [DOI](https://doi.org/1

[An Automated Protein Synthesis Pipeline with Transcriptic and Snakemake](http://blog.booleanbiotech.com/transcriptic_protein_synthesis_pipeline.html)

and other projects on [github](https://github.com/BjornFJohansson/pydna/network/dependents?package_id=UGFja2FnZS01MjQ2MjYzNQ%3D%3D)
and other projects on [github](https://github.com/pydna-group/pydna/network/dependents?package_id=UGFja2FnZS01MjQ2MjYzNQ%3D%3D)
2 changes: 1 addition & 1 deletion docs/README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Documentation

Documentation is built using [Sphinx](http://www.sphinx-doc.org/) from [docstrings](https://www.python.org/dev/peps/pep-0257/)
using a GitHub [action](https://github.com/BjornFJohansson/pydna/actions/workflows/publish-docs.yml).
using a GitHub [action](https://github.com/pydna-group/pydna/actions/workflows/publish-docs.yml).
The [numpy](www.numpy.org) [docstring format](https://numpy.org/doc/stable/dev/howto-docs.html#docstring-intro) is used.

Below the commands to run a local sphinx server that auto-updated when files are changed.
Expand Down
2 changes: 1 addition & 1 deletion docs/cookbook/cookbook.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"<a target=\"_blank\" href=\"https://colab.research.google.com/github/BjornFJohansson/pydna/blob/dev_bjorn/docs/cookbook/cookbook.ipynb\">\n",
"<a target=\"_blank\" href=\"https://colab.research.google.com/github/pydna-group/pydna/blob/master/docs/cookbook/cookbook.ipynb\">\n",
" <img src=\"https://colab.research.google.com/assets/colab-badge.svg\" alt=\"Open In Colab\"/>\n",
"</a>"
]
Expand Down
2 changes: 1 addition & 1 deletion docs/getting_started.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@


The best way to get started is to follow our tutorial notebooks, you can find them in the
repository folder [docs/notebooks](https://github.com/BjornFJohansson/pydna/tree/main/docs/notebooks) and
repository folder [docs/notebooks](https://github.com/pydna-group/pydna/tree/master/docs/notebooks) and
are reproduced here so they can serve as documentation.

You can run the notebooks locally, but also on the browser using Google Colab, simply click in the badge of
Expand Down
11 changes: 4 additions & 7 deletions docs/notebooks/CRISPR.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"source": [
"# How to Model CRISPR-Cas9 Experiments in pydna\n",
"\n",
"> Visit the full library documentation [here](https://bjornfjohansson.github.io/pydna/)\n",
"> Visit the full library documentation [here](https://pydna-group.github.io/pydna/)\n",
"\n",
"The pydna package can simulate CRISPR-Cas9 editing, which allows one to cut DNA sequences at specific sites using guide RNAs (gRNAs) that direct the Cas9 protein. This page will guide you through the process of using the `pydna.crispr` module to model a CRISPR-Cas9 cut on a DNA sequence.\n",
"\n",
Expand All @@ -17,7 +17,7 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"<a target=\"_blank\" href=\"https://colab.research.google.com/github/BjornFJohansson/pydna/blob/dev_bjorn/docs/notebooks/CRISPR.ipynb\">\n",
"<a target=\"_blank\" href=\"https://colab.research.google.com/github/pydna-group/pydna/blob/master/docs/notebooks/CRISPR.ipynb\">\n",
" <img src=\"https://colab.research.google.com/assets/colab-badge.svg\" alt=\"Open In Colab\"/>\n",
"</a>"
]
Expand All @@ -28,14 +28,11 @@
"metadata": {},
"outputs": [],
"source": [
"%%capture\n",
"# Install pydna (only when running on Colab)\n",
"import sys\n",
"if 'google.colab' in sys.modules:\n",
" %%capture\n",
" # Install the current development version of pydna (comment to install pip version)\n",
" !pip install git+https://github.com/BjornFJohansson/pydna@dev_bjorn\n",
" # Install pip version instead (uncomment to install)\n",
" # !pip install pydna\n"
" %pip install pydna\n"
]
},
{
Expand Down
11 changes: 4 additions & 7 deletions docs/notebooks/Dseq.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,14 @@
"metadata": {},
"source": [
"# Representing sequences in pydna\n",
"> Visit the full library documentation [here](https://bjornfjohansson.github.io/pydna/)"
"> Visit the full library documentation [here](https://pydna-group.github.io/pydna/)"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"<a target=\"_blank\" href=\"https://colab.research.google.com/github/BjornFJohansson/pydna/blob/dev_bjorn/docs/notebooks/Dseq.ipynb\">\n",
"<a target=\"_blank\" href=\"https://colab.research.google.com/github/pydna-group/pydna/blob/master/docs/notebooks/Dseq.ipynb\">\n",
" <img src=\"https://colab.research.google.com/assets/colab-badge.svg\" alt=\"Open In Colab\"/>\n",
"</a>"
]
Expand All @@ -23,14 +23,11 @@
"metadata": {},
"outputs": [],
"source": [
"%%capture\n",
"# Install pydna (only when running on Colab)\n",
"import sys\n",
"if 'google.colab' in sys.modules:\n",
" %%capture\n",
" # Install the current development version of pydna (comment to install pip version)\n",
" !pip install git+https://github.com/BjornFJohansson/pydna@dev_bjorn\n",
" # Install pip version instead (uncomment to install)\n",
" # !pip install pydna\n"
" %pip install pydna\n"
]
},
{
Expand Down
11 changes: 4 additions & 7 deletions docs/notebooks/Dseq_Features.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"\n",
"> Before working with features, check how to import sequences from files in the [Importing_Seqs notebook](./Importing_Seqs.ipynb).\n",
">\n",
"> For full library documentation, visit [here](https://bjornfjohansson.github.io/pydna/).\n",
"> For full library documentation, visit [here](https://pydna-group.github.io/pydna/).\n",
"\n",
"Some sequence file formats (like Genbank) include features, describing key biological properties of sequence regions. In Genbank, features \"include genes, gene products, as well as regions of biological significance reported in the sequence.\" (See [here](https://www.ncbi.nlm.nih.gov/genbank/samplerecord/) for a description of a Genbank file and associated terminologies/annotations) Examples include coding sequences (CDS), introns, promoters, etc.\n",
"\n",
Expand All @@ -19,7 +19,7 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"<a target=\"_blank\" href=\"https://colab.research.google.com/github/BjornFJohansson/pydna/blob/dev_bjorn/docs/notebooks/Dseq_Features.ipynb\">\n",
"<a target=\"_blank\" href=\"https://colab.research.google.com/github/pydna-group/pydna/blob/master/docs/notebooks/Dseq_Features.ipynb\">\n",
" <img src=\"https://colab.research.google.com/assets/colab-badge.svg\" alt=\"Open In Colab\"/>\n",
"</a>"
]
Expand All @@ -30,14 +30,11 @@
"metadata": {},
"outputs": [],
"source": [
"%%capture\n",
"# Install pydna (only when running on Colab)\n",
"import sys\n",
"if 'google.colab' in sys.modules:\n",
" %%capture\n",
" # Install the current development version of pydna (comment to install pip version)\n",
" !pip install git+https://github.com/BjornFJohansson/pydna@dev_bjorn\n",
" # Install pip version instead (uncomment to install)\n",
" # !pip install pydna\n"
" %pip install pydna"
]
},
{
Expand Down
25 changes: 11 additions & 14 deletions docs/notebooks/Example_CRISPR.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,15 @@
"https://academic.oup.com/femsyr/article/doi/10.1093/femsyr/foae026/7740463?login=false "
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"<a target=\"_blank\" href=\"https://colab.research.google.com/github/pydna-group/pydna/blob/master/docs/notebooks/Example_CRISPR.ipynb\">\n",
" <img src=\"https://colab.research.google.com/assets/colab-badge.svg\" alt=\"Open In Colab\"/>\n",
"</a>"
]
},
{
"cell_type": "code",
"execution_count": null,
Expand Down Expand Up @@ -60,29 +69,17 @@
"- Let's see how this can be implemented in pydna\n"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"<a target=\"_blank\" href=\"https://colab.research.google.com/github/BjornFJohansson/pydna/blob/dev_bjorn/docs/notebooks/Example_CRISPR.ipynb\">\n",
" <img src=\"https://colab.research.google.com/assets/colab-badge.svg\" alt=\"Open In Colab\"/>\n",
"</a>"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"%%capture\n",
"# Install pydna (only when running on Colab)\n",
"import sys\n",
"if 'google.colab' in sys.modules:\n",
" %%capture\n",
" # Install the current development version of pydna (comment to install pip version)\n",
" !pip install git+https://github.com/BjornFJohansson/pydna@dev_bjorn\n",
" # Install pip version instead (uncomment to install)\n",
" # !pip install pydna\n"
" %pip install pydna\n"
]
},
{
Expand Down
11 changes: 4 additions & 7 deletions docs/notebooks/Example_Gibson.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"metadata": {},
"source": [
"# Example of a Gibson Assembly in pydna\n",
"> Visit the full library documentation [here](https://bjornfjohansson.github.io/pydna/)\n",
"> Visit the full library documentation [here](https://pydna-group.github.io/pydna/)\n",
"\n",
"This example showcases a workflow of modelling Gibson assembly to clone gene fragments into plasmids for synthetic biology. The biological example is sourced [here](https://www.nature.com/articles/nmeth.1318#MOESM319), from the original Gibson assembly paper. This example constructs a synthetic pCC1BAC plasmid by joining sequence fragments from Ruminiclostridium (Clostridium) cellulolyticum. The R. cellulolyticum fragments joined are termed F1, F2, and F3, as in the paper.\n",
"\n",
Expand All @@ -16,7 +16,7 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"<a target=\"_blank\" href=\"https://colab.research.google.com/github/BjornFJohansson/pydna/blob/dev_bjorn/docs/notebooks/Example_Gibson.ipynb\">\n",
"<a target=\"_blank\" href=\"https://colab.research.google.com/github/pydna-group/pydna/blob/master/docs/notebooks/Example_Gibson.ipynb\">\n",
" <img src=\"https://colab.research.google.com/assets/colab-badge.svg\" alt=\"Open In Colab\"/>\n",
"</a>"
]
Expand All @@ -27,14 +27,11 @@
"metadata": {},
"outputs": [],
"source": [
"%%capture\n",
"# Install pydna (only when running on Colab)\n",
"import sys\n",
"if 'google.colab' in sys.modules:\n",
" %%capture\n",
" # Install the current development version of pydna (comment to install pip version)\n",
" !pip install git+https://github.com/BjornFJohansson/pydna@dev_bjorn\n",
" # Install pip version instead (uncomment to install)\n",
" # !pip install pydna\n"
" %pip install pydna\n"
]
},
{
Expand Down
11 changes: 4 additions & 7 deletions docs/notebooks/Example_Restriction.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"metadata": {},
"source": [
"# Example of a Plasmid Restriction/Ligation Cloning\n",
"> Visit the full library documentation [here](https://bjornfjohansson.github.io/pydna/)\n",
"> Visit the full library documentation [here](https://pydna-group.github.io/pydna/)\n",
"\n",
"This example showcases a workflow of modelling molecular cloning with restriction enzymes, PCR, and ligases, to clone gene fragments into plasmids. This example constructs a synthetic plasmid by cloning the ase1 gene, which encodes a microtubule associated protein responsible for mitotic spindle assembly, into the pFA6a-kanMX6 cloning vector:\n",
"\n",
Expand All @@ -20,7 +20,7 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"<a target=\"_blank\" href=\"https://colab.research.google.com/github/BjornFJohansson/pydna/blob/dev_bjorn/docs/notebooks/Example_Gibson.ipynb\">\n",
"<a target=\"_blank\" href=\"https://colab.research.google.com/github/pydna-group/pydna/blob/master/docs/notebooks/Example_Gibson.ipynb\">\n",
" <img src=\"https://colab.research.google.com/assets/colab-badge.svg\" alt=\"Open In Colab\"/>\n",
"</a>"
]
Expand All @@ -31,14 +31,11 @@
"metadata": {},
"outputs": [],
"source": [
"%%capture\n",
"# Install pydna (only when running on Colab)\n",
"import sys\n",
"if 'google.colab' in sys.modules:\n",
" %%capture\n",
" # Install the current development version of pydna (comment to install pip version)\n",
" !pip install git+https://github.com/BjornFJohansson/pydna@dev_bjorn\n",
" # Install pip version instead (uncomment to install)\n",
" # !pip install pydna\n"
" %pip install pydna\n"
]
},
{
Expand Down
Loading

0 comments on commit ff5ba41

Please sign in to comment.