From ea8a62dbd68b2b990f3aedb34886c6ecc19c8c33 Mon Sep 17 00:00:00 2001 From: Gregor Sturm Date: Mon, 23 May 2022 19:37:11 +0200 Subject: [PATCH 1/4] Add issue templates --- .../.github/ISSUE_TEMPLATE/bug_report.yml | 71 +++++++++++++++++++ .../.github/ISSUE_TEMPLATE/config.yml | 5 ++ .../ISSUE_TEMPLATE/feature_request.yml | 11 +++ 3 files changed, 87 insertions(+) create mode 100644 {{cookiecutter.project_name}}/.github/ISSUE_TEMPLATE/bug_report.yml create mode 100644 {{cookiecutter.project_name}}/.github/ISSUE_TEMPLATE/config.yml create mode 100644 {{cookiecutter.project_name}}/.github/ISSUE_TEMPLATE/feature_request.yml diff --git a/{{cookiecutter.project_name}}/.github/ISSUE_TEMPLATE/bug_report.yml b/{{cookiecutter.project_name}}/.github/ISSUE_TEMPLATE/bug_report.yml new file mode 100644 index 00000000..2ac2f0f1 --- /dev/null +++ b/{{cookiecutter.project_name}}/.github/ISSUE_TEMPLATE/bug_report.yml @@ -0,0 +1,71 @@ +name: Bug report +description: Report something that is broken or incorrect +labels: bug +body: + - type: markdown + attributes: + value: | + **Note**: Please read [this guide](https://matthewrocklin.com/blog/work/2018/02/28/minimal-bug-reports) + detailing how to provide the necessary information for us to reproduce your bug. In brief: + * Please provide exact steps how to reproduce the bug in a clean Python environment. + * In case it's not clear what's causing this bug, please provide the data or the data generation procecure. + * Sometimes it is not possible to share the data but usually it is possible to replicate problems on publicly + available datasets or to share a subset of your data. + + - type: textarea + id: description + attributes: + label: Description of the bug + description: A clear and concise description of what the bug is. + validations: + required: true + + - type: textarea + id: repex + attributes: + label: Minimal reproducible example + description: A code snipped that we can copy&paste to reproduce the bug without having any data + render: python + placeholder: | + import scanpy as sc + adata = sc.datasets.pbmc3k() + + sc.do_something_that_doesnt_work(adata) + + - type: textarea + id: stacktrace + attributes: + label: The error message produced by the code above + description: Please paste the entire error message + render: pytb + placeholder: | + --------------------------------------------------------------------------- + AssertionError Traceback (most recent call last) + in + ----> 1 adata = sc.do_something_that_doesnt_work(adata) + + /opt/conda/lib/python3.8/site-packages/scanpy/_preprocessing.py in do_something_that_doesnt_work(adata) + 438 + --> 439 raise AssertionError("Demo function that fails") + 440 + + - type: textarea + id: versions + attributes: + label: Version information + description: | + Please provide use with some details about your system: + + * Version of {{ cookiecutter.package_name }} (`{{ cookiecutter.package_name }}.__version__`) + * Version of numpy (`numpy.__version__`) + * Version of pandas (`pandas.__version__`) + * Version of AnnData (`anndata.__version__`) + * Python version (*e.g. 3.7, 3.8*) + * OS (*e.g. Arch Linux, Windows 10, MacOS*) + placeholder: | + {{ cookiecutter.package_name }}: 0.7.0 + numpy: 1.22.3 + pandas: 1.4.2 + AnnData: 0.7.6 + Python: 3.7 + OS: Arch Linux diff --git a/{{cookiecutter.project_name}}/.github/ISSUE_TEMPLATE/config.yml b/{{cookiecutter.project_name}}/.github/ISSUE_TEMPLATE/config.yml new file mode 100644 index 00000000..5cad625d --- /dev/null +++ b/{{cookiecutter.project_name}}/.github/ISSUE_TEMPLATE/config.yml @@ -0,0 +1,5 @@ +blank_issues_enabled: false +contact_links: + - name: Scverse Community Forum + url: https://discourse.scverse.org/ + about: If you have questions about “How to do X”, please ask them here. diff --git a/{{cookiecutter.project_name}}/.github/ISSUE_TEMPLATE/feature_request.yml b/{{cookiecutter.project_name}}/.github/ISSUE_TEMPLATE/feature_request.yml new file mode 100644 index 00000000..816c4abf --- /dev/null +++ b/{{cookiecutter.project_name}}/.github/ISSUE_TEMPLATE/feature_request.yml @@ -0,0 +1,11 @@ +name: Feature request +description: Propose a new feature for {{ cookiecutter.project_name }} +labels: enhancement +body: + - type: textarea + id: description + attributes: + label: Description of feature + description: Please describe your suggestion for a new feature. It might help to describe a problem or use case, plus any alternatives that you have considered. + validations: + required: true From e5b0bf0d66435835b504cf5dbce38d45531be460 Mon Sep 17 00:00:00 2001 From: Gregor Sturm Date: Thu, 7 Jul 2022 17:56:48 +0200 Subject: [PATCH 2/4] Session info dependency --- .../.github/ISSUE_TEMPLATE/bug_report.yml | 73 +++++++++++++++---- {{cookiecutter.project_name}}/pyproject.toml | 6 +- 2 files changed, 65 insertions(+), 14 deletions(-) diff --git a/{{cookiecutter.project_name}}/.github/ISSUE_TEMPLATE/bug_report.yml b/{{cookiecutter.project_name}}/.github/ISSUE_TEMPLATE/bug_report.yml index 2ac2f0f1..85e8b175 100644 --- a/{{cookiecutter.project_name}}/.github/ISSUE_TEMPLATE/bug_report.yml +++ b/{{cookiecutter.project_name}}/.github/ISSUE_TEMPLATE/bug_report.yml @@ -54,18 +54,65 @@ body: attributes: label: Version information description: | - Please provide use with some details about your system: + Please paste below the output of - * Version of {{ cookiecutter.package_name }} (`{{ cookiecutter.package_name }}.__version__`) - * Version of numpy (`numpy.__version__`) - * Version of pandas (`pandas.__version__`) - * Version of AnnData (`anndata.__version__`) - * Python version (*e.g. 3.7, 3.8*) - * OS (*e.g. Arch Linux, Windows 10, MacOS*) + ```python + import session_info + session_info.show(html=False, dependencies=True) + ``` placeholder: | - {{ cookiecutter.package_name }}: 0.7.0 - numpy: 1.22.3 - pandas: 1.4.2 - AnnData: 0.7.6 - Python: 3.7 - OS: Arch Linux + ----- + anndata 0.8.0rc2.dev27+ge524389 + session_info 1.0.0 + ----- + asttokens NA + awkward 1.8.0 + backcall 0.2.0 + cython_runtime NA + dateutil 2.8.2 + debugpy 1.6.0 + decorator 5.1.1 + entrypoints 0.4 + executing 0.8.3 + h5py 3.7.0 + ipykernel 6.15.0 + jedi 0.18.1 + mpl_toolkits NA + natsort 8.1.0 + numpy 1.22.4 + packaging 21.3 + pandas 1.4.2 + parso 0.8.3 + pexpect 4.8.0 + pickleshare 0.7.5 + pkg_resources NA + prompt_toolkit 3.0.29 + psutil 5.9.1 + ptyprocess 0.7.0 + pure_eval 0.2.2 + pydev_ipython NA + pydevconsole NA + pydevd 2.8.0 + pydevd_file_utils NA + pydevd_plugins NA + pydevd_tracing NA + pygments 2.12.0 + pytz 2022.1 + scipy 1.8.1 + setuptools 62.5.0 + setuptools_scm NA + six 1.16.0 + stack_data 0.3.0 + tornado 6.1 + traitlets 5.3.0 + wcwidth 0.2.5 + zmq 23.1.0 + ----- + IPython 8.4.0 + jupyter_client 7.3.4 + jupyter_core 4.10.0 + ----- + Python 3.9.13 | packaged by conda-forge | (main, May 27 2022, 16:58:50) [GCC 10.3.0] + Linux-5.18.6-arch1-1-x86_64-with-glibc2.35 + ----- + Session information updated at 2022-07-07 17:55 diff --git a/{{cookiecutter.project_name}}/pyproject.toml b/{{cookiecutter.project_name}}/pyproject.toml index 60e3c587..35822404 100644 --- a/{{cookiecutter.project_name}}/pyproject.toml +++ b/{{cookiecutter.project_name}}/pyproject.toml @@ -22,7 +22,11 @@ version = "0.0.1" requires-python = ">=3.8" license = {file = "LICENSE"} readme = "README.md" -dependencies = ["anndata"] +dependencies = [ + "anndata", + # for debug logging (referenced from the issue template) + "session-info" +] [project.optional-dependencies] dev = [ From 9f5c354380b646765f041d71a15b7d5f54418897 Mon Sep 17 00:00:00 2001 From: Gregor Sturm Date: Fri, 14 Oct 2022 09:06:38 +0200 Subject: [PATCH 3/4] Update {{cookiecutter.project_name}}/.github/ISSUE_TEMPLATE/bug_report.yml Co-authored-by: Giovanni Palla <25887487+giovp@users.noreply.github.com> --- .../.github/ISSUE_TEMPLATE/bug_report.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/{{cookiecutter.project_name}}/.github/ISSUE_TEMPLATE/bug_report.yml b/{{cookiecutter.project_name}}/.github/ISSUE_TEMPLATE/bug_report.yml index 85e8b175..9a9ca914 100644 --- a/{{cookiecutter.project_name}}/.github/ISSUE_TEMPLATE/bug_report.yml +++ b/{{cookiecutter.project_name}}/.github/ISSUE_TEMPLATE/bug_report.yml @@ -24,7 +24,7 @@ body: id: repex attributes: label: Minimal reproducible example - description: A code snipped that we can copy&paste to reproduce the bug without having any data + description: A code snippet that we can copy&paste to reproduce the bug without having any data render: python placeholder: | import scanpy as sc From db61be84b410c6bdc5e17501825bf11272caeb79 Mon Sep 17 00:00:00 2001 From: Gregor Sturm Date: Wed, 19 Oct 2022 10:38:35 +0200 Subject: [PATCH 4/4] Update {{cookiecutter.project_name}}/.github/ISSUE_TEMPLATE/bug_report.yml Co-authored-by: Isaac Virshup --- .../.github/ISSUE_TEMPLATE/bug_report.yml | 33 ++----------------- 1 file changed, 2 insertions(+), 31 deletions(-) diff --git a/{{cookiecutter.project_name}}/.github/ISSUE_TEMPLATE/bug_report.yml b/{{cookiecutter.project_name}}/.github/ISSUE_TEMPLATE/bug_report.yml index 9a9ca914..9dfd4acb 100644 --- a/{{cookiecutter.project_name}}/.github/ISSUE_TEMPLATE/bug_report.yml +++ b/{{cookiecutter.project_name}}/.github/ISSUE_TEMPLATE/bug_report.yml @@ -13,42 +13,13 @@ body: available datasets or to share a subset of your data. - type: textarea - id: description + id: report attributes: - label: Description of the bug + label: Report description: A clear and concise description of what the bug is. validations: required: true - - type: textarea - id: repex - attributes: - label: Minimal reproducible example - description: A code snippet that we can copy&paste to reproduce the bug without having any data - render: python - placeholder: | - import scanpy as sc - adata = sc.datasets.pbmc3k() - - sc.do_something_that_doesnt_work(adata) - - - type: textarea - id: stacktrace - attributes: - label: The error message produced by the code above - description: Please paste the entire error message - render: pytb - placeholder: | - --------------------------------------------------------------------------- - AssertionError Traceback (most recent call last) - in - ----> 1 adata = sc.do_something_that_doesnt_work(adata) - - /opt/conda/lib/python3.8/site-packages/scanpy/_preprocessing.py in do_something_that_doesnt_work(adata) - 438 - --> 439 raise AssertionError("Demo function that fails") - 440 - - type: textarea id: versions attributes: