mirror of
https://github.com/Novartis/cellxgene-gateway.git
synced 2026-09-15 12:47:59 +08:00
#87 remove version pins for markupsafe, flask and werkzeug
also remove dependency on flask-api
This commit is contained in:
1
.github/workflows/pr-checks.yaml
vendored
1
.github/workflows/pr-checks.yaml
vendored
@@ -39,7 +39,6 @@ jobs:
|
|||||||
conda env create -f environment.yml
|
conda env create -f environment.yml
|
||||||
eval "$(conda shell.bash hook)"
|
eval "$(conda shell.bash hook)"
|
||||||
conda activate cellxgene-gateway
|
conda activate cellxgene-gateway
|
||||||
pip install markupsafe==2.0.1 # temporary workaround for jinja2-2.11.3 calling soft_unicode in markupsafe
|
|
||||||
python setup.py install
|
python setup.py install
|
||||||
|
|
||||||
- name: Run tests
|
- name: Run tests
|
||||||
|
|||||||
@@ -1,3 +1,8 @@
|
|||||||
|
# UNRELEASED
|
||||||
|
|
||||||
|
* Removed dependency on flask-api enabling update of werkzeug
|
||||||
|
* Updated dependencies (python 3.11, numpy 1.26, unpinned flask, werkzeug)
|
||||||
|
|
||||||
# 0.3.12
|
# 0.3.12
|
||||||
|
|
||||||
* #81 List gene set annotations when cell annotations not present
|
* #81 List gene set annotations when cell annotations not present
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
FROM python:3.9
|
FROM python:3.11
|
||||||
|
|
||||||
RUN pip install --upgrade pip \
|
RUN pip install --upgrade pip
|
||||||
&& pip install cellxgene-gateway 'MarkupSafe<2.1'
|
RUN pip install "cellxgene-gateway>=0.4"
|
||||||
|
|
||||||
ENV CELLXGENE_DATA=/cellxgene-data
|
ENV CELLXGENE_DATA=/cellxgene-data
|
||||||
ENV CELLXGENE_LOCATION=/usr/local/bin/cellxgene
|
ENV CELLXGENE_LOCATION=/usr/local/bin/cellxgene
|
||||||
|
|||||||
31
README.md
31
README.md
@@ -110,7 +110,7 @@ Additional environment variables can be provided with the `-e` parameter:
|
|||||||
|
|
||||||
```bash
|
```bash
|
||||||
docker run -it --rm \
|
docker run -it --rm \
|
||||||
-v <local_data_dir>:/cellxgene-data \
|
-v ../cellxgene_data:/cellxgene-data \
|
||||||
-e GATEWAY_PORT=8080 \
|
-e GATEWAY_PORT=8080 \
|
||||||
-p 8080:8080 \
|
-p 8080:8080 \
|
||||||
cellxgene-gateway
|
cellxgene-gateway
|
||||||
@@ -191,6 +191,35 @@ black .
|
|||||||
|
|
||||||
If you need help for any reason, please make a github ticket. One of the contributors should help you out.
|
If you need help for any reason, please make a github ticket. One of the contributors should help you out.
|
||||||
|
|
||||||
|
# Releasing New Versions
|
||||||
|
|
||||||
|
## How to prepare for release
|
||||||
|
|
||||||
|
- Update Changelog.md and version number in __init__.py
|
||||||
|
- Cut a release on github
|
||||||
|
- Go to your project homepage on GitHub
|
||||||
|
- On right side, you will see [Releases](https://github.com/Novartis/cellxgene-gateway/releases) link. Click on it.
|
||||||
|
- Click on Draft a new release
|
||||||
|
- Fill in all the details
|
||||||
|
- Tag version should be the version number of your package release
|
||||||
|
- Release Title can be anything you want, but we use v0.3.11 (the same as the tag to be created on publish)
|
||||||
|
- Description should be changelog
|
||||||
|
- Click Publish release at the bottom of the page
|
||||||
|
- Now under Releases you can view all of your releases.
|
||||||
|
- Copy the download link (tar.gz) and save it somewhere
|
||||||
|
|
||||||
|
## How to publish to PyPI
|
||||||
|
|
||||||
|
Make sure your `.pypirc` is set up for testpypi and pypi index servers.
|
||||||
|
|
||||||
|
|
||||||
|
```bash
|
||||||
|
rm -rf dist
|
||||||
|
python setup.py sdist bdist_wheel
|
||||||
|
python -m twine upload --repository testpypi dist/*
|
||||||
|
python -m twine upload dist/*
|
||||||
|
```
|
||||||
|
|
||||||
# Contributors
|
# Contributors
|
||||||
|
|
||||||
* Niket Patel - https://github.com/NiketPatel9
|
* Niket Patel - https://github.com/NiketPatel9
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ import time
|
|||||||
from threading import Thread
|
from threading import Thread
|
||||||
from typing import List
|
from typing import List
|
||||||
|
|
||||||
from flask_api import status
|
from http import HTTPStatus
|
||||||
|
|
||||||
from cellxgene_gateway import env
|
from cellxgene_gateway import env
|
||||||
from cellxgene_gateway.cache_entry import CacheEntry, CacheEntryStatus
|
from cellxgene_gateway.cache_entry import CacheEntry, CacheEntryStatus
|
||||||
@@ -53,7 +53,7 @@ class BackendCache:
|
|||||||
return matches[0]
|
return matches[0]
|
||||||
else:
|
else:
|
||||||
raise CellxgeneException(
|
raise CellxgeneException(
|
||||||
status.HTTP_500_INTERNAL_SERVER_ERROR,
|
HTTPStatus.INTERNAL_SERVER_ERROR,
|
||||||
"Found " + str(len(matches)) + " for " + path,
|
"Found " + str(len(matches)) + " for " + path,
|
||||||
)
|
)
|
||||||
|
|
||||||
@@ -71,7 +71,7 @@ class BackendCache:
|
|||||||
return matches[0]
|
return matches[0]
|
||||||
else:
|
else:
|
||||||
raise CellxgeneException(
|
raise CellxgeneException(
|
||||||
status.HTTP_500_INTERNAL_SERVER_ERROR,
|
HTTPStatus.INTERNAL_SERVER_ERROR,
|
||||||
"Found " + str(len(matches)) + " for " + key.dataset,
|
"Found " + str(len(matches)) + " for " + key.dataset,
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|||||||
@@ -9,8 +9,6 @@
|
|||||||
|
|
||||||
import os
|
import os
|
||||||
|
|
||||||
from flask_api import status
|
|
||||||
|
|
||||||
from cellxgene_gateway import env
|
from cellxgene_gateway import env
|
||||||
from cellxgene_gateway.cellxgene_exception import CellxgeneException
|
from cellxgene_gateway.cellxgene_exception import CellxgeneException
|
||||||
|
|
||||||
|
|||||||
@@ -10,7 +10,7 @@
|
|||||||
import logging
|
import logging
|
||||||
import subprocess
|
import subprocess
|
||||||
|
|
||||||
from flask_api import status
|
from http import HTTPStatus
|
||||||
|
|
||||||
from cellxgene_gateway.cache_entry import CacheEntryStatus
|
from cellxgene_gateway.cache_entry import CacheEntryStatus
|
||||||
from cellxgene_gateway.dir_util import make_annotations
|
from cellxgene_gateway.dir_util import make_annotations
|
||||||
@@ -76,10 +76,10 @@ class SubprocessBackend:
|
|||||||
or "Could not open file" in stderr
|
or "Could not open file" in stderr
|
||||||
):
|
):
|
||||||
message = "File was invalid."
|
message = "File was invalid."
|
||||||
http_status = status.HTTP_400_BAD_REQUEST
|
http_status = HTTPStatus.BAD_REQUEST
|
||||||
else:
|
else:
|
||||||
message = "Cellxgene failed to launch dataset."
|
message = "Cellxgene failed to launch dataset."
|
||||||
http_status = status.HTTP_500_INTERNAL_SERVER_ERROR
|
http_status = HTTPStatus.INTERNAL_SERVER_ERROR
|
||||||
|
|
||||||
cache_entry.status = CacheEntryStatus.error
|
cache_entry.status = CacheEntryStatus.error
|
||||||
cache_entry.set_error(message, stderr, http_status)
|
cache_entry.set_error(message, stderr, http_status)
|
||||||
|
|||||||
@@ -2,9 +2,9 @@ name: cellxgene-gateway
|
|||||||
channels:
|
channels:
|
||||||
- conda-forge
|
- conda-forge
|
||||||
dependencies:
|
dependencies:
|
||||||
- python=3.9
|
- python=3.11
|
||||||
- requests
|
- requests
|
||||||
- flask==2.2.5
|
- flask
|
||||||
- psutil
|
- psutil
|
||||||
- black
|
- black
|
||||||
- twine
|
- twine
|
||||||
@@ -13,6 +13,5 @@ dependencies:
|
|||||||
- pip
|
- pip
|
||||||
- pip:
|
- pip:
|
||||||
- pre_commit
|
- pre_commit
|
||||||
- flask-api
|
- werkzeug
|
||||||
- werkzeug==2.3.8
|
|
||||||
- cellxgene
|
- cellxgene
|
||||||
|
|||||||
@@ -1,6 +1,5 @@
|
|||||||
cellxgene
|
cellxgene
|
||||||
flask==2.2.5
|
flask
|
||||||
flask-api
|
werkzeug
|
||||||
werkzeug==2.3.8
|
|
||||||
psutil
|
psutil
|
||||||
requests
|
requests
|
||||||
|
|||||||
Reference in New Issue
Block a user