Damien Goutte-Gattat
0e801b94ea
Switch to Black-enforced code style.
3 weeks ago
Damien Goutte-Gattat
fa20c968af
Switch back to the original click-shell.
...
Development of click-shell has resumed, so we no longer have to rely on
our own fork.
1 year ago
Damien Goutte-Gattat
4b3cffa39c
Replace click_shell by incenp.click_shell.
1 year ago
Damien Goutte-Gattat
b9723dcd10
Prepare the 0.2.0 release.
1 year ago
Damien Goutte-Gattat
671486d80c
Add more documentation.
...
Start properly documenting the project in a Sphinx-based manual.
1 year ago
Damien Goutte-Gattat
df47a1ed6c
Allow seqtool to access user-configured databases.
...
Make seqtool use the default DatabaseProvider object, so that it can
fetch sequences from any database listed in databases.ini.
1 year ago
Damien Goutte-Gattat
b3d14b925f
Remove the seqvault.rc configuration file.
...
Make the seqvault program use the same configuration file as the
default DatabaseProvider object.
Also remove the possibility to specify server settings on the command
line. This effectively makes the presence of a configuration file
mandatory.
1 year ago
Damien Goutte-Gattat
5f5f96b6ad
Change option for database name in databases.ini.
...
In the configuration file for databases, change the name of the
option indicating the database name from `name' to `database', for
clarity.
1 year ago
Damien Goutte-Gattat
d18fa3ea7d
Change location of seqvault's configuration file.
...
Make seqvault look for a seqvault.rc file in the
$XDG_CONFIG_HOME/bioutils directory.
1 year ago
Damien Goutte-Gattat
73d28dc432
Add more documentation.
1 year ago
Damien Goutte-Gattat
3fab6608c0
Improve documentation of the USA module.
1 year ago
Damien Goutte-Gattat
ae88830522
Factorize test code.
1 year ago
Damien Goutte-Gattat
c9e45ce936
Remove unneeded import.
...
The usa module is no longer coupled to the databases module.
1 year ago
Damien Goutte-Gattat
efc07ed7ca
Remove query methods from the DatabaseProvider class.
...
With the new dict-like interface, that class is no longer supposed
to be used to query the databases directly. Client code should
instead get the database adapter from the dictionary and then use
the adapter to perfor any query.
1 year ago
Damien Goutte-Gattat
a82269f98c
Use a dict-like interface for the DatabaseProvider.
...
Make the DatabaseProvider object use a dict-like interface to check
if a database name exists and to get a database adapter. This allows
the USA code to accept a mere dictionary (with database names as keys
and database adapters as values) instead of a DatabaseProvider object.
Rename the `db_provider' argument to `databases' to reflect that
change.
1 year ago
Damien Goutte-Gattat
63a14f1d85
Do not use a global DatabaseProvider object.
...
Make the read_usa and parse_usa functions accept an optional
db_provider argument instead of relying on a module-level global
DatabaseProvider object.
1 year ago
Damien Goutte-Gattat
4230b44a1f
Fix creation of an unprefixed database.
...
A typo (missing closing parenthesis) prevented the creation of a
new subdatabase on a BioSQL server without support for prefixed
databases.
2 years ago
Damien Goutte-Gattat
d08bde1e5a
seqvault: Add support for SQLite databases.
...
Add the (unreleased by upstream) BioSQL schema for SQLite3. Fix
detection of the 'prefix' column.
2 years ago
Damien Goutte-Gattat
b64f943c77
seqvault: Fix creation of a new database.
...
Add a missing call to commit() to make sure the new database is
indeed created.
2 years ago
Damien Goutte-Gattat
3437bc4031
Add the expasy and entrez database sources.
...
Add adapters to allow fetching sequences from the NCBI servers and
from ExPASy.
2 years ago
Damien Goutte-Gattat
5b455632b9
Add read tests for database-based USAs.
...
Add a sample SQLite file (containing the same sequences as the
samples.gb file) and use it to test fetching sequences from a BioSQL
database.
2 years ago
Damien Goutte-Gattat
9e3e02afcd
Support SQLite-backed BioSQL databases.
...
Add support for sqlite3 driver for BioSQL databases. Unfortunately
this involves having to add an explicit 'ESCAPE' clause to all
queries as sqlite3 does not define any escape character by default.
2 years ago
Damien Goutte-Gattat
30da42775b
Use a single adapter for BioSQL-based databases.
...
Do not use one adapter for BioSQL subdatabases and another one for
BioSQL "entire" databases. Merge the two into a single adapter and
adjust the SQL queries when needed.
2 years ago
Damien Goutte-Gattat
5cfd8b0b6f
Support wildcards when querying a BioSQL database.
...
Implement support for '*' and '?' wildcards in database-backed USAs.
2 years ago
Damien Goutte-Gattat
f7735db4eb
Allow access to a specific subdatabase.
...
A BioSQL server contains subdatabases. This patch allows to define
a database source corresponding to a single subdatabase, while still
allowing to define a source corresponding to the entire server
(spanning all subdatabases).
2 years ago
Damien Goutte-Gattat
7bf4106794
Change the DatabaseProvider interface.
...
Do not use a single method for all kind of queries. Instead, use 3
distinct methods for fetching records based on a identifier, fetching
records based on a field query, and fetching all records.
2 years ago
Damien Goutte-Gattat
439255721c
Rough implementation of the database access layer.
...
Start implementing fetching records from database-backed USAs. Only
BioSQL-based databases are supported for now.
2 years ago
Damien Goutte-Gattat
c1a8553eef
Prepare 0.1.2 release.
2 years ago
Damien Goutte-Gattat
31b216528a
Fix Click interface for the blast tool.
...
Add the missing pass_context decorator to the definition of the
blast tool.
2 years ago
Damien Goutte-Gattat
4dd8428583
Fix link to the USA specification.
2 years ago
Damien Goutte-Gattat
e89320c0a2
Prepare 0.1.1 release.
...
Present the USA module in the README; bump version number and add the
NEWS file.
2 years ago
Damien Goutte-Gattat
f253447794
Compile search patterns in database-based USAs.
...
When creating a database-based USAs, compile the search pattern given
(if any). This will be used when fetching records from a database-based
USA is actually implemented.
2 years ago
Damien Goutte-Gattat
ae29033b6b
Only allow valid search fields.
...
When parsing a file-based or database-based USA, check that the search
field, if any, is one of the fields allowed by the USA specification.
2 years ago
Damien Goutte-Gattat
17d02a3f4d
Add tests for field-based searches.
...
Update sample files and add more test cases to test filtering based
on explicitly specified fields.
2 years ago
Damien Goutte-Gattat
d0f5ca6339
Implement per-field search in USAs.
...
When reading a file-based USA, allow to filter sequences based on
explicitly specified fields.
2 years ago
Damien Goutte-Gattat
c36e3f352b
Match identifier against unversioned accession number.
...
If a record’s accession number contains a version number, ignore it
when matching against an identifier.
2 years ago
Damien Goutte-Gattat
b43e77c717
Use both name and id when matching a record against an identifier.
...
The USA specification says that unless a ID or ACC field is
explicitly used, an identifier in a USA should match against any of the
two fields.
2 years ago
Damien Goutte-Gattat
660ea77f3c
Support wildcard ID lookups.
...
Add support for USAs with wildcard ID specifiers.
2 years ago
Damien Goutte-Gattat
f6b6f29392
Test reading from a program-based USA.
...
Add a sample GenBank file and a test case to check that we can fetch
sequences from a program-based USA.
2 years ago
Damien Goutte-Gattat
8a6448ad2f
Support reading from program-based USAs.
...
Implement fetching sequences from a ProgramUSA object.
2 years ago
Damien Goutte-Gattat
c849b899e4
Reuse first record's details when catenating sequences.
...
When catenating several sequences into one, default to copying the
details and annotations from the first sequence.
2 years ago
Damien Goutte-Gattat
f4656c4a56
Typo fix.
2 years ago
Damien Goutte-Gattat
0988964627
Prepare release 0.1.0.
...
Add more information in the README file.
2 years ago
Damien Goutte-Gattat
a87abf8e62
Add dependencies in setup.py.
...
Add Biopython as a required dependency, and reportlab as an optional
dependency. Do not require reportlab to launch the seqtool program.
2 years ago
Damien Goutte-Gattat
d26b0741c3
Fix invocation of the plasmm command.
...
The plasmm command expects an array of USA specs.
2 years ago
Damien Goutte-Gattat
c146e376f0
Autodetect format for file-based USAs.
...
When parsing a file-based USA, try to guess the format from the
extension if no explicit format is specified.
2 years ago
Damien Goutte-Gattat
de45b0c2ed
Fix distribution of BioSQL schemas.
...
The biosql folder was not included in the distribution.
2 years ago
Damien Goutte-Gattat
209f190b70
Add the newdb command.
...
Add a command to create a new biodatabase.
2 years ago
Damien Goutte-Gattat
b01e79ccdb
Fix incorrect use of is_prefixed().
...
One call to is_prefixed was still using the temporary name of
is_prefixed_biosql().
2 years ago
Damien Goutte-Gattat
fc3e146cad
Add prefix information in biodatabase table.
...
Modify the BioSQL schemas to add a `prefix' column to hold the default
accession prefix to be used when generating new accession numbers for
entries added to the database.
2 years ago