mirror of
https://github.com/chanzuckerberg/cellxgene.git
synced 2026-09-27 04:58:12 +08:00
Fix a few bugs from server refactor (#1188)
- Fixes #1185 port command line argument was not handle correctly - Fixes #1184 was not catching the "DatasetAccessError" exception.
This commit is contained in:
@@ -12,6 +12,7 @@ import click
|
||||
|
||||
from server.common.utils import custom_format_warning
|
||||
from server.common.utils import find_available_port, is_port_available, sort_options
|
||||
from server.common.errors import DatasetAccessError
|
||||
from server.data_common.matrix_loader import MatrixDataLoader, MatrixDataCacheManager
|
||||
from server.common.annotations import AnnotationsLocalFile
|
||||
from server.common.app_config import AppConfig
|
||||
@@ -167,7 +168,7 @@ def server_args(func):
|
||||
"--port",
|
||||
"-p",
|
||||
metavar="<port>",
|
||||
default=DEFAULT_SERVER_PORT,
|
||||
default=None,
|
||||
show_default=True,
|
||||
help="Port to run server on. If not specified cellxgene will find an available port.",
|
||||
)
|
||||
@@ -313,7 +314,7 @@ def launch(
|
||||
|
||||
try:
|
||||
matrix_data_loader.pre_load_validation()
|
||||
except RuntimeError as e:
|
||||
except DatasetAccessError as e:
|
||||
raise click.ClickException(str(e))
|
||||
|
||||
file_size = matrix_data_loader.file_size()
|
||||
|
||||
Reference in New Issue
Block a user