2020-11-04 08:49:04 +01:00
|
|
|
[tool.black]
|
2024-06-24 17:36:41 +05:00
|
|
|
line-length = 120
|
2024-07-30 11:22:41 +05:00
|
|
|
include = '''
|
|
|
|
|
src/(
|
|
|
|
|
bcf
|
|
|
|
|
|bcfserver
|
2024-09-05 17:13:25 +05:00
|
|
|
|bonsai
|
2024-07-30 11:22:41 +05:00
|
|
|
|bsdd
|
|
|
|
|
|foundationserver
|
|
|
|
|
|ifc2ca
|
|
|
|
|
|ifc4d
|
|
|
|
|
|ifc5d
|
|
|
|
|
|ifcbimtester
|
|
|
|
|
|ifcblender
|
|
|
|
|
|ifccityjson
|
|
|
|
|
|ifcclash
|
|
|
|
|
|ifccsv
|
|
|
|
|
|ifcdiff
|
|
|
|
|
|ifcfm
|
|
|
|
|
|ifcpatch
|
|
|
|
|
|ifctester
|
|
|
|
|
|ifcopenshell-python
|
|
|
|
|
|ifcsverchok
|
|
|
|
|
|opencdeserver
|
2025-05-28 12:29:32 +05:00
|
|
|
)/.*.pyi?$
|
2024-07-30 11:22:41 +05:00
|
|
|
'''
|
|
|
|
|
extend-exclude = '''
|
|
|
|
|
src/ifcopenshell-python/ifcopenshell/express/*
|
|
|
|
|
|src/ifcopenshell-python/ifcopenshell/mvd/*
|
2025-02-03 11:43:04 +05:00
|
|
|
|src/ifcopenshell-python/ifcopenshell/simple_spf/*
|
2024-07-30 11:22:41 +05:00
|
|
|
|src/ifc2ca/templates/*
|
2025-01-31 18:19:46 +05:00
|
|
|
|src/ifcconvert/cityjson/*
|
2024-07-30 11:22:41 +05:00
|
|
|
'''
|
2024-06-24 17:36:41 +05:00
|
|
|
|
|
|
|
|
[tool.pyright]
|
|
|
|
|
reportInvalidTypeForm = false
|
2024-07-01 13:33:47 +05:00
|
|
|
disableBytesTypePromotions = true
|
2025-04-18 12:20:25 +05:00
|
|
|
reportUnnecessaryTypeIgnoreComment = true
|
2025-05-16 18:12:33 +05:00
|
|
|
# Just to add a quick insert of `# pyright: ignore[xxx]` comments in Pylance.
|
|
|
|
|
enableTypeIgnoreComments = false
|
2025-05-28 17:31:10 +05:00
|
|
|
|
|
|
|
|
# Define here general ruff settings,
|
|
|
|
|
# then they will be inherited projects .toml files.
|
|
|
|
|
# This allows using assuming different Python version for different projects.
|
|
|
|
|
[tool.ruff]
|
|
|
|
|
exclude = [
|
|
|
|
|
# Submodules.
|
|
|
|
|
"src/ifcopenshell-python/ifcopenshell/express",
|
|
|
|
|
"src/ifcopenshell-python/ifcopenshell/mvd",
|
|
|
|
|
"src/ifcopenshell-python/ifcopenshell/simple_spf",
|
|
|
|
|
"src/svgfill",
|
|
|
|
|
#
|
|
|
|
|
# Unformatted.
|
|
|
|
|
"src/exterior-shell-extractor",
|
|
|
|
|
# Incompatible with linter.
|
|
|
|
|
"src/ifc2ca/templates",
|
|
|
|
|
]
|
|
|
|
|
[tool.ruff.lint]
|
|
|
|
|
select = [
|
|
|
|
|
# Default Ruff rules.
|
|
|
|
|
# "E4", # imports
|
|
|
|
|
# "E7", # statements
|
|
|
|
|
"E9", # io errors
|
|
|
|
|
# "F", # pyflakes
|
|
|
|
|
#
|
|
|
|
|
"FA", # future annotations
|
|
|
|
|
"UP", # pyupgrade
|
|
|
|
|
]
|
|
|
|
|
ignore = [
|
|
|
|
|
"FA100", # Conflicts with Blender using annotations for props definitions.
|
|
|
|
|
# Maybe will enable later:
|
|
|
|
|
"UP006", # deprecated symbols
|
|
|
|
|
"UP007", # Optional to X | Y
|
|
|
|
|
"UP015", # Unnecessary mode argument
|
|
|
|
|
"UP028", # yield for -> yield from
|
|
|
|
|
"UP030", # implicit references for positional format fields
|
|
|
|
|
"UP031", # Replace % with .format
|
|
|
|
|
"UP032", # Replace .format with f-string
|
|
|
|
|
"UP035", # List -> list
|
|
|
|
|
|
|
|
|
|
# Deprecated Ruff rules.
|
|
|
|
|
"UP038", # Use X | Y in isinstance
|
|
|
|
|
]
|