opencloning 0.2.7__tar.gz → 0.2.7.2__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {opencloning-0.2.7 → opencloning-0.2.7.2}/PKG-INFO +1 -1
- {opencloning-0.2.7 → opencloning-0.2.7.2}/pyproject.toml +1 -1
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/endpoints/primer_design.py +5 -5
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/primer_design.py +35 -3
- {opencloning-0.2.7 → opencloning-0.2.7.2}/LICENSE +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/README.md +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/__init__.py +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/api_config_utils.py +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/app_settings.py +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/assembly2.py +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/batch_cloning/EBIC/__init__.py +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/batch_cloning/EBIC/barcode.gb +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/batch_cloning/EBIC/common_plasmid.gb +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/batch_cloning/EBIC/example.py +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/batch_cloning/EBIC/primer_design_settings.py +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/batch_cloning/__init__.py +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/batch_cloning/index.html +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/batch_cloning/pombe/__init__.py +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/batch_cloning/pombe/index.html +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/batch_cloning/pombe/pombe_all.sh +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/batch_cloning/pombe/pombe_clone.py +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/batch_cloning/pombe/pombe_gather.py +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/batch_cloning/pombe/pombe_get_primers.py +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/batch_cloning/pombe/pombe_summary.py +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/batch_cloning/ziqiang_et_al2024/__init__.py +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/batch_cloning/ziqiang_et_al2024/index.html +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/batch_cloning/ziqiang_et_al2024/ziqiang_et_al2024.json +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/dna_functions.py +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/dna_utils.py +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/ebic/__init__.py +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/ebic/primer_design.py +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/ebic/primer_design_settings.py +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/endpoints/annotation.py +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/endpoints/assembly.py +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/endpoints/external_import.py +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/endpoints/no_assembly.py +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/endpoints/no_input.py +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/endpoints/other.py +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/gateway.py +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/get_router.py +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/main.py +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/ncbi_requests.py +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/pydantic_models.py +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/request_examples.py +0 -0
- {opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/utils.py +0 -0
|
@@ -3,7 +3,7 @@ authors = ["Manuel Lera-Ramirez <manulera14@gmail.com>"]
|
|
|
3
3
|
description = "Backend of OpenCloning, a web application to generate molecular cloning strategies in json format, and share them with others."
|
|
4
4
|
license = "MIT"
|
|
5
5
|
name = "opencloning"
|
|
6
|
-
version = "v0.2.7"
|
|
6
|
+
version = "v0.2.7.2"
|
|
7
7
|
package-mode = true
|
|
8
8
|
readme = "README.md"
|
|
9
9
|
repository = "https://github.com/manulera/OpenCloning_backend"
|
|
@@ -209,8 +209,8 @@ async def primer_design_ebic(
|
|
|
209
209
|
# @router.post('/primer_design/gateway_attB', response_model=PrimerDesignResponse)
|
|
210
210
|
# async def primer_design_gateway_attB(
|
|
211
211
|
# template: PrimerDesignQuery,
|
|
212
|
-
# left_site: str = Query(..., description='The left attB site to recombine.',
|
|
213
|
-
# right_site: str = Query(..., description='The right attB site to recombine.',
|
|
212
|
+
# left_site: str = Query(..., description='The left attB site to recombine.', pattern=r'^attB[1-5]$'),
|
|
213
|
+
# right_site: str = Query(..., description='The right attB site to recombine.', pattern=r'^attB[1-5]$'),
|
|
214
214
|
# spacers: list[str] | None = Body(None, description='Spacers to add between the attB site and the primer.'),
|
|
215
215
|
# filler_bases: str = Query(
|
|
216
216
|
# 'GGGG',
|
|
@@ -276,7 +276,7 @@ class PrimerDetailsResponse(BaseModel):
|
|
|
276
276
|
|
|
277
277
|
@router.get('/primer_details', response_model=PrimerDetailsResponse)
|
|
278
278
|
async def primer_details(
|
|
279
|
-
sequence: str = Query(..., description='Primer sequence',
|
|
279
|
+
sequence: str = Query(..., description='Primer sequence', pattern=r'^[ACGTacgt]+$'),
|
|
280
280
|
):
|
|
281
281
|
"""Get information about a primer"""
|
|
282
282
|
sequence = sequence.upper()
|
|
@@ -299,8 +299,8 @@ async def primer_details(
|
|
|
299
299
|
|
|
300
300
|
@router.get('/primer_heterodimer', response_model=ThermodynamicResult | None)
|
|
301
301
|
async def primer_heterodimer(
|
|
302
|
-
sequence1: str = Query(..., description='First primer sequence',
|
|
303
|
-
sequence2: str = Query(..., description='Second primer sequence',
|
|
302
|
+
sequence1: str = Query(..., description='First primer sequence', pattern=r'^[ACGTacgt]+$'),
|
|
303
|
+
sequence2: str = Query(..., description='Second primer sequence', pattern=r'^[ACGTacgt]+$'),
|
|
304
304
|
):
|
|
305
305
|
"""Get information about a primer pair"""
|
|
306
306
|
|
|
@@ -7,6 +7,13 @@ from .pydantic_models import PrimerModel
|
|
|
7
7
|
from Bio.Seq import reverse_complement
|
|
8
8
|
from Bio.Restriction.Restriction import RestrictionType
|
|
9
9
|
from Bio.Data.IUPACData import ambiguous_dna_values as _ambiguous_dna_values
|
|
10
|
+
from primer3.bindings import calc_tm as _calc_tm
|
|
11
|
+
from typing import Callable
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
def primer3_calc_tm(seq: str) -> float:
|
|
15
|
+
return _calc_tm(seq.upper())
|
|
16
|
+
|
|
10
17
|
|
|
11
18
|
ambiguous_dna_values = _ambiguous_dna_values.copy()
|
|
12
19
|
# Remove acgt
|
|
@@ -24,10 +31,18 @@ def homologous_recombination_primers(
|
|
|
24
31
|
insert_forward: bool,
|
|
25
32
|
target_tm: float,
|
|
26
33
|
spacers: list[str] | None = None,
|
|
34
|
+
tm_func: Callable[[str], float] = primer3_calc_tm,
|
|
35
|
+
estimate_function: Callable[[str], float] | None = None,
|
|
27
36
|
) -> tuple[str, str]:
|
|
28
37
|
|
|
29
38
|
fragment2amplify = pcr_loc.extract(pcr_seq)
|
|
30
|
-
amplicon = primer_design(
|
|
39
|
+
amplicon = primer_design(
|
|
40
|
+
fragment2amplify,
|
|
41
|
+
limit=minimal_hybridization_length,
|
|
42
|
+
target_tm=target_tm,
|
|
43
|
+
tm_func=tm_func,
|
|
44
|
+
estimate_function=estimate_function,
|
|
45
|
+
)
|
|
31
46
|
|
|
32
47
|
if insert_forward:
|
|
33
48
|
fwd_primer, rvs_primer = amplicon.primers()
|
|
@@ -76,10 +91,19 @@ def gibson_assembly_primers(
|
|
|
76
91
|
target_tm: float,
|
|
77
92
|
circular: bool,
|
|
78
93
|
spacers: list[str] | None = None,
|
|
94
|
+
tm_func: Callable[[str], float] = primer3_calc_tm,
|
|
95
|
+
estimate_function: Callable[[str], float] | None = None,
|
|
79
96
|
) -> list[PrimerModel]:
|
|
80
97
|
|
|
81
98
|
initial_amplicons = [
|
|
82
|
-
primer_design(
|
|
99
|
+
primer_design(
|
|
100
|
+
template,
|
|
101
|
+
limit=minimal_hybridization_length,
|
|
102
|
+
target_tm=target_tm,
|
|
103
|
+
tm_func=tm_func,
|
|
104
|
+
estimate_function=estimate_function,
|
|
105
|
+
)
|
|
106
|
+
for template in templates
|
|
83
107
|
]
|
|
84
108
|
|
|
85
109
|
for i, amplicon in enumerate(initial_amplicons):
|
|
@@ -133,6 +157,8 @@ def simple_pair_primers(
|
|
|
133
157
|
spacers: list[str] | None = None,
|
|
134
158
|
left_enzyme_inverted: bool = False,
|
|
135
159
|
right_enzyme_inverted: bool = False,
|
|
160
|
+
tm_func: Callable[[str], float] = primer3_calc_tm,
|
|
161
|
+
estimate_function: Callable[[str], float] | None = None,
|
|
136
162
|
) -> tuple[PrimerModel, PrimerModel]:
|
|
137
163
|
"""
|
|
138
164
|
Design primers to amplify a DNA fragment, if left_enzyme or right_enzyme are set, the primers will be designed
|
|
@@ -145,7 +171,13 @@ def simple_pair_primers(
|
|
|
145
171
|
if len(spacers) != 2:
|
|
146
172
|
raise ValueError("The 'spacers' list must contain exactly two elements.")
|
|
147
173
|
|
|
148
|
-
amplicon = primer_design(
|
|
174
|
+
amplicon = primer_design(
|
|
175
|
+
template,
|
|
176
|
+
limit=minimal_hybridization_length,
|
|
177
|
+
target_tm=target_tm,
|
|
178
|
+
tm_func=tm_func,
|
|
179
|
+
estimate_function=estimate_function,
|
|
180
|
+
)
|
|
149
181
|
fwd_primer, rvs_primer = amplicon.primers()
|
|
150
182
|
|
|
151
183
|
if fwd_primer is None or rvs_primer is None:
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/batch_cloning/EBIC/common_plasmid.gb
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/batch_cloning/pombe/pombe_clone.py
RENAMED
|
File without changes
|
{opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/batch_cloning/pombe/pombe_gather.py
RENAMED
|
File without changes
|
{opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/batch_cloning/pombe/pombe_get_primers.py
RENAMED
|
File without changes
|
{opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/batch_cloning/pombe/pombe_summary.py
RENAMED
|
File without changes
|
|
File without changes
|
{opencloning-0.2.7 → opencloning-0.2.7.2}/src/opencloning/batch_cloning/ziqiang_et_al2024/index.html
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|