Skip to content

Commit ea5dae6

Browse files
authored
Merge pull request #14 from scverse/feature/repr
Skeleton and basic IO
2 parents dda1165 + 2e8c647 commit ea5dae6

31 files changed

Lines changed: 1482 additions & 72 deletions

‎.flake8‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,10 @@ ignore =
3838
E203
3939
# format string does contain unindexed parameters
4040
P101
41+
# check if docstring conforms with RST
42+
RST
43+
# general docstrings check
44+
D
4145
exclude = .git,__pycache__,build,docs/_build,dist
4246
per-file-ignores =
4347
tests/*: D

‎.github/workflows/build.yaml‎

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
name: Check Build
2+
3+
on:
4+
push:
5+
branches: [main]
6+
pull_request:
7+
branches: [main]
8+
9+
jobs:
10+
package:
11+
runs-on: ubuntu-latest
12+
steps:
13+
- uses: actions/checkout@v2
14+
- name: Set up Python 3.10
15+
uses: actions/setup-python@v2
16+
with:
17+
python-version: "3.10"
18+
- name: Install build dependencies
19+
run: python -m pip install --upgrade pip wheel twine build
20+
- name: Build package
21+
run: python -m build
22+
- name: Check package
23+
run: twine check --strict dist/*.whl

‎.github/workflows/pre-commit.yaml‎

Lines changed: 0 additions & 14 deletions
This file was deleted.

‎.github/workflows/test.yaml‎

Lines changed: 1 addition & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
strategy:
1717
fail-fast: false
1818
matrix:
19-
python: ["3.8", "3.10"]
19+
python: ["3.9", "3.10"]
2020
os: [ubuntu-latest]
2121

2222
env:
@@ -60,18 +60,3 @@ jobs:
6060
CODECOV_NAME: ${{ matrix.python }}-${{ matrix.os }}
6161
run: |
6262
codecov --required --flags=unittests
63-
64-
package:
65-
runs-on: ubuntu-latest
66-
steps:
67-
- uses: actions/checkout@v2
68-
- name: Set up Python 3.10
69-
uses: actions/setup-python@v2
70-
with:
71-
python-version: "3.10"
72-
- name: Install test dependencies
73-
run: python -m pip install --upgrade pip wheel twine build
74-
- name: Build package
75-
run: python -m build
76-
- name: Check package
77-
run: twine check --strict dist/*.whl

‎.gitignore‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,3 +22,6 @@ __pycache__/
2222
# IDEs
2323
/.idea/
2424
.vscode
25+
26+
# data
27+
spatialdata-sandbox

‎.pre-commit-config.yaml‎

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,6 @@ default_stages:
66
- push
77
minimum_pre_commit_version: 2.16.0
88
repos:
9-
- repo: https://github.com/pre-commit/mirrors-mypy
10-
rev: v0.971
11-
hooks:
12-
- id: mypy
13-
additional_dependencies:
14-
[numpy==1.22.0, scipy, pandas, types-requests]
15-
exclude: tests/|docs/
169
- repo: https://github.com/psf/black
1710
rev: 22.6.0
1811
hooks:
@@ -29,8 +22,14 @@ repos:
2922
rev: 5.10.1
3023
hooks:
3124
- id: isort
25+
- repo: https://github.com/pre-commit/mirrors-mypy
26+
rev: v0.971
27+
hooks:
28+
- id: mypy
29+
additional_dependencies: [numpy==1.22.0, types-requests]
30+
exclude: tests/|docs/|temp/|spatialdata/_core/reader.py
3231
- repo: https://github.com/asottile/yesqa
33-
rev: v1.3.0
32+
rev: v1.4.0
3433
hooks:
3534
- id: yesqa
3635
additional_dependencies:
@@ -60,7 +59,7 @@ repos:
6059
- --remove-unused-variable
6160
- --ignore-init-module-imports
6261
- repo: https://github.com/PyCQA/flake8
63-
rev: 5.0.1
62+
rev: 5.0.4
6463
hooks:
6564
- id: flake8
6665
additional_dependencies:

‎README.md‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
[![Tests][badge-tests]][link-tests]
44
[![Documentation][badge-docs]][link-docs]
5+
[![pre-commit.ci status](https://results.pre-commit.ci/badge/github/scverse/spatialdata/main.svg)](https://results.pre-commit.ci/latest/github/scverse/spatialdata/main)
56

67
[badge-tests]: https://img.shields.io/github/workflow/status/scverse/spatialdata/Test/main
78
[link-tests]: https://github.com/scverse/spatialdata.git/actions/workflows/test.yml

‎pyproject.toml‎

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ version = "0.0.1.dev0"
2222
requires-python = ">=3.8"
2323
license = {file = "LICENSE"}
2424
readme = "README.md"
25-
dependencies = ["anndata"]
25+
dependencies = ["anndata","numpy","xarray","zarr","ome_zarr"]
2626

2727
[project.optional-dependencies]
2828
dev = [
@@ -54,11 +54,12 @@ omit = [
5454
testpaths = ["tests"]
5555
xfail_strict = true
5656
addopts = [
57-
"-Werror", # if 3rd party libs raise DeprecationWarnings, just use filterwarnings below
57+
# "-Werror", # if 3rd party libs raise DeprecationWarnings, just use filterwarnings below
5858
"--import-mode=importlib", # allow using test files with same name
5959
]
60+
# info on how to use this https://stackoverflow.com/questions/57925071/how-do-i-avoid-getting-deprecationwarning-from-inside-dependencies-with-pytest
6061
filterwarnings = [
61-
# "ignore:.*U.*mode is deprecated:DeprecationWarning",
62+
# "ignore:.*U.*mode is deprecated:DeprecationWarning",
6263
]
6364

6465
[tool.isort]

‎spatialdata/__init__.py‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,5 @@
22

33
__version__ = version("spatialdata")
44

5-
from ._core import SpatialData
5+
from spatialdata._core.spatialdata import SpatialData
6+
from spatialdata._core.transform import Transform

‎spatialdata/_constants/__init__.py‎

Whitespace-only changes.

0 commit comments

Comments
 (0)