vidhi 0.0.3__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.
Files changed (72) hide show
  1. vidhi-0.0.3/.github/workflows/deploy_docs.yml +56 -0
  2. vidhi-0.0.3/.github/workflows/lint.yml +40 -0
  3. vidhi-0.0.3/.github/workflows/publish.yml +51 -0
  4. vidhi-0.0.3/.github/workflows/publish_nightly.yml +48 -0
  5. vidhi-0.0.3/.github/workflows/test.yml +37 -0
  6. vidhi-0.0.3/.gitignore +92 -0
  7. vidhi-0.0.3/.readthedocs.yaml +19 -0
  8. vidhi-0.0.3/CONTRIBUTING.md +108 -0
  9. vidhi-0.0.3/LICENSE +201 -0
  10. vidhi-0.0.3/Makefile +106 -0
  11. vidhi-0.0.3/PKG-INFO +196 -0
  12. vidhi-0.0.3/README.md +158 -0
  13. vidhi-0.0.3/docs/Makefile +22 -0
  14. vidhi-0.0.3/docs/_static/custom.css +11 -0
  15. vidhi-0.0.3/docs/conf.py +37 -0
  16. vidhi-0.0.3/docs/index.rst +65 -0
  17. vidhi-0.0.3/docs/installation.rst +50 -0
  18. vidhi-0.0.3/docs/quickstart.rst +275 -0
  19. vidhi-0.0.3/docs/requirements.txt +3 -0
  20. vidhi-0.0.3/docs/user_guide/api.rst +66 -0
  21. vidhi-0.0.3/docs/user_guide/cli.rst +238 -0
  22. vidhi-0.0.3/docs/user_guide/frozen_dataclasses.rst +54 -0
  23. vidhi-0.0.3/docs/user_guide/ide.rst +56 -0
  24. vidhi-0.0.3/docs/user_guide/index.rst +27 -0
  25. vidhi-0.0.3/docs/user_guide/polymorphic.rst +256 -0
  26. vidhi-0.0.3/docs/user_guide/shell_completion.rst +109 -0
  27. vidhi-0.0.3/docs/user_guide/yaml.rst +69 -0
  28. vidhi-0.0.3/examples/01_basic_usage.py +86 -0
  29. vidhi-0.0.3/examples/02_polymorphic_cli.py +338 -0
  30. vidhi-0.0.3/examples/03_yaml_config.py +189 -0
  31. vidhi-0.0.3/examples/04_cli_yaml_combo.py +135 -0
  32. vidhi-0.0.3/examples/README.md +45 -0
  33. vidhi-0.0.3/examples/config.yaml +16 -0
  34. vidhi-0.0.3/pyproject.toml +114 -0
  35. vidhi-0.0.3/setup.cfg +4 -0
  36. vidhi-0.0.3/setup.py +43 -0
  37. vidhi-0.0.3/tests/test_base_poly_config.py +43 -0
  38. vidhi-0.0.3/tests/test_cli_api.py +365 -0
  39. vidhi-0.0.3/tests/test_cli_completion.py +366 -0
  40. vidhi-0.0.3/tests/test_cli_polymorphic.py +1408 -0
  41. vidhi-0.0.3/tests/test_examples.py +257 -0
  42. vidhi-0.0.3/tests/test_flat_dataclass.py +128 -0
  43. vidhi-0.0.3/tests/test_flat_dataclass_advanced.py +3336 -0
  44. vidhi-0.0.3/tests/test_frozen_dataclass.py +27 -0
  45. vidhi-0.0.3/tests/test_integration.py +488 -0
  46. vidhi-0.0.3/tests/test_schema.py +363 -0
  47. vidhi-0.0.3/tests/test_utils.py +487 -0
  48. vidhi-0.0.3/tests/test_vajra_config.py +2095 -0
  49. vidhi-0.0.3/vidhi/__init__.py +51 -0
  50. vidhi-0.0.3/vidhi/_version.py +34 -0
  51. vidhi-0.0.3/vidhi/base_poly_config.py +45 -0
  52. vidhi-0.0.3/vidhi/cli.py +331 -0
  53. vidhi-0.0.3/vidhi/cli_completion.py +541 -0
  54. vidhi-0.0.3/vidhi/cli_parser.py +1344 -0
  55. vidhi-0.0.3/vidhi/constants.py +182 -0
  56. vidhi-0.0.3/vidhi/flat_dataclass/__init__.py +22 -0
  57. vidhi-0.0.3/vidhi/flat_dataclass/cli.py +605 -0
  58. vidhi-0.0.3/vidhi/flat_dataclass/core.py +150 -0
  59. vidhi-0.0.3/vidhi/flat_dataclass/explosion.py +387 -0
  60. vidhi-0.0.3/vidhi/flat_dataclass/reconstruction.py +458 -0
  61. vidhi-0.0.3/vidhi/flat_dataclass/state.py +665 -0
  62. vidhi-0.0.3/vidhi/flat_dataclass/validation.py +423 -0
  63. vidhi-0.0.3/vidhi/frozen_dataclass.py +153 -0
  64. vidhi-0.0.3/vidhi/py.typed +0 -0
  65. vidhi-0.0.3/vidhi/schema.py +655 -0
  66. vidhi-0.0.3/vidhi/types.py +78 -0
  67. vidhi-0.0.3/vidhi/utils.py +635 -0
  68. vidhi-0.0.3/vidhi.egg-info/PKG-INFO +196 -0
  69. vidhi-0.0.3/vidhi.egg-info/SOURCES.txt +70 -0
  70. vidhi-0.0.3/vidhi.egg-info/dependency_links.txt +1 -0
  71. vidhi-0.0.3/vidhi.egg-info/requires.txt +16 -0
  72. vidhi-0.0.3/vidhi.egg-info/top_level.txt +1 -0
