Skip to content

🖌️ adopt dprint #471

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/bug-report.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ body:
attributes:
label: "Type-checker version and configuration:"
description: >
Please include the exact version of the type-checker you are using.
Please include the exact version of the type-checker you are using.
Popular (static) type checkers include Mypy, Pyright / Pylance, Pytype, Pyre, PyCharm, etc.
Also include the full CLI command used to run the type-checker, and all of the relevant configuration options.
validations:
Expand Down
22 changes: 11 additions & 11 deletions .github/ISSUE_TEMPLATE/documentation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,15 @@ title: "<Please write a comprehensive title>"
labels: ["topic: Docs"]

body:
- type: textarea
attributes:
label: "Issue with current documentation:"
description: >
Please make sure to leave a reference to the document/code you're
referring to. You can also check the development version of the
documentation.
- type: textarea
attributes:
label: "Issue with current documentation:"
description: >
Please make sure to leave a reference to the document/code you're
referring to. You can also check the development version of the
documentation.

- type: textarea
attributes:
label: "Idea or request for content:"
description: Please describe as clearly as possible what topics you think are missing from the current documentation.
- type: textarea
attributes:
label: "Idea or request for content:"
description: Please describe as clearly as possible what topics you think are missing from the current documentation.
22 changes: 11 additions & 11 deletions .github/ISSUE_TEMPLATE/feature-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,15 @@ description: Suggest an improvement or propose a new feature.
title: "<Please write a comprehensive title>"
labels: ["stubs: Enhancement"]
body:
- type: markdown
attributes:
value: >
If you're looking to request a new feature or change in functionality,
including adding or changing the meaning of arguments to an existing
function.
- type: markdown
attributes:
value: >
If you're looking to request a new feature or change in functionality,
including adding or changing the meaning of arguments to an existing
function.

- type: textarea
attributes:
label: "Please describe the feature or change you would like to see:"
validations:
required: true
- type: textarea
attributes:
label: "Please describe the feature or change you would like to see:"
validations:
required: true
195 changes: 97 additions & 98 deletions .github/labeler.yml
Original file line number Diff line number Diff line change
@@ -1,155 +1,154 @@
"numpy.ctypeslib.*":
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/ctypeslib.pyi
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/ctypeslib.pyi

"numpy.distutils.*":
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/distutils/**
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/distutils/**

"numpy.dtype":
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/dtypes.pyi
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/dtypes.pyi
Comment on lines +12 to +14
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not sure why this is 2/6/10, the indentation is set to '2'. it might be a bug in pretty-yaml

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you usually prefer fibonacci indentation, right?


"numpy.dtypes.*":
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/dtypes.pyi
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/dtypes.pyi

"numpy.emath.*":
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/lib/_scimath_impl.pyi
- src/numpy-stubs/lib/scimath.pyi
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/lib/_scimath_impl.pyi
- src/numpy-stubs/lib/scimath.pyi

"numpy.f2py.*":
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/f2py/**
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/f2py/**

"numpy.fft.*":
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/fft/**
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/fft/**

"numpy.linalg.*":
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/linalg/**
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/linalg/**

"numpy.ma.*":
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/ma/**
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/ma/**

"numpy.matlib.*":
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/matlib.pyi
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/matlib.pyi

"numpy.matrixlib.*":
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/matrixlib/**
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/matrixlib/**

"numpy.poly*":
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/lib/_polynomial_impl.pyi
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/lib/_polynomial_impl.pyi

"numpy.polynomial.*":
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/polynomial/**
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/polynomial/**

"numpy.random.*":
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/random/**
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/random/**

"numpy.rec.*":
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/rec/**
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/rec/**

"numpy.strings.*":
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/_core/strings.pyi
- src/numpy-stubs/strings/**.pyi
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/_core/strings.pyi
- src/numpy-stubs/strings/**.pyi

"numpy.testing.*":
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/testing/**
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/testing/**

"numpy.ufunc":
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/_core/umath.pyi
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/_core/umath.pyi

"numpy._utils":
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/_utils/**
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/_utils/**

"numpy.version.*":
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/version.pyi
- changed-files:
- any-glob-to-any-file:
- src/numpy-stubs/version.pyi

# Documentation and Testing
# Documentation and Testing

"topic: documentation":
- changed-files:
- any-glob-to-any-file:
- docs/**
- README.md
- CONTRIBUTING.md
- mkdocs.yml
- changed-files:
- any-glob-to-any-file:
- docs/**
- README.md
- CONTRIBUTING.md
- mkdocs.yml

"topic: testing":
- changed-files:
- any-glob-to-any-file:
- src/**/@test/**
- tool/test/**
- changed-files:
- any-glob-to-any-file:
- src/**/@test/**
- tool/test/**

# Tools and Configuration
# Tools and Configuration

"tool: stubtest":
- changed-files:
- any-glob-to-any-file:
- tool/allowlists/**
- tool/stubtest.py
- changed-files:
- any-glob-to-any-file:
- tool/allowlists/**
- tool/stubtest.py

"tool: github-actions":
- changed-files:
- any-glob-to-any-file:
- .github/workflows/**
- changed-files:
- any-glob-to-any-file:
- .github/workflows/**

"topic: dependencies":
- changed-files:
- any-glob-to-any-file:
- uv.lock
- tool/*.lock
- changed-files:
- any-glob-to-any-file:
- uv.lock
- tool/*.lock

"topic: developer experience":
- changed-files:
- any-glob-to-any-file:
- .vscode/**
- lefthook.yml
- changed-files:
- any-glob-to-any-file:
- .vscode/**
- lefthook.yml

"topic: automation":
- changed-files:
- any-glob-to-any-file:
- .github/workflows/**
- tool/testgen.py
- changed-files:
- any-glob-to-any-file:
- .github/workflows/**
- tool/testgen.py

"topic: code style":
- changed-files:
- any-glob-to-any-file:
- .taplo.toml
- **/.ruff.toml

