Skip to content

Commit d188bad

Browse files
authored
Merge pull request #1244 from guardrails-ai/jsonschema-nongpl-extra
Update to jsonschema's format-nongpl extra
2 parents 279f57f + 9a53f8a commit d188bad

File tree

3 files changed

+115
-20
lines changed

3 files changed

+115
-20
lines changed

.github/workflows/ci.yml

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,34 @@ on:
1616
workflow_dispatch:
1717

1818
jobs:
19+
LicenseChecks:
20+
runs-on: ubuntu-latest
21+
strategy:
22+
matrix:
23+
python-version: ["3.9", "3.10", "3.11", "3.12"]
24+
steps:
25+
- uses: actions/checkout@v4
26+
- name: Set up Python ${{ matrix.python-version }}
27+
uses: actions/setup-python@v5
28+
with:
29+
python-version: ${{ matrix.python-version }}
30+
31+
- name: Install Poetry
32+
uses: snok/install-poetry@v1
33+
34+
- name: Install Dependencies
35+
# TODO: fix errors so that we can run `make dev` instead
36+
run: |
37+
# Setup Virtual Environment
38+
python3 -m venv ./.venv
39+
source .venv/bin/activate
40+
poetry install
41+
42+
- name: Check license
43+
run: |
44+
source .venv/bin/activate
45+
.venv/bin/pip install greenlet
46+
.venv/bin/liccheck
1947
Linting:
2048
runs-on: ubuntu-latest
2149
strategy:

poetry.lock

Lines changed: 44 additions & 18 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pyproject.toml

Lines changed: 43 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[tool.poetry]
22
name = "guardrails-ai"
3-
version = "0.6.4"
3+
version = "0.6.5"
44
description = "Adding guardrails to large language models."
55
authors = ["Guardrails AI <[email protected]>"]
66
license = "Apache License 2.0"
@@ -46,7 +46,7 @@ requests = "^2.31.0"
4646
faker = "^25.2.0"
4747
jsonref = "^1.1.0"
4848
jsonformer = {version = "0.12.0", optional = true}
49-
jsonschema = {version = "^4.22.0", extras = ["format"]}
49+
jsonschema = {version = "^4.22.0", extras = ["format-nongpl"]}
5050
pip = ">=22"
5151
pyjwt = "^2.8.0"
5252
opentelemetry-sdk = "^1.24.0"
@@ -87,6 +87,8 @@ pypdfium2 = "^4.23.1"
8787
pyright = "1.1.334"
8888
lxml-stubs = "^0.4.0"
8989
ruff = ">=0.4.1"
90+
liccheck = "^0.9.2"
91+
9092

9193
[tool.poetry.group.api]
9294
optional = true
@@ -132,3 +134,42 @@ markers = [
132134
[pytest]
133135
log_cli = "True"
134136
log_cli_level = "DEBUG"
137+
138+
139+
[tool.liccheck]
140+
authorized_licenses = [
141+
"3-clause bsd",
142+
"bsd",
143+
"new bsd",
144+
"bsd license",
145+
"new bsd license",
146+
"simplified bsd",
147+
"academic free license (afl)",
148+
"apache",
149+
"apache 2.0",
150+
"apache software",
151+
"apache software license",
152+
"gnu lgpl",
153+
"lgpl with exceptions or zpl",
154+
"gnu library or lesser general public license (lgpl)",
155+
"isc",
156+
"isc license",
157+
"isc license (iscl)",
158+
"mit",
159+
"mit license",
160+
"mozilla public license 2.0 (mpl 2.0)",
161+
"the unlicense (unlicense)",
162+
"python software foundation",
163+
"python software foundation license",
164+
"zpl 2.1",
165+
]
166+
unauthorized_licenses = [
167+
"gpl v3",
168+
]
169+
level = "Paranoid"
170+
dependencies = true # to load [tool.poetry.dependencies]
171+
172+
[tool.liccheck.authorized_packages]
173+
aiocache = "0.12.3" # BSD 3-Clause
174+
aiohappyeyeballs = "2.4.3" # Python Software Foundation
175+
guardrails-api = "*" # Modified ELSSTIC

0 commit comments

Comments
 (0)