@@ -0,0 +1,56 @@
1
+ name: Deploy Documentation
2
+
3
+ on:
4
+ push:
5
+ branches: [main]
6
+ workflow_dispatch:
7
+
8
+ permissions:
9
+ contents: read
10
+ pages: write
11
+ id-token: write
12
+
13
+ concurrency:
14
+ group: "pages"
15
+ cancel-in-progress: false
16
+
17
+ jobs:
18
+ build:
19
+ runs-on: ubuntu-latest
20
+ steps:
21
+ - uses: actions/checkout@v4
22
+ with:
23
+ fetch-depth: 0
24
+
25
+ - name: Set up Python
26
+ uses: actions/setup-python@v5
27
+ with:
28
+ python-version: "3.12"
29
+ cache: "pip"
30
+
31
+ - name: Install dependencies
32
+ run: |
33
+ pip install --upgrade pip
34
+ pip install -e .
35
+ pip install -r docs/requirements.txt
36
+
37
+ - name: Build documentation
38
+ run: |
39
+ cd docs
40
+ make html
41
+
42
+ - name: Upload artifact
43
+ uses: actions/upload-pages-artifact@v3
44
+ with:
45
+ path: docs/_build/html
46
+
47
+ deploy:
48
+ environment:
49
+ name: github-pages
50
+ url: ${{ steps.deployment.outputs.page_url }}
51
+ runs-on: ubuntu-latest
52
+ needs: build
53
+ steps:
54
+ - name: Deploy to GitHub Pages
55
+ id: deployment
56
+ uses: actions/deploy-pages@v4
@@ -0,0 +1,40 @@
1
+ name: Lint
2
+
3
+ on:
4
+ push:
5
+ branches: [ main, dev ]
6
+ pull_request:
7
+ branches: [ main, dev ]
8
+
9
+ jobs:
10
+ lint:
11
+ runs-on: ubuntu-latest
12
+
13
+ steps:
14
+ - uses: actions/checkout@v4
15
+
16
+ - name: Set up Python
17
+ uses: actions/setup-python@v5
18
+ with:
19
+ python-version: "3.12"
20
+
21
+ - name: Install dependencies
22
+ run: |
23
+ python -m pip install --upgrade pip
24
+ pip install -e ".[dev]"
25
+
26
+ - name: Run black
27
+ run: |
28
+ black --check vidhi/ tests/
29
+
30
+ - name: Run isort
31
+ run: |
32
+ isort --check-only vidhi/ tests/
33
+
34
+ - name: Run pyright
35
+ run: |
36
+ pyright vidhi/
37
+
38
+ - name: Run codespell
39
+ run: |
40
+ codespell vidhi/ tests/ README.md
@@ -0,0 +1,51 @@
1
+ name: Publish Release to PyPI
2
+
3
+ on:
4
+ release:
5
+ types: [published]
6
+ workflow_dispatch:
7
+
8
+ permissions:
9
+ contents: read
10
+ id-token: write
11
+
12
+ env:
13
+ IS_NIGHTLY_BUILD: "false"
14
+
15
+ jobs:
16
+ build-and-publish:
17
+ runs-on: ubuntu-latest
18
+
19
+ steps:
20
+ - uses: actions/checkout@v4
21
+ with:
22
+ fetch-depth: 0 # Full history for setuptools_scm
23
+ fetch-tags: true
24
+ ref: ${{ github.event.release.tag_name || github.ref }}
25
+
26
+ - name: Set up Python
27
+ uses: actions/setup-python@v5
28
+ with:
29
+ python-version: "3.12"
30
+
31
+ - name: Install build dependencies
32
+ run: |
33
+ python -m pip install --upgrade pip
34
+ pip install build twine setuptools setuptools-scm wheel
35
+
36
+ - name: Verify version from tag
37
+ run: |
38
+ git describe --tags
39
+ python -c "from setuptools_scm import get_version; print('Version:', get_version())"
40
+
41
+ - name: Build distribution
42
+ run: |
43
+ python -m build
44
+
45
+ - name: Check distribution
46
+ run: |
47
+ twine check dist/*
48
+ ls -la dist/
49
+
50
+ - name: Publish to PyPI
51
+ uses: pypa/gh-action-pypi-publish@release/v1
@@ -0,0 +1,48 @@
1
+ name: Publish Nightly Build to PyPI
2
+
3
+ on:
4
+ # schedule:
5
+ # - cron: '0 6 * * *' # Runs at 06:00 UTC every day (DISABLED)
6
+ workflow_dispatch: # Manual trigger only
7
+
8
+ permissions:
9
+ contents: read
10
+ id-token: write
11
+
12
+ env:
13
+ IS_NIGHTLY_BUILD: "true"
14
+
15
+ jobs:
16
+ build-and-publish:
17
+ runs-on: ubuntu-latest
18
+
19
+ steps:
20
+ - uses: actions/checkout@v4
21
+ with:
22
+ fetch-depth: 0 # Full history for setuptools_scm
23
+ fetch-tags: true
24
+
25
+ - name: Set up Python
26
+ uses: actions/setup-python@v5
27
+ with:
28
+ python-version: "3.12"
29
+
30
+ - name: Install build dependencies
31
+ run: |
32
+ python -m pip install --upgrade pip
33
+ pip install build twine setuptools setuptools-scm wheel
34
+
35
+ - name: Build distribution
36
+ run: |
37
+ python -m build
38
+
39
+ - name: Check distribution
40
+ run: |
41
+ twine check dist/*
42
+ ls -la dist/
43
+
44
+ - name: Publish to Test PyPI
45
+ uses: pypa/gh-action-pypi-publish@release/v1
46
+ with:
47
+ repository-url: https://test.pypi.org/legacy/
48
+ skip-existing: true
@@ -0,0 +1,37 @@
1
+ name: Tests
2
+
3
+ on:
4
+ push:
5
+ branches: [ main, dev ]
6
+ pull_request:
7
+ branches: [ main, dev ]
8
+
9
+ jobs:
10
+ test:
11
+ runs-on: ubuntu-latest
12
+ strategy:
13
+ matrix:
14
+ python-version: ["3.12"]
15
+
16
+ steps:
17
+ - uses: actions/checkout@v4
18
+
19
+ - name: Set up Python ${{ matrix.python-version }}
20
+ uses: actions/setup-python@v5
21
+ with:
22
+ python-version: ${{ matrix.python-version }}
23
+
24
+ - name: Install dependencies
25
+ run: |
26
+ python -m pip install --upgrade pip
27
+ pip install -e ".[dev]"
28
+
29
+ - name: Run tests with pytest
30
+ run: |
31
+ pytest tests/ -v --cov=vidhi --cov-report=xml --cov-report=term
32
+
33
+ - name: Upload coverage to Codecov
34
+ uses: codecov/codecov-action@v4
35
+ with:
36
+ file: ./coverage.xml
37
+ fail_ci_if_error: false
vidhi-0.0.3/.gitignore ADDED
@@ -0,0 +1,92 @@
1
+ # Byte-compiled / optimized / DLL files
2
+ __pycache__/
3
+ *.py[cod]
4
+ *$py.class
5
+
6
+ # C extensions
7
+ *.so
8
+
9
+ # Distribution / packaging
10
+ .Python
11
+ build/
12
+ develop-eggs/
13
+ dist/
14
+ downloads/
15
+ eggs/
16
+ .eggs/
17
+ lib/
18
+ lib64/
19
+ parts/
20
+ sdist/
21
+ var/
22
+ wheels/
23
+ *.egg-info/
24
+ .installed.cfg
25
+ *.egg
26
+
27
+ # PyInstaller
28
+ *.manifest
29
+ *.spec
30
+
31
+ # Installer logs
32
+ pip-log.txt
33
+ pip-delete-this-directory.txt
34
+
35
+ # Unit test / coverage reports
36
+ htmlcov/
37
+ .tox/
38
+ .nox/
39
+ .coverage
40
+ .coverage.*
41
+ .cache
42
+ nosetests.xml
43
+ coverage.xml
44
+ *.cover
45
+ *.py,cover
46
+ .hypothesis/
47
+ .pytest_cache/
48
+
49
+ # Translations
50
+ *.mo
51
+ *.pot
52
+
53
+ # Environments
54
+ .env
55
+ .venv
56
+ env/
57
+ venv/
58
+ ENV/
59
+ env.bak/
60
+ venv.bak/
61
+
62
+ # IDE
63
+ .idea/
64
+ .vscode/
65
+ *.swp
66
+ *.swo
67
+ *~
68
+
69
+ # Jupyter Notebook
70
+ .ipynb_checkpoints
71
+
72
+ # pyenv
73
+ .python-version
74
+
75
+ # mypy
76
+ .mypy_cache/
77
+ .dmypy.json
78
+ dmypy.json
79
+
80
+ # Pyright
81
+ .pyright/
82
+
83
+ # OS
84
+ .DS_Store
85
+ Thumbs.db
86
+
87
+ # Project-specific
88
+ *.log
89
+ docs/_build/
90
+ test_reports/
91
+ .claude/
92
+ vidhi/_version.py
@@ -0,0 +1,19 @@
1
+ # .readthedocs.yaml
2
+ # Read the Docs configuration file
3
+ # See https://docs.readthedocs.io/en/stable/config-file/v2.html for details
4
+
5
+ version: 2
6
+
7
+ build:
8
+ os: ubuntu-22.04
9
+ tools:
10
+ python: "3.12"
11
+
12
+ sphinx:
13
+ configuration: docs/conf.py
14
+
15
+ python:
16
+ install:
17
+ - requirements: docs/requirements.txt
18
+ - method: pip
19
+ path: .
@@ -0,0 +1,108 @@
1
+ # Contributing to Vidhi
2
+
3
+ Thank you for your interest in contributing to Vidhi! This document provides guidelines for contributing to the project.
4
+
5
+ ## Getting Started
6
+
7
+ ### Development Setup
8
+
9
+ 1. Clone the repository:
10
+ ```bash
11
+ git clone https://github.com/project-vajra/vidhi.git
12
+ cd vidhi
13
+ ```
14
+
15
+ 2. Install development dependencies:
16
+ ```bash
17
+ pip install -e ".[dev]"
18
+ ```
19
+
20
+ 3. Install pre-commit hooks:
21
+ ```bash
22
+ pre-commit install
23
+ ```
24
+
25
+ ### Running Tests
26
+
27
+ ```bash
28
+ # Run all tests
29
+ make test
30
+
31
+ # Run with coverage
32
+ make test-cov
33
+
34
+ # Run specific test file
35
+ pytest tests/test_frozen_dataclass.py -v
36
+ ```
37
+
38
+ ### Code Formatting
39
+
40
+ ```bash
41
+ # Format code
42
+ make format
43
+
44
+ # Run linters
45
+ make lint
46
+ ```
47
+
48
+ ## How to Contribute
49
+
50
+ ### Reporting Bugs
51
+
52
+ 1. Check if the issue already exists in [GitHub Issues](https://github.com/project-vajra/vidhi/issues)
53
+ 2. If not, create a new issue with:
54
+ - A clear, descriptive title
55
+ - Steps to reproduce the bug
56
+ - Expected vs actual behavior
57
+ - Python version and OS
58
+ - Minimal code example if possible
59
+
60
+ ### Suggesting Features
61
+
62
+ 1. Open a new issue describing:
63
+ - The problem you're trying to solve
64
+ - Your proposed solution
65
+ - Any alternatives you've considered
66
+
67
+ ### Submitting Pull Requests
68
+
69
+ 1. Fork the repository
70
+ 2. Create a feature branch from `main`
71
+ 3. Make your changes
72
+ 4. Ensure all tests pass
73
+ 5. Run `make format` and `make lint`
74
+ 6. Submit a pull request
75
+
76
+ #### Pull Request Guidelines
77
+
78
+ - Keep PRs focused on a single change
79
+ - Write clear commit messages
80
+ - Add tests for new functionality
81
+ - Update documentation as needed
82
+ - Follow the existing code style
83
+
84
+ ## Code Style
85
+
86
+ - Use [Black](https://github.com/psf/black) for formatting
87
+ - Use [isort](https://pycqa.github.io/isort/) for import sorting
88
+ - Follow PEP 8 guidelines
89
+ - Add type hints to all functions
90
+ - Write docstrings for public functions
91
+
92
+ ## Testing
93
+
94
+ - Write tests for all new functionality
95
+ - Maintain or improve test coverage
96
+ - Use pytest for testing
97
+ - Keep tests focused and readable
98
+
99
+ ## Documentation
100
+
101
+ - Update README.md for user-facing changes
102
+ - Update docs/USER_GUIDE.md for new features
103
+ - Add docstrings to new functions/classes
104
+ - Include code examples where helpful
105
+
106
+ ## Questions?
107
+
108
+ Feel free to open an issue for any questions about contributing.
vidhi-0.0.3/LICENSE ADDED
@@ -0,0 +1,201 @@
1
+ Apache License
2
+ Version 2.0, January 2004
3
+ http://www.apache.org/licenses/
4
+
5
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
6
+
7
+ 1. Definitions.
8
+
9
+ "License" shall mean the terms and conditions for use, reproduction,
10
+ and distribution as defined by Sections 1 through 9 of this document.
11
+
12
+ "Licensor" shall mean the copyright owner or entity authorized by
13
+ the copyright owner that is granting the License.
14
+
15
+ "Legal Entity" shall mean the union of the acting entity and all
16
+ other entities that control, are controlled by, or are under common
17
+ control with that entity. For the purposes of this definition,
18
+ "control" means (i) the power, direct or indirect, to cause the
19
+ direction or management of such entity, whether by contract or
20
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
21
+ outstanding shares, or (iii) beneficial ownership of such entity.
22
+
23
+ "You" (or "Your") shall mean an individual or Legal Entity
24
+ exercising permissions granted by this License.
25
+
26
+ "Source" form shall mean the preferred form for making modifications,
27
+ including but not limited to software source code, documentation
28
+ source, and configuration files.
29
+
30
+ "Object" form shall mean any form resulting from mechanical
31
+ transformation or translation of a Source form, including but
32
+ not limited to compiled object code, generated documentation,
33
+ and conversions to other media types.
34
+
35
+ "Work" shall mean the work of authorship, whether in Source or
36
+ Object form, made available under the License, as indicated by a
37
+ copyright notice that is included in or attached to the work
38
+ (an example is provided in the Appendix below).
39
+
40
+ "Derivative Works" shall mean any work, whether in Source or Object
41
+ form, that is based on (or derived from) the Work and for which the
42
+ editorial revisions, annotations, elaborations, or other modifications
43
+ represent, as a whole, an original work of authorship. For the purposes
44
+ of this License, Derivative Works shall not include works that remain
45
+ separable from, or merely link (or bind by name) to the interfaces of,
46
+ the Work and Derivative Works thereof.
47
+
48
+ "Contribution" shall mean any work of authorship, including
49
+ the original version of the Work and any modifications or additions
50
+ to that Work or Derivative Works thereof, that is intentionally
51
+ submitted to Licensor for inclusion in the Work by the copyright owner
52
+ or by an individual or Legal Entity authorized to submit on behalf of
53
+ the copyright owner. For the purposes of this definition, "submitted"
54
+ means any form of electronic, verbal, or written communication sent
55
+ to the Licensor or its representatives, including but not limited to
56
+ communication on electronic mailing lists, source code control systems,
57
+ and issue tracking systems that are managed by, or on behalf of, the
58
+ Licensor for the purpose of discussing and improving the Work, but
59
+ excluding communication that is conspicuously marked or otherwise
60
+ designated in writing by the copyright owner as "Not a Contribution."
61
+
62
+ "Contributor" shall mean Licensor and any individual or Legal Entity
63
+ on behalf of whom a Contribution has been received by Licensor and
64
+ subsequently incorporated within the Work.
65
+
66
+ 2. Grant of Copyright License. Subject to the terms and conditions of
67
+ this License, each Contributor hereby grants to You a perpetual,
68
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
69
+ copyright license to reproduce, prepare Derivative Works of,
70
+ publicly display, publicly perform, sublicense, and distribute the
71
+ Work and such Derivative Works in Source or Object form.
72
+
73
+ 3. Grant of Patent License. Subject to the terms and conditions of
74
+ this License, each Contributor hereby grants to You a perpetual,
75
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
76
+ (except as stated in this section) patent license to make, have made,
77
+ use, offer to sell, sell, import, and otherwise transfer the Work,
78
+ where such license applies only to those patent claims licensable
79
+ by such Contributor that are necessarily infringed by their
80
+ Contribution(s) alone or by combination of their Contribution(s)
81
+ with the Work to which such Contribution(s) was submitted. If You
82
+ institute patent litigation against any entity (including a
83
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
84
+ or a Contribution incorporated within the Work constitutes direct
85
+ or contributory patent infringement, then any patent licenses
86
+ granted to You under this License for that Work shall terminate
87
+ as of the date such litigation is filed.
88
+
89
+ 4. Redistribution. You may reproduce and distribute copies of the
90
+ Work or Derivative Works thereof in any medium, with or without
91
+ modifications, and in Source or Object form, provided that You
92
+ meet the following conditions:
93
+
94
+ (a) You must give any other recipients of the Work or
95
+ Derivative Works a copy of this License; and
96
+
97
+ (b) You must cause any modified files to carry prominent notices
98
+ stating that You changed the files; and
99
+
100
+ (c) You must retain, in the Source form of any Derivative Works
101
+ that You distribute, all copyright, patent, trademark, and
102
+ attribution notices from the Source form of the Work,
103
+ excluding those notices that do not pertain to any part of
104
+ the Derivative Works; and
105
+
106
+ (d) If the Work includes a "NOTICE" text file as part of its
107
+ distribution, then any Derivative Works that You distribute must
108
+ include a readable copy of the attribution notices contained
109
+ within such NOTICE file, excluding those notices that do not
110
+ pertain to any part of the Derivative Works, in at least one
111
+ of the following places: within a NOTICE text file distributed
112
+ as part of the Derivative Works; within the Source form or
113
+ documentation, if provided along with the Derivative Works; or,
114
+ within a display generated by the Derivative Works, if and
115
+ wherever such third-party notices normally appear. The contents
116
+ of the NOTICE file are for informational purposes only and
117
+ do not modify the License. You may add Your own attribution
118
+ notices within Derivative Works that You distribute, alongside
119
+ or as an addendum to the NOTICE text from the Work, provided
120
+ that such additional attribution notices cannot be construed
121
+ as modifying the License.
122
+
123
+ You may add Your own copyright statement to Your modifications and
124
+ may provide additional or different license terms and conditions
125
+ for use, reproduction, or distribution of Your modifications, or
126
+ for any such Derivative Works as a whole, provided Your use,
127
+ reproduction, and distribution of the Work otherwise complies with
128
+ the conditions stated in this License.
129
+
130
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
131
+ any Contribution intentionally submitted for inclusion in the Work
132
+ by You to the Licensor shall be under the terms and conditions of
133
+ this License, without any additional terms or conditions.
134
+ Notwithstanding the above, nothing herein shall supersede or modify
135
+ the terms of any separate license agreement you may have executed
136
+ with Licensor regarding such Contributions.
137
+
138
+ 6. Trademarks. This License does not grant permission to use the trade
139
+ names, trademarks, service marks, or product names of the Licensor,
140
+ except as required for reasonable and customary use in describing the
141
+ origin of the Work and reproducing the content of the NOTICE file.
142
+
143
+ 7. Disclaimer of Warranty. Unless required by applicable law or
144
+ agreed to in writing, Licensor provides the Work (and each
145
+ Contributor provides its Contributions) on an "AS IS" BASIS,
146
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
147
+ implied, including, without limitation, any warranties or conditions
148
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
149
+ PARTICULAR PURPOSE. You are solely responsible for determining the
150
+ appropriateness of using or redistributing the Work and assume any
151
+ risks associated with Your exercise of permissions under this License.
152
+
153
+ 8. Limitation of Liability. In no event and under no legal theory,
154
+ whether in tort (including negligence), contract, or otherwise,
155
+ unless required by applicable law (such as deliberate and grossly
156
+ negligent acts) or agreed to in writing, shall any Contributor be
157
+ liable to You for damages, including any direct, indirect, special,
158
+ incidental, or consequential damages of any character arising as a
159
+ result of this License or out of the use or inability to use the
160
+ Work (including but not limited to damages for loss of goodwill,
161
+ work stoppage, computer failure or malfunction, or any and all
162
+ other commercial damages or losses), even if such Contributor
163
+ has been advised of the possibility of such damages.
164
+
165
+ 9. Accepting Warranty or Additional Liability. While redistributing
166
+ the Work or Derivative Works thereof, You may choose to offer,
167
+ and charge a fee for, acceptance of support, warranty, indemnity,
168
+ or other liability obligations and/or rights consistent with this
169
+ License. However, in accepting such obligations, You may act only
170
+ on Your own behalf and on Your sole responsibility, not on behalf
171
+ of any other Contributor, and only if You agree to indemnify,
172
+ defend, and hold each Contributor harmless for any liability
173
+ incurred by, or claims asserted against, such Contributor by reason
174
+ of your accepting any such warranty or additional liability.
175
+
176
+ END OF TERMS AND CONDITIONS
177
+
178
+ APPENDIX: How to apply the Apache License to your work.
179
+
180
+ To apply the Apache License to your work, attach the following
181
+ boilerplate notice, with the fields enclosed by brackets "[]"
182
+ replaced with your own identifying information. (Don't include
183
+ the brackets!) The text should be enclosed in the appropriate
184
+ comment syntax for the file format. We also recommend that a
185
+ file or class name and description of purpose be included on the
186
+ same "printed page" as the copyright notice for easier
187
+ identification within third-party archives.
188
+
189
+ Copyright 2025 Vajra Team
190
+
191
+ Licensed under the Apache License, Version 2.0 (the "License");
192
+ you may not use this file except in compliance with the License.
193
+ You may obtain a copy of the License at
194
+
195
+ http://www.apache.org/licenses/LICENSE-2.0
196
+
197
+ Unless required by applicable law or agreed to in writing, software
198
+ distributed under the License is distributed on an "AS IS" BASIS,
199
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
200
+ See the License for the specific language governing permissions and
201
+ limitations under the License.