- changed-files:
- any-glob-to-any-file:
- .taplo.toml
- **/.ruff.toml
3 changes: 3 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,9 @@ jobs:
uv run --no-sync ruff check --output-format=github
uv run --no-sync ruff format --check

- name: dprint
run: uv run --no-sync dprint check

- name: pytest
run: uv run --no-sync pytest

Expand Down
2 changes: 1 addition & 1 deletion .taplo.toml
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this should probably be deleted, or be made compatible with the dprint toml style

Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ column_width = 88
compact_arrays = true
compact_inline_tables = true
crlf = false
indent_string = " " # 4 spaces
indent_string = " " # 4 spaces
indent_tables = true
reorder_keys = false
reorder_arrays = false
Expand Down
3 changes: 2 additions & 1 deletion .vscode/extensions.json
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

gh won't let me suggest it; but davidanson.vscode-markdownlint can also 🔥

Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,8 @@
"ms-python.python",
"redhat.vscode-yaml",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔥

Suggested change
"redhat.vscode-yaml",

"seatonjiang.gitmoji-vscode",
"tamasfe.even-better-toml"
"tamasfe.even-better-toml",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔥

Suggested change
"tamasfe.even-better-toml",

"dprint.dprint"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If I may pick a nit; It'd help appease my neuroticism if this were to be sorted alphabetically.

],
"unwantedRecommendations": ["ms-pyright.pyright", "ms-python.vscode-pylance"]
}
5 changes: 2 additions & 3 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,14 @@ grow.

Pull requests (PRs) are always welcome, but making a PR is just the
start. Please respond to comments and requests for changes to help move
the process forward. Please follow our [Code of
Conduct](https://numpy.org/code-of-conduct/), which applies to all
the process forward. Please follow our [Code of Conduct](https://numpy.org/code-of-conduct/), which applies to all
interactions, including issues and PRs.

For more, please read <https://www.numpy.org/devdocs/dev/index.html>

Thank you for contributing, and happy coding!

______________________________________________________________________
---

<!--overview-start-->

Expand Down
6 changes: 3 additions & 3 deletions docs/contributing.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ hide:
# Contributing to NumType

{%
include-markdown "../CONTRIBUTING.md"
start="<!--overview-start-->"
end="<!--overview-end-->"
include-markdown "../CONTRIBUTING.md"
start="<!--overview-start-->"
end="<!--overview-end-->"
%}
Loading
Loading