Files
aqtinstall/pyproject.toml
Alexandre Poumaroux a09b5cee28 Fix WASM (#846)
* Rewrite WASM support

* Add WASM tests to CI, update CI to test more the latest versions, add auto EMSDK version detection function

* Fix some mistakes, typos, moved emsdk version function into BuildJob

* Fix issue related to extensions interfering with wasm on 6.8+

* Fix tests

* Remove dep on Version in CI

* Remove safety before patch

* handle cases where extensions don't exist.

for example with windows desktop 6.8.1 win64_msvc2022_arm64_cross_compiled
both qtwebengine and qtpdf don't exist.

Signed-off-by: Alexandre 'Kidev' Poumaroux <1204936+Kidev@users.noreply.github.com>

* for --long-modules assume extension doesn't exist on download error.

Signed-off-by: Alexandre 'Kidev' Poumaroux <1204936+Kidev@users.noreply.github.com>

* for --modules assume extension doesn't exist for download failures.

Signed-off-by: Alexandre 'Kidev' Poumaroux <1204936+Kidev@users.noreply.github.com>

* reformat with black

Signed-off-by: Alexandre 'Kidev' Poumaroux <1204936+Kidev@users.noreply.github.com>

* fix flake8 regression that doesn't occur locally.

Signed-off-by: Alexandre 'Kidev' Poumaroux <1204936+Kidev@users.noreply.github.com>

* Fix autodesktop by also updating the OS when searching for a valid desktop version to download

* Fix extension issue, reduce the possible retry for getting extensions to prevent server spam

* Fix CI asking for msvc2019 on 6.8+ but its no longer supported

* Make CI use C++20 and MSVC2022

* Fix linux build

* Update runners to windows-2022

Signed-off-by: Alexandre 'Kidev' Poumaroux <1204936+Kidev@users.noreply.github.com>

* Fix patching

Signed-off-by: Alexandre 'Kidev' Poumaroux <1204936+Kidev@users.noreply.github.com>

* Add back the semantic version changes to prevent crashes, add tests for it

* Update checks

* Cast 'https://mirrors.ustc.edu.cn' to the shadow realm

* Again

* Update settings.ini

* Update settings.ini

* Update settings.ini

* Remove one_rep on silent

* Update settings.ini

* Restore master settings, remove hash check

* ci: Use specific mirror

Attempt to work around download errors in Azure due to Qt's official download site often redirecting to mirrors to which the network connection is unstable

Signed-off-by: Alexandre 'Kidev' Poumaroux <1204936+Kidev@users.noreply.github.com>

* Re enable hash checking

* Treat read timeout error during download as connection error

Signed-off-by: Alexandre 'Kidev' Poumaroux <1204936+Kidev@users.noreply.github.com>

* Add test for modules in WASM with autodesktop

* Fix format

* Fix test

* Make '--autodesktop' trigger its own install process, and test it

* Fix older autodesktop tests

* Add mock update files for 680 wasm, add test for wasm 680 autodesktop

* Passes the additional tests

* Fix format

* Improve coverage, fix format

* Fix tests and improve logging or install

* Fix format

* Fix regression in other tests

* Use flavor

* Fix line len

* Fix codeql

* Fix list-qt for WASM arch on 6.5.x and 6.6.x, restore to original download URL

* Fix test error

* Revert ci settings URL as it is never used by clients, only in CI

* Add comment for clarity in ci/settings.ini

---------

Signed-off-by: Alexandre 'Kidev' Poumaroux <1204936+Kidev@users.noreply.github.com>
Co-authored-by: tsteven4 <13596209+tsteven4@users.noreply.github.com>
Co-authored-by: J.D. Purcell <jdpurcell@gmail.com>
2025-01-06 15:35:40 +09:00

252 lines
5.8 KiB
TOML

[project]
name = "aqtinstall"
description = "Another unofficial Qt installer"
license = {text = "MIT License"}
authors = [
{name = "Hiroshi Miura", email = "miurahr@linux.com"},
]
classifiers = [
"Development Status :: 4 - Beta",
"Environment :: Console",
"Environment :: X11 Applications :: Qt",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Operating System :: MacOS :: MacOS X",
"Operating System :: Microsoft :: Windows",
"Operating System :: POSIX",
"Operating System :: POSIX :: Linux",
"Programming Language :: Python",
"Programming Language :: C++",
"Topic :: Software Development",
"Topic :: Software Development :: Libraries",
]
requires-python = ">=3.9"
dependencies = [
"bs4", # canonical name is beautifulsoup4
"defusedxml",
"humanize",
"patch>=1.16",
"py7zr>=0.22.0",
"requests>=2.31.0",
"semantic-version",
"texttable",
]
dynamic = ["version", "readme"]
[tool.setuptools]
packages = ["aqt"]
[tool.setuptools.dynamic]
readme = {file = ["README.rst"]}
[tool.setuptools.package-data]
aqt = ["*.yml", "*.ini"]
[project.scripts]
aqt = "aqt.__main__:main"
[project.optional-dependencies]
test = [
"pytest>=6.0",
"pytest-pep8",
"pytest-cov",
"pytest-remotedata>=0.4.1",
"pytest-socket",
"pytest-timeout",
"pympler",
]
check = [
"mypy>=1.10.0",
"flake8>=6.0.0,<8.0.0",
"flake8-black",
"flake8-colors",
"flake8-isort>=6.0.0,<7.0.0",
"flake8-pyi",
"flake8-typing-imports",
"docutils",
"check-manifest",
"readme-renderer",
"pygments",
"packaging",
"pylint",
"types-requests",
]
docs = [
"sphinx>=7.0",
"sphinx_rtd_theme>=1.3",
"sphinx-py3doc-enhanced-theme>=2.4",
]
debug = [
"pytest-leaks",
]
[project.urls]
Documentation = "https://aqtinstall.readthedocs.io/"
"Bug Tracker" = "https://github.com/miurahr/aqtinstall/issues"
Wiki = "https://github.com/miurahr/aqtinstall/wiki"
Source = "https://github.com/miurahr/aqtinstall"
Changelog = "https://aqtinstall.readthedocs.io/en/latest/CHANGELOG.html"
[build-system]
requires = ["setuptools>=61", "wheel", "setuptools_scm[toml]>=6.4"]
build-backend = "setuptools.build_meta"
[tool.setuptools_scm]
local_scheme = "no-local-version"
write_to = "aqt/version.py"
write_to_template = """
__version__ = \"{version}\"
"""
tag_regex = "^(?P<prefix>v)?(?P<version>[^\\+]+)(?P<suffix>.*)?$"
[tool.check-manifest]
ignore = ["aqt/version.py","azure-pipelines.yml", ".readthedocs.yml", "ci/*"]
[tool.coverage.run]
branch = true
parallel = true
source = ["aqt", "tests"]
[tool.coverage.report]
show_missing = true
exclude_lines = ["if __name__ == .__main__.:", "pragma: no-cover", "@abstract", "def __repr__"]
[tool.pylint]
max-line-length = 125
[tool.black]
line-length = 125
target-version = ['py312']
[tool.isort]
line_length = 125
known_first_party = "aqt"
known_third_party = ["docutils", "flake8", "pyannotate_runtime", "pytest", "pytz", "requests", "setuptools", "sphinx", "yaml", "packaging"]
multi_line_output = 3
include_trailing_comma = true
force_grid_wrap = 0
use_parentheses = true
ensure_newline_before_comments = true
[tool.mypy]
# Untyped definitions and calls are disable in default
check_untyped_defs = false
disallow_incomplete_defs = false
disallow_untyped_calls = false
disallow_untyped_defs = false
disallow_untyped_decorators = false
# not a all 3rd party package has type hints
ignore_missing_imports = true
# Optional check: implicit check enabled in mypy 0.980 or before
strict_optional = true
implicit_optional = false
# Enable incremental mode and use sqlite cache
incremental = true
sqlite_cache = true
# Enables PEP 420 style namespace packages
namespace_packages = true
# Control error output
pretty = true
color_output = true
show_error_context = false
show_column_numbers = true
error_summary = true
# configuring warnings
warn_no_return = true
warn_redundant_casts = true
warn_return_any = true
warn_unreachable = true
warn_unused_ignores = true
# TODO: Remove this `ignore_missing_imports` and add type stubs.
# See https://mypy.readthedocs.io/en/stable/running_mypy.html#missing-imports
[[tool.mypy.overrides]]
module = "texttable"
ignore_missing_imports = true
[tool.pytest.ini_options]
minversion = "6.0"
testpaths = ["tests"]
python_files = "test*.py"
norecursedirs = [".git", "_build", "tmp", ".eggs"]
timeout = 480
markers = [
"unit: mark a test as an unit test.",
"enable_socket : mark a test with enabling socket.",
"remote_data: mark a test with remote data.",
]
[tool.tox]
legacy_tox_ini = """
[tox]
envlist = check, docs, py{39,310,311,312,313}, mprof, fil, mypy
isolated_build = True
[testenv]
passenv =
GITHUB*
APPVEYOR*
TRAVIS*
COVERALLS_*
PYTEST_ADDOPTS
extras = test, check, docs
commands =
python -m pytest -vv
[testenv:check]
basepython = python3.12
extras = check
commands =
check-manifest {toxinidir}
flake8 aqt tests
[testenv:mypy]
basepython = python3.12
extras = check
commands = mypy aqt
deps =
types-requests
types-beautifulsoup4
types-psutil
[testenv:docs]
basepython = python3.12
extras = docs
commands =
sphinx-build {posargs:-E} -W -b html docs build/docs
sphinx-build -W -b linkcheck docs build/docs
[testenv:mprof]
basepython = python3.12
extras = debug
commands =
mprof run --multiprocess python -m aqt install-qt -O /tmp -d /tmp linux desktop 6.8.1
mprof plot --output memory-profile.png
deps =
memory_profiler
matplotlib
[testenv:fil]
basepython = python3.12
extras = debug
commands =
fil-profile run -m aqt install-qt -O /tmp -d /tmp linux desktop 6.8.1
deps =
filprofiler
[testenv:coveralls]
deps =
coveralls
skip_install = true
commands =
coveralls []
[gh-actions]
python =
3.9: py39
3.10: py310
3.11: py311
3.12: py312
3.13: py313
"""