From a3e728f9452e6cb83695587e553e97944af974d0 Mon Sep 17 00:00:00 2001 From: Scott Gigante Date: Mon, 2 Nov 2020 11:09:33 -0500 Subject: [PATCH] black -t py35 --- .travis.yml | 2 +- autoblack.sh | 2 +- python/magic/io.py | 14 +++++++------- python/magic/magic.py | 2 +- python/magic/preprocessing.py | 2 +- python/setup.py | 4 +++- 6 files changed, 14 insertions(+), 12 deletions(-) diff --git a/.travis.yml b/.travis.yml index 12145a88..cfba9b64 100644 --- a/.travis.yml +++ b/.travis.yml @@ -49,7 +49,7 @@ script: - cd Rmagic; R CMD build . - R CMD check *tar.gz - cd ../python; pip install --user -q .[test] - - if [ "$TRAVIS_PYTHON_VERSION" != "3.5" ]; then black . --check --diff; fi + - if [ "$TRAVIS_PYTHON_VERSION" != "3.5" ]; then black . --check --diff -t py35; fi - python setup.py test - pip install --user -q .[doc] - cd doc; make html; cd .. diff --git a/autoblack.sh b/autoblack.sh index cfbaf2b4..981a7b4f 100644 --- a/autoblack.sh +++ b/autoblack.sh @@ -6,7 +6,7 @@ set -e files=\$(git diff --staged --name-only --diff-filter=d -- "*.py") for file in \$files; do - black -q \$file + black -q -t py35 \$file git add \$file done EOF diff --git a/python/magic/io.py b/python/magic/io.py index dd23dd2d..aadbf6df 100644 --- a/python/magic/io.py +++ b/python/magic/io.py @@ -16,7 +16,7 @@ def load_csv( **kwargs ): """magic.io is deprecated. Please use scprep.io instead. - Read more at http://scprep.readthedocs.io/ + Read more at http://scprep.readthedocs.io/ """ raise RuntimeError( "magic.io is deprecated. Please use scprep.io instead. " @@ -35,7 +35,7 @@ def load_tsv( **kwargs ): """magic.io is deprecated. Please use scprep.io instead. - Read more at http://scprep.readthedocs.io/ + Read more at http://scprep.readthedocs.io/ """ raise RuntimeError( "magic.io is deprecated. Please use scprep.io instead. " @@ -60,7 +60,7 @@ def load_fcs( ], ): """magic.io is deprecated. Please use scprep.io instead. - Read more at http://scprep.readthedocs.io/ + Read more at http://scprep.readthedocs.io/ """ raise RuntimeError( "magic.io is deprecated. Please use scprep.io instead. " @@ -71,7 +71,7 @@ def load_fcs( def load_mtx(mtx_file, cell_axis="row", gene_names=None, cell_names=None, sparse=None): """magic.io is deprecated. Please use scprep.io instead. - Read more at http://scprep.readthedocs.io/ + Read more at http://scprep.readthedocs.io/ """ raise RuntimeError( "magic.io is deprecated. Please use scprep.io instead. " @@ -82,7 +82,7 @@ def load_mtx(mtx_file, cell_axis="row", gene_names=None, cell_names=None, sparse def load_10X(data_dir, sparse=True, gene_labels="symbol", allow_duplicates=None): """magic.io is deprecated. Please use scprep.io instead. - Read more at http://scprep.readthedocs.io/ + Read more at http://scprep.readthedocs.io/ """ raise RuntimeError( "magic.io is deprecated. Please use scprep.io instead. " @@ -93,7 +93,7 @@ def load_10X(data_dir, sparse=True, gene_labels="symbol", allow_duplicates=None) def load_10X_zip(filename, sparse=True, gene_labels="symbol", allow_duplicates=None): """magic.io is deprecated. Please use scprep.io instead. - Read more at http://scprep.readthedocs.io/ + Read more at http://scprep.readthedocs.io/ """ raise RuntimeError( "magic.io is deprecated. Please use scprep.io instead. " @@ -106,7 +106,7 @@ def load_10X_HDF5( filename, genome=None, sparse=True, gene_labels="symbol", allow_duplicates=None ): """magic.io is deprecated. Please use scprep.io instead. - Read more at http://scprep.readthedocs.io/ + Read more at http://scprep.readthedocs.io/ """ raise RuntimeError( "magic.io is deprecated. Please use scprep.io instead. " diff --git a/python/magic/magic.py b/python/magic/magic.py index 8f9d071a..65c02bcb 100644 --- a/python/magic/magic.py +++ b/python/magic/magic.py @@ -925,6 +925,6 @@ def knnDREMI( n_mesh=n_mesh, n_jobs=n_jobs, plot=plot, - **kwargs + **kwargs, ) return dremi diff --git a/python/magic/preprocessing.py b/python/magic/preprocessing.py index 6ce983c1..a16e87b0 100644 --- a/python/magic/preprocessing.py +++ b/python/magic/preprocessing.py @@ -8,7 +8,7 @@ def library_size_normalize(data, verbose=False): """magic.preprocessing is deprecated. Please use scprep.normalize instead. - Read more at http://scprep.readthedocs.io/ + Read more at http://scprep.readthedocs.io/ """ raise RuntimeError( "magic.preprocessing is deprecated. Please use scprep.normalize instead. " diff --git a/python/setup.py b/python/setup.py index 413fffee..9535e4a8 100644 --- a/python/setup.py +++ b/python/setup.py @@ -42,7 +42,9 @@ description="MAGIC", author="", author_email="", - packages=["magic",], + packages=[ + "magic", + ], license="GNU General Public License Version 2", install_requires=install_requires, extras_require={"test": test_requires, "doc": doc_requires},