Skip to main content

Keep track of genes, transcripts and exons from different sources

Project description

Schug

Schug :stew: is a service that gather data about genes, transcripts and exons from multiple sources and merge the information. There is a REST API with relevant endpoints.

Test the app using Docker

You can test Schug on your local computer using Docker. Make sure you have Docker installed and type the following commands in a terminal window:

git clone https://github.com/Clinical-Genomics/schug
cd schug
docker-compose up

Then the app endpoints should be listed available at the following address http://localhost:8000/docs

The command to stop the demo is docker-compose down.

Installation (development)

Make sure poetry is installed

git clone https://github.com/Clinical-Genomics/schug
cd schug
poetry install
schug serve --reload

Go to http://localhost:8000/docs and check out the API.

Ready-to-use endpoints

Once having set up an instance of Schug, you can use the following endpoints:

  • /genes/ensembl_genes/

    Downloads genes from Ensembl in text format. Specify a genome build by using the parameters 37 or 38.

    Usage: curl -X 'GET' 'http://0.0.0.0:8000/genes/ensembl_genes/?build=38' > genes_GRCh38.txt

  • /transcripts/ensembl_transcripts/

    Downloads gene transcripts from Ensembl in text format. Specify a genome build by using the parameters 37 or 38.

    Usage: curl -X 'GET' 'http://0.0.0.0:8000/transcripts/ensembl_transcripts/?build=38' > transcripts_GRCh38.txt

  • /exons/ensembl_exons/

    Downloads gene exons from Ensembl in text format. Specify a genome build by using the parameters 37 or 38.

    Usage: curl -X 'GET' 'http://0.0.0.0:8000/exons/ensembl_exons/?build=38' > exons_GRCh38.txt

Issues While Downloading Genes, Transcripts, or Exons

You might encounter errors while downloading genes, transcripts, or exons, such as the following error:

httpx.RemoteProtocolError: peer closed connection without sending complete message body (incomplete chunked read)

This error often occurs when the external service prematurely closes the connection during data streaming. To address this issue, you can try increasing the max_tries parameter in your request, which otherwise defaults to 5. Increasing the number of retries can help handle intermittent network issues or temporary interruptions from the service.

Here’s an example of how to modify the request:

curl -X 'GET' 'http://0.0.0.0:8000/exons/ensembl_exons/?build=37&max_retries=10' > exons_GRCh37.txt`

What is left to do?

The basic structure is outlined and implemented, however there are many details left to implement before this can be used. Some of the basic endpoints are in place but these need to be extended according to the needs of the users. Also the gene information needs to be completed, this will be done in a similar fashion as in Scout.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

schug-1.11.0.tar.gz (19.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

schug-1.11.0-py3-none-any.whl (29.0 kB view details)

Uploaded Python 3

File details

Details for the file schug-1.11.0.tar.gz.

File metadata

  • Download URL: schug-1.11.0.tar.gz
  • Upload date:
  • Size: 19.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.1.1 CPython/3.11.11 Linux/6.8.0-1021-azure

File hashes

Hashes for schug-1.11.0.tar.gz
Algorithm Hash digest
SHA256 ed83fbce9393974000eb65b2ac994db2f7e3a55b2842f1966ec576890c6b5318
MD5 fdb735e1340d532a7854840863adec91
BLAKE2b-256 3f9f1e50b7b9c486ce4871fa9ad5f4801cdbe542cd8892dbe5d30fb5d4bdaecc

See more details on using hashes here.

File details

Details for the file schug-1.11.0-py3-none-any.whl.

File metadata

  • Download URL: schug-1.11.0-py3-none-any.whl
  • Upload date:
  • Size: 29.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.1.1 CPython/3.11.11 Linux/6.8.0-1021-azure

File hashes

Hashes for schug-1.11.0-py3-none-any.whl
Algorithm Hash digest
SHA256 6d3e5962e4c042ef39ae48532cae6eb7c5c0b198d2772709510713212b9f943c
MD5 d94fb85e1ae6c8214dd9a324bee139a3
BLAKE2b-256 2f9ca5ba227ddba8805ca366339138e75a55e1305b0af1becb50b7b7a204c31c

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page