Skip to content
Merged
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
4 changes: 2 additions & 2 deletions .devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
}
},
"postCreateCommand": {
"pre-commit": "pre-commit install --hook-type commit-msg --hook-type pre-commit --hook-type pre-push",
"pre-commit": "pre-commit install --hook-type pre-commit --hook-type commit-msg --hook-type pre-push",
"dev-requirements": "python2 -m pip install --requirement requirements.txt"
}
}
}
8 changes: 3 additions & 5 deletions .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -6,19 +6,17 @@ root = true
[*]
charset = utf-8
end_of_line = lf
indent_style = space
trim_trailing_whitespace = true

[*.{json}]
indent_size = 2
indent_style = space
insert_final_newline = false

[*.{md,toml,yaml,yml}]
indent_size = 2
indent_style = space
insert_final_newline = true

[*.{py,pyi}]
[*.{ini,py,pyi}]
indent_size = 4
indent_style = space
insert_final_newline = true
insert_final_newline = true
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,4 @@ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
SOFTWARE.
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[metadata]
name = java_api
version = 17.26.0
description = Java API Specification for ignition-api
description = Java API Specification
long_description = file: README.md
long_description_content_type = text/markdown
url = https://github.com/ignition-devs/java-api
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# pylint: skip-file
"""Java API Specification."""
"""Java API Specification"""

from setuptools import setup

Expand Down
8 changes: 3 additions & 5 deletions stubs/pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[build-system]
build-backend = "setuptools.build_meta"
requires = [
"setuptools",
"setuptools>=61.2",
]

[project]
Expand Down Expand Up @@ -35,15 +35,13 @@ classifiers = [
"Typing :: Stubs Only",
"Typing :: Typed",
]
urls.Homepage = "https://github.com/ignition-devs/java-api"
urls.Documentation = "https://docs.oracle.com/en/java/javase/17/docs/api/index.html"
urls.Funding = "https://github.com/sponsors/cesarcoatl"
urls.Homepage = "https://github.com/ignition-devs/java-api"
urls.Source = "https://github.com/ignition-devs/java-api/tree/main"
urls.Tracker = "https://github.com/ignition-devs/java-api/issues"

[tool.setuptools]
include-package-data = true
package-dir = { "" = "stubs" }

[tool.setuptools.package-data]
"*" = [ "*.pyi", "py.typed" ]
package-data."*" = [ "*.pyi", "py.typed" ]
2 changes: 1 addition & 1 deletion stubs/tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ description = run type check on code base
base_python = python3.12
skip_install = true
deps =
mypy[python2]@ git+https://github.com/coatl-dev/mypy.git@v0.971
mypy[python2] @ git+https://github.com/coatl-dev/mypy.git@v0.971
commands =
mypy stubs

Expand Down
44 changes: 7 additions & 37 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ description = run type check on code base
base_python = python3.12
skip_install = true
deps =
mypy[python2]@ git+https://github.com/coatl-dev/mypy.git@v0.971
mypy[python2] @ git+https://github.com/coatl-dev/mypy.git@v0.971
commands =
mypy --install-types --non-interactive src

Expand All @@ -26,60 +26,30 @@ description = generate stubs
base_python = python3.12
skip_install = true
deps =
mypy[python2]@ git+https://github.com/coatl-dev/mypy.git@v0.971
mypy[python2] @ git+https://github.com/coatl-dev/mypy.git@v0.971
commands =
stubgen --export-less --output=stubs{/}stubs src

[testenv:style]
description = apply style
base_python = python3.12
skip_install = true
deps =
black
docformatter
flake8@ git+https://github.com/coatl-dev/flake8.git@5.0.4
isort
pydoclint
pydocstyle
sort-all
unimport
commands =
python -c \
"import pathlib, subprocess; \
files = [str(p) for p in pathlib.Path('src').rglob('*.py')]; \
subprocess.run(['sort-all'] + files, check=True)"
black --quiet src
unimport src
isort --settings-file=tox.ini src
docformatter \
--in-place \
--wrap-summaries 72 \
--close-quotes-on-newline \
--recursive \
src
flake8 --select=DOC --config=tox.ini src
pydocstyle --config=tox.ini src{/}system

[docformatter]
close-quotes-on-newline = true
in-place = true
wrap-summaries = 72
close-quotes-on-newline = true

[flake8]
arg-type-hints-in-docstring = False
arg-type-hints-in-signature = False
check-return-types = False
ignore = DOC202, E741, F821
max-complexity = 10
max-doc-length = 72
max-line-length = 120
style = google
arg-type-hints-in-docstring = False
arg-type-hints-in-signature = False
check-return-types = False

[isort]
extra_standard_library = typing
profile = black
py_version = 27

[pydocstyle]
convention = google
add_ignore = D101, D102, D104, D105, D106, D107, D205, D415
convention = google