Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
mutalyzer
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Analyze
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Mirrors
mutalyzer
Commits
ef958a5a
Commit
ef958a5a
authored
9 years ago
by
Vermaat
Browse files
Options
Downloads
Patches
Plain Diff
Improve docstrings in transcript-protein link queries
parent
4d17063b
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
mutalyzer/db/queries.py
+10
-1
10 additions, 1 deletion
mutalyzer/db/queries.py
with
10 additions
and
1 deletion
mutalyzer/db/queries.py
+
10
−
1
View file @
ef958a5a
...
...
@@ -62,7 +62,8 @@ def get_transcript_protein_link(accession, reverse=False):
according to the configuration settings `PROTEIN_LINK_EXPIRATION` and
`NEGATIVE_PROTEIN_LINK_EXPIRATION`.
:arg str accession: Accession number to lookup link for.
:arg str accession: Accession number (without version number) to lookup
link for.
:arg bool reverse: If `True`, `accession` is assumed to be a protein
accession number, otherwise `accession` is assumed to be a transcript
accession number.
...
...
@@ -101,6 +102,14 @@ def update_transcript_protein_link(transcript_accession=None,
"""
Update cached link between a transcript and a protein, or create it if it
doesn
'
t exist yet.
:arg str transcript_accession: Transcript accession number (without
version number).
:arg str protein_accession: Protein accession number (without version
number).
At least one of `transcript_accession` or `protein_accession` must be not
`None`.
"""
if
transcript_accession
is
None
and
protein_accession
is
None
:
raise
ValueError
(
'
Link must have a transcript or protein
'
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment