j-law-python 0.0.7__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- j_law_python-0.0.7/MANIFEST.in +6 -0
- j_law_python-0.0.7/PKG-INFO +140 -0
- j_law_python-0.0.7/README.md +113 -0
- j_law_python-0.0.7/j_law_python/__init__.py +12 -0
- j_law_python-0.0.7/j_law_python/_c_ffi.py +783 -0
- j_law_python-0.0.7/j_law_python/build_support.py +248 -0
- j_law_python-0.0.7/j_law_python/consumption_tax.py +81 -0
- j_law_python-0.0.7/j_law_python/income_tax.py +266 -0
- j_law_python-0.0.7/j_law_python/real_estate.py +112 -0
- j_law_python-0.0.7/j_law_python/stamp_tax.py +125 -0
- j_law_python-0.0.7/j_law_python/withholding_tax.py +111 -0
- j_law_python-0.0.7/j_law_python.egg-info/PKG-INFO +140 -0
- j_law_python-0.0.7/j_law_python.egg-info/SOURCES.txt +95 -0
- j_law_python-0.0.7/j_law_python.egg-info/dependency_links.txt +1 -0
- j_law_python-0.0.7/j_law_python.egg-info/not-zip-safe +1 -0
- j_law_python-0.0.7/j_law_python.egg-info/requires.txt +3 -0
- j_law_python-0.0.7/j_law_python.egg-info/top_level.txt +1 -0
- j_law_python-0.0.7/pyproject.toml +45 -0
- j_law_python-0.0.7/setup.cfg +4 -0
- j_law_python-0.0.7/setup.py +71 -0
- j_law_python-0.0.7/tests/conftest.py +56 -0
- j_law_python-0.0.7/tests/test_c_ffi.py +198 -0
- j_law_python-0.0.7/tests/test_consumption_tax.py +77 -0
- j_law_python-0.0.7/tests/test_income_tax.py +69 -0
- j_law_python-0.0.7/tests/test_income_tax_deductions.py +130 -0
- j_law_python-0.0.7/tests/test_real_estate.py +77 -0
- j_law_python-0.0.7/tests/test_stamp_tax.py +65 -0
- j_law_python-0.0.7/tests/test_withholding_tax.py +70 -0
- j_law_python-0.0.7/vendor/rust/Cargo.lock +235 -0
- j_law_python-0.0.7/vendor/rust/Cargo.toml +12 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-c-ffi/Cargo.toml +20 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-c-ffi/j_law_c_ffi.h +493 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-c-ffi/src/lib.rs +1553 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/Cargo.toml +18 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/consumption_tax/calculator.rs +216 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/consumption_tax/context.rs +29 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/consumption_tax/mod.rs +9 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/consumption_tax/params.rs +24 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/consumption_tax/policy.rs +34 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/income_tax/assessment.rs +76 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/income_tax/calculator.rs +222 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/income_tax/context.rs +79 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/income_tax/deduction/calculator.rs +167 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/income_tax/deduction/context.rs +172 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/income_tax/deduction/expense.rs +465 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/income_tax/deduction/mod.rs +20 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/income_tax/deduction/params.rs +205 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/income_tax/deduction/personal.rs +324 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/income_tax/deduction/types.rs +61 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/income_tax/mod.rs +24 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/income_tax/params.rs +109 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/income_tax/policy.rs +103 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/mod.rs +5 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/real_estate/calculator.rs +197 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/real_estate/context.rs +48 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/real_estate/mod.rs +9 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/real_estate/params.rs +43 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/real_estate/policy.rs +40 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/stamp_tax/calculator.rs +321 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/stamp_tax/context.rs +408 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/stamp_tax/mod.rs +12 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/stamp_tax/params.rs +190 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/stamp_tax/policy.rs +105 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/withholding_tax/calculator.rs +247 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/withholding_tax/context.rs +167 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/withholding_tax/mod.rs +9 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/withholding_tax/params.rs +80 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/domains/withholding_tax/policy.rs +49 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/error.rs +171 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/lib.rs +9 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/types/amount.rs +232 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/types/citation.rs +82 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/types/date.rs +280 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/types/mod.rs +11 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/types/rate.rs +219 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-core/src/types/rounding.rs +81 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-registry/Cargo.toml +15 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-registry/data/consumption_tax/consumption_tax.json +70 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-registry/data/income_tax/deductions.json +327 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-registry/data/income_tax/income_tax.json +352 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-registry/data/real_estate/brokerage_fee.json +125 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-registry/data/stamp_tax/stamp_tax.json +674 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-registry/data/withholding_tax/withholding_tax.json +70 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-registry/src/consumption_tax_loader.rs +325 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-registry/src/consumption_tax_schema.rs +49 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-registry/src/income_tax_deduction_loader.rs +636 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-registry/src/income_tax_deduction_schema.rs +111 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-registry/src/income_tax_loader.rs +445 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-registry/src/income_tax_schema.rs +44 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-registry/src/lib.rs +20 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-registry/src/loader.rs +221 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-registry/src/schema.rs +73 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-registry/src/stamp_tax_loader.rs +374 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-registry/src/stamp_tax_schema.rs +72 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-registry/src/validator.rs +204 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-registry/src/withholding_tax_loader.rs +310 -0
- j_law_python-0.0.7/vendor/rust/crates/j-law-registry/src/withholding_tax_schema.rs +61 -0
|
@@ -0,0 +1,140 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: j-law-python
|
|
3
|
+
Version: 0.0.7
|
|
4
|
+
Summary: 日本法令計算の PoC を Python から利用するためのアルファ版バインディング
|
|
5
|
+
License: MIT
|
|
6
|
+
Project-URL: Homepage, https://github.com/kmoyashi/j-law-core
|
|
7
|
+
Project-URL: Repository, https://github.com/kmoyashi/j-law-core
|
|
8
|
+
Project-URL: Bug Tracker, https://github.com/kmoyashi/j-law-core/issues
|
|
9
|
+
Keywords: japan,law,tax,real-estate,calculation
|
|
10
|
+
Classifier: Development Status :: 3 - Alpha
|
|
11
|
+
Classifier: Intended Audience :: Developers
|
|
12
|
+
Classifier: License :: OSI Approved :: MIT License
|
|
13
|
+
Classifier: Programming Language :: Python :: 3
|
|
14
|
+
Classifier: Programming Language :: Python :: 3 :: Only
|
|
15
|
+
Classifier: Programming Language :: Python :: 3.10
|
|
16
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
17
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
18
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
19
|
+
Classifier: Programming Language :: Python :: 3.14
|
|
20
|
+
Classifier: Programming Language :: Python :: Implementation :: CPython
|
|
21
|
+
Classifier: Topic :: Office/Business :: Financial
|
|
22
|
+
Classifier: Topic :: Software Development :: Libraries :: Python Modules
|
|
23
|
+
Requires-Python: >=3.10
|
|
24
|
+
Description-Content-Type: text/markdown
|
|
25
|
+
Provides-Extra: test
|
|
26
|
+
Requires-Dist: pytest; extra == "test"
|
|
27
|
+
|
|
28
|
+
# j-law-python
|
|
29
|
+
|
|
30
|
+
日本法令計算の PoC を Python から試すためのバインディングです。
|
|
31
|
+
|
|
32
|
+
内部では `j-law-c-ffi` の C ABI を `ctypes` 経由で呼び出し、Rust コアの整数演算ロジックを Python から利用します。
|
|
33
|
+
|
|
34
|
+
> [!WARNING]
|
|
35
|
+
> **PoC / アルファ版に関する注意事項**
|
|
36
|
+
>
|
|
37
|
+
> - 本ライブラリは現在 **`v0.0.1` のアルファ版**です。API と配布形態は予告なく変更される場合があります。
|
|
38
|
+
> - この binding が返す計算結果について、法的正確性、完全性、最新性、個別事案への適合性は保証しません。
|
|
39
|
+
> - コードの一部には **AI 生成 / AI 補助**による実装が含まれ、人手による全面レビューは完了していません。
|
|
40
|
+
> - 税務申告や契約実務の唯一の根拠として使用せず、一次資料と専門家で検証してください。
|
|
41
|
+
> - 詳細は [プロジェクトステータスと免責](../../docs/project-status.md) を参照してください。
|
|
42
|
+
|
|
43
|
+
## 対応機能
|
|
44
|
+
|
|
45
|
+
- `j_law_python.consumption_tax.calc_consumption_tax`
|
|
46
|
+
- `j_law_python.real_estate.calc_brokerage_fee`
|
|
47
|
+
- `j_law_python.income_tax.calc_income_tax`
|
|
48
|
+
- `j_law_python.income_tax.calc_income_deductions`
|
|
49
|
+
- `j_law_python.income_tax.calc_income_tax_assessment`
|
|
50
|
+
- `j_law_python.stamp_tax.calc_stamp_tax`
|
|
51
|
+
- `j_law_python.withholding_tax.calc_withholding_tax`
|
|
52
|
+
|
|
53
|
+
## インストール
|
|
54
|
+
|
|
55
|
+
```sh
|
|
56
|
+
pip install j-law-python
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
CI と publish workflow で検証している組み合わせは次のとおりです。
|
|
60
|
+
|
|
61
|
+
- CPython `3.10` から `3.14`
|
|
62
|
+
- PyPI wheel: `linux/x86_64` `linux/aarch64` `macos/x86_64` `macos/arm64` `windows/amd64`
|
|
63
|
+
- それ以外の環境は source build 扱いです。Rust `1.94.0` が必要です。
|
|
64
|
+
|
|
65
|
+
リポジトリ checkout を直接 install / import する場合は、先に `j-law-c-ffi` をビルドしてください。
|
|
66
|
+
|
|
67
|
+
```sh
|
|
68
|
+
cargo build -p j-law-c-ffi
|
|
69
|
+
pip install ./crates/j-law-python
|
|
70
|
+
```
|
|
71
|
+
|
|
72
|
+
共有ライブラリの探索先を明示したい場合は `JLAW_PYTHON_C_FFI_LIB` を指定できます。
|
|
73
|
+
|
|
74
|
+
## クイックスタート
|
|
75
|
+
|
|
76
|
+
```python
|
|
77
|
+
import datetime
|
|
78
|
+
|
|
79
|
+
from j_law_python.consumption_tax import calc_consumption_tax
|
|
80
|
+
from j_law_python.income_tax import IncomeDeductionInput, calc_income_tax_assessment
|
|
81
|
+
from j_law_python.real_estate import calc_brokerage_fee
|
|
82
|
+
from j_law_python.stamp_tax import calc_stamp_tax
|
|
83
|
+
from j_law_python.withholding_tax import (
|
|
84
|
+
WithholdingTaxCategory,
|
|
85
|
+
calc_withholding_tax,
|
|
86
|
+
)
|
|
87
|
+
|
|
88
|
+
print(calc_consumption_tax(100_000, datetime.date(2024, 1, 1)).tax_amount)
|
|
89
|
+
print(calc_brokerage_fee(5_000_000, datetime.date(2024, 8, 1)).total_with_tax)
|
|
90
|
+
|
|
91
|
+
assessment = calc_income_tax_assessment(
|
|
92
|
+
IncomeDeductionInput(
|
|
93
|
+
total_income_amount=8_000_000,
|
|
94
|
+
date=datetime.date(2024, 1, 1),
|
|
95
|
+
social_insurance_premium_paid=600_000,
|
|
96
|
+
)
|
|
97
|
+
)
|
|
98
|
+
print(assessment.tax.total_tax)
|
|
99
|
+
|
|
100
|
+
print(
|
|
101
|
+
calc_stamp_tax(
|
|
102
|
+
"article1_real_estate_transfer",
|
|
103
|
+
5_000_000,
|
|
104
|
+
datetime.date(2024, 8, 1),
|
|
105
|
+
).tax_amount
|
|
106
|
+
)
|
|
107
|
+
|
|
108
|
+
print(
|
|
109
|
+
calc_withholding_tax(
|
|
110
|
+
1_500_000,
|
|
111
|
+
datetime.date(2026, 1, 1),
|
|
112
|
+
WithholdingTaxCategory.PROFESSIONAL_FEE,
|
|
113
|
+
).tax_amount
|
|
114
|
+
)
|
|
115
|
+
```
|
|
116
|
+
|
|
117
|
+
## API メモ
|
|
118
|
+
|
|
119
|
+
- すべての金額は整数円です。
|
|
120
|
+
- すべての API は `datetime.date` を受け取り、型不一致は `TypeError` を送出します。
|
|
121
|
+
- 入力不正や法令適用外日付は `ValueError` を送出します。
|
|
122
|
+
- `calc_stamp_tax()` の `document_code` / `flags` は文字列で指定します。
|
|
123
|
+
- `calc_withholding_tax()` の `category` は enum / 文字列 / 整数を受け取れます。
|
|
124
|
+
|
|
125
|
+
## テスト
|
|
126
|
+
|
|
127
|
+
```sh
|
|
128
|
+
pip install pytest
|
|
129
|
+
pytest crates/j-law-python/tests/ -v
|
|
130
|
+
```
|
|
131
|
+
|
|
132
|
+
## 関連ドキュメント
|
|
133
|
+
|
|
134
|
+
- [プロジェクトステータスと免責](../../docs/project-status.md)
|
|
135
|
+
- [リポジトリ README](../../README.md)
|
|
136
|
+
- [利用ガイド](../../docs/usage.md)
|
|
137
|
+
|
|
138
|
+
## ライセンス
|
|
139
|
+
|
|
140
|
+
[MIT License](../../LICENSE)
|
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
# j-law-python
|
|
2
|
+
|
|
3
|
+
日本法令計算の PoC を Python から試すためのバインディングです。
|
|
4
|
+
|
|
5
|
+
内部では `j-law-c-ffi` の C ABI を `ctypes` 経由で呼び出し、Rust コアの整数演算ロジックを Python から利用します。
|
|
6
|
+
|
|
7
|
+
> [!WARNING]
|
|
8
|
+
> **PoC / アルファ版に関する注意事項**
|
|
9
|
+
>
|
|
10
|
+
> - 本ライブラリは現在 **`v0.0.1` のアルファ版**です。API と配布形態は予告なく変更される場合があります。
|
|
11
|
+
> - この binding が返す計算結果について、法的正確性、完全性、最新性、個別事案への適合性は保証しません。
|
|
12
|
+
> - コードの一部には **AI 生成 / AI 補助**による実装が含まれ、人手による全面レビューは完了していません。
|
|
13
|
+
> - 税務申告や契約実務の唯一の根拠として使用せず、一次資料と専門家で検証してください。
|
|
14
|
+
> - 詳細は [プロジェクトステータスと免責](../../docs/project-status.md) を参照してください。
|
|
15
|
+
|
|
16
|
+
## 対応機能
|
|
17
|
+
|
|
18
|
+
- `j_law_python.consumption_tax.calc_consumption_tax`
|
|
19
|
+
- `j_law_python.real_estate.calc_brokerage_fee`
|
|
20
|
+
- `j_law_python.income_tax.calc_income_tax`
|
|
21
|
+
- `j_law_python.income_tax.calc_income_deductions`
|
|
22
|
+
- `j_law_python.income_tax.calc_income_tax_assessment`
|
|
23
|
+
- `j_law_python.stamp_tax.calc_stamp_tax`
|
|
24
|
+
- `j_law_python.withholding_tax.calc_withholding_tax`
|
|
25
|
+
|
|
26
|
+
## インストール
|
|
27
|
+
|
|
28
|
+
```sh
|
|
29
|
+
pip install j-law-python
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
CI と publish workflow で検証している組み合わせは次のとおりです。
|
|
33
|
+
|
|
34
|
+
- CPython `3.10` から `3.14`
|
|
35
|
+
- PyPI wheel: `linux/x86_64` `linux/aarch64` `macos/x86_64` `macos/arm64` `windows/amd64`
|
|
36
|
+
- それ以外の環境は source build 扱いです。Rust `1.94.0` が必要です。
|
|
37
|
+
|
|
38
|
+
リポジトリ checkout を直接 install / import する場合は、先に `j-law-c-ffi` をビルドしてください。
|
|
39
|
+
|
|
40
|
+
```sh
|
|
41
|
+
cargo build -p j-law-c-ffi
|
|
42
|
+
pip install ./crates/j-law-python
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
共有ライブラリの探索先を明示したい場合は `JLAW_PYTHON_C_FFI_LIB` を指定できます。
|
|
46
|
+
|
|
47
|
+
## クイックスタート
|
|
48
|
+
|
|
49
|
+
```python
|
|
50
|
+
import datetime
|
|
51
|
+
|
|
52
|
+
from j_law_python.consumption_tax import calc_consumption_tax
|
|
53
|
+
from j_law_python.income_tax import IncomeDeductionInput, calc_income_tax_assessment
|
|
54
|
+
from j_law_python.real_estate import calc_brokerage_fee
|
|
55
|
+
from j_law_python.stamp_tax import calc_stamp_tax
|
|
56
|
+
from j_law_python.withholding_tax import (
|
|
57
|
+
WithholdingTaxCategory,
|
|
58
|
+
calc_withholding_tax,
|
|
59
|
+
)
|
|
60
|
+
|
|
61
|
+
print(calc_consumption_tax(100_000, datetime.date(2024, 1, 1)).tax_amount)
|
|
62
|
+
print(calc_brokerage_fee(5_000_000, datetime.date(2024, 8, 1)).total_with_tax)
|
|
63
|
+
|
|
64
|
+
assessment = calc_income_tax_assessment(
|
|
65
|
+
IncomeDeductionInput(
|
|
66
|
+
total_income_amount=8_000_000,
|
|
67
|
+
date=datetime.date(2024, 1, 1),
|
|
68
|
+
social_insurance_premium_paid=600_000,
|
|
69
|
+
)
|
|
70
|
+
)
|
|
71
|
+
print(assessment.tax.total_tax)
|
|
72
|
+
|
|
73
|
+
print(
|
|
74
|
+
calc_stamp_tax(
|
|
75
|
+
"article1_real_estate_transfer",
|
|
76
|
+
5_000_000,
|
|
77
|
+
datetime.date(2024, 8, 1),
|
|
78
|
+
).tax_amount
|
|
79
|
+
)
|
|
80
|
+
|
|
81
|
+
print(
|
|
82
|
+
calc_withholding_tax(
|
|
83
|
+
1_500_000,
|
|
84
|
+
datetime.date(2026, 1, 1),
|
|
85
|
+
WithholdingTaxCategory.PROFESSIONAL_FEE,
|
|
86
|
+
).tax_amount
|
|
87
|
+
)
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
## API メモ
|
|
91
|
+
|
|
92
|
+
- すべての金額は整数円です。
|
|
93
|
+
- すべての API は `datetime.date` を受け取り、型不一致は `TypeError` を送出します。
|
|
94
|
+
- 入力不正や法令適用外日付は `ValueError` を送出します。
|
|
95
|
+
- `calc_stamp_tax()` の `document_code` / `flags` は文字列で指定します。
|
|
96
|
+
- `calc_withholding_tax()` の `category` は enum / 文字列 / 整数を受け取れます。
|
|
97
|
+
|
|
98
|
+
## テスト
|
|
99
|
+
|
|
100
|
+
```sh
|
|
101
|
+
pip install pytest
|
|
102
|
+
pytest crates/j-law-python/tests/ -v
|
|
103
|
+
```
|
|
104
|
+
|
|
105
|
+
## 関連ドキュメント
|
|
106
|
+
|
|
107
|
+
- [プロジェクトステータスと免責](../../docs/project-status.md)
|
|
108
|
+
- [リポジトリ README](../../README.md)
|
|
109
|
+
- [利用ガイド](../../docs/usage.md)
|
|
110
|
+
|
|
111
|
+
## ライセンス
|
|
112
|
+
|
|
113
|
+
[MIT License](../../LICENSE)
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
"""j_law_python — 日本の法令計算ライブラリ(Python バインディング)。
|
|
2
|
+
|
|
3
|
+
`j-law-c-ffi` の C FFI を `ctypes` でラップし、
|
|
4
|
+
datetime.date を受け取るインターフェースを提供する。
|
|
5
|
+
|
|
6
|
+
サブモジュール:
|
|
7
|
+
j_law_python.consumption_tax — 消費税(消費税法 第29条)
|
|
8
|
+
j_law_python.real_estate — 不動産(宅地建物取引業法 第46条)
|
|
9
|
+
j_law_python.income_tax — 所得税(所得税法 第89条)
|
|
10
|
+
j_law_python.stamp_tax — 印紙税(印紙税法 別表第一)
|
|
11
|
+
j_law_python.withholding_tax — 報酬・料金等の源泉徴収(所得税法 第204条)
|
|
12
|
+
"""
|