--- Begin Message ---
Source: sqlmodel
Version: 0.0.8-4
Severity: serious
Justification: FTBFS
Tags: trixie sid ftbfs
User: lu...@debian.org
Usertags: ftbfs-20230726 ftbfs-trixie
Hi,
During a rebuild of all packages in sid, your package failed to build
on amd64.
Relevant part (hopefully):
> make[1]: Entering directory '/<<PKGBUILDDIR>>'
> # test_create_db_and_table: converage cant find docs_src so this test fails
> PYBUILD_SYSTEM=custom PYBUILD_TEST_ARGS="PYTHONPATH=/<<PKGBUILDDIR>>
> {interpreter} -m pytest -k 'not test_create_db_and_table' " dh_auto_test
> pybuild --test --test-pytest -i python{version} -p 3.11
> I: pybuild base:240: PYTHONPATH=/<<PKGBUILDDIR>> python3.11 -m pytest -k 'not
> test_create_db_and_table'
> ============================= test session starts
> ==============================
> platform linux -- Python 3.11.4, pytest-7.4.0, pluggy-1.2.0
> rootdir: /<<PKGBUILDDIR>>
> plugins: anyio-3.7.0
> collected 125 items / 3 deselected / 122 selected
>
> docs_src/tutorial/fastapi/app_testing/tutorial001/test_main.py ....... [
> 5%]
> docs_src/tutorial/fastapi/app_testing/tutorial001/test_main_001.py . [
> 6%]
> docs_src/tutorial/fastapi/app_testing/tutorial001/test_main_002.py . [
> 7%]
> docs_src/tutorial/fastapi/app_testing/tutorial001/test_main_003.py . [
> 8%]
> docs_src/tutorial/fastapi/app_testing/tutorial001/test_main_004.py . [
> 9%]
> docs_src/tutorial/fastapi/app_testing/tutorial001/test_main_005.py . [
> 9%]
> docs_src/tutorial/fastapi/app_testing/tutorial001/test_main_006.py . [
> 10%]
> tests/test_default.py .... [
> 13%]
> tests/test_enums.py .. [
> 15%]
> tests/test_fields_set.py . [
> 16%]
> tests/test_instance_no_args.py . [
> 17%]
> tests/test_main.py ... [
> 19%]
> tests/test_missing_type.py . [
> 20%]
> tests/test_nullable.py ... [
> 22%]
> tests/test_query.py . [
> 23%]
> tests/test_validation.py . [
> 24%]
> tests/test_advanced/test_decimal/test_tutorial001.py . [
> 25%]
> tests/test_tutorial/test_automatic_id_none_refresh/test_tutorial001_tutorial002.py
> . [ 26%]
> . [
> 27%]
> tests/test_tutorial/test_code_structure/test_tutorial001.py . [
> 27%]
> tests/test_tutorial/test_code_structure/test_tutorial002.py . [
> 28%]
> tests/test_tutorial/test_connect/test_create_connected_tables/test_tutorial001.py
> . [ 29%]
> [
> 29%]
> tests/test_tutorial/test_connect/test_delete/test_tutorial001.py . [
> 30%]
> tests/test_tutorial/test_connect/test_insert/test_tutorial001.py . [
> 31%]
> tests/test_tutorial/test_connect/test_select/test_tutorial001_tutorial002.py
> . [ 31%]
> . [
> 32%]
> tests/test_tutorial/test_connect/test_select/test_tutorial003.py . [
> 33%]
> tests/test_tutorial/test_connect/test_select/test_tutorial004.py . [
> 34%]
> tests/test_tutorial/test_connect/test_select/test_tutorial005.py . [
> 35%]
> tests/test_tutorial/test_connect/test_update/test_tutorial001.py . [
> 36%]
> tests/test_tutorial/test_delete/test_tutorial001_tutorial002.py .. [
> 37%]
> tests/test_tutorial/test_fastapi/test_app_testing/test_tutorial001_tests001.py
> . [ 38%]
> [
> 38%]
> tests/test_tutorial/test_fastapi/test_app_testing/test_tutorial001_tests002.py
> . [ 39%]
> [
> 39%]
> tests/test_tutorial/test_fastapi/test_app_testing/test_tutorial001_tests003.py
> . [ 40%]
> [
> 40%]
> tests/test_tutorial/test_fastapi/test_app_testing/test_tutorial001_tests004.py
> . [ 40%]
> [
> 40%]
> tests/test_tutorial/test_fastapi/test_app_testing/test_tutorial001_tests005.py
> . [ 41%]
> [
> 41%]
> tests/test_tutorial/test_fastapi/test_app_testing/test_tutorial001_tests006.py
> . [ 42%]
> [
> 42%]
> tests/test_tutorial/test_fastapi/test_app_testing/test_tutorial001_tests_main.py
> . [ 43%]
> ........... [
> 52%]
> tests/test_tutorial/test_fastapi/test_delete/test_tutorial001.py F [
> 53%]
> tests/test_tutorial/test_fastapi/test_limit_and_offset/test_tutorial001.py F
> [ 54%]
> [
> 54%]
> tests/test_tutorial/test_fastapi/test_multiple_models/test_tutorial001.py F [
> 54%]
> [
> 54%]
> tests/test_tutorial/test_fastapi/test_multiple_models/test_tutorial002.py F [
> 55%]
> [
> 55%]
> tests/test_tutorial/test_fastapi/test_read_one/test_tutorial001.py F [
> 56%]
> tests/test_tutorial/test_fastapi/test_relationships/test_tutorial001.py F [
> 57%]
> [
> 57%]
> tests/test_tutorial/test_fastapi/test_response_model/test_tutorial001.py F [
> 58%]
> [
> 58%]
> tests/test_tutorial/test_fastapi/test_session_with_dependency/test_tutorial001.py
> F [ 59%]
> [
> 59%]
> tests/test_tutorial/test_fastapi/test_simple_hero_api/test_tutorial001.py F [
> 59%]
> [
> 59%]
> tests/test_tutorial/test_fastapi/test_teams/test_tutorial001.py F [
> 60%]
> tests/test_tutorial/test_fastapi/test_update/test_tutorial001.py F [
> 61%]
> tests/test_tutorial/test_indexes/test_tutorial001.py . [
> 62%]
> tests/test_tutorial/test_indexes/test_tutorial006.py . [
> 63%]
> tests/test_tutorial/test_insert/test_tutorial001.py . [
> 63%]
> tests/test_tutorial/test_insert/test_tutorial002.py . [
> 64%]
> tests/test_tutorial/test_insert/test_tutorial003.py . [
> 65%]
> tests/test_tutorial/test_limit_and_offset/test_tutorial001.py . [
> 66%]
> tests/test_tutorial/test_limit_and_offset/test_tutorial002.py . [
> 67%]
> tests/test_tutorial/test_limit_and_offset/test_tutorial003.py . [
> 68%]
> tests/test_tutorial/test_limit_and_offset/test_tutorial004.py . [
> 68%]
> tests/test_tutorial/test_many_to_many/test_tutorial001.py . [
> 69%]
> tests/test_tutorial/test_many_to_many/test_tutorial002.py . [
> 70%]
> tests/test_tutorial/test_many_to_many/test_tutorial003.py . [
> 71%]
> tests/test_tutorial/test_one/test_tutorial001.py . [
> 72%]
> tests/test_tutorial/test_one/test_tutorial002.py . [
> 72%]
> tests/test_tutorial/test_one/test_tutorial003.py . [
> 73%]
> tests/test_tutorial/test_one/test_tutorial004.py . [
> 74%]
> tests/test_tutorial/test_one/test_tutorial005.py . [
> 75%]
> tests/test_tutorial/test_one/test_tutorial006.py . [
> 76%]
> tests/test_tutorial/test_one/test_tutorial007.py . [
> 77%]
> tests/test_tutorial/test_one/test_tutorial008.py . [
> 77%]
> tests/test_tutorial/test_one/test_tutorial009.py . [
> 78%]
> tests/test_tutorial/test_relationship_attributes/test_back_populates/test_tutorial001.py
> . [ 79%]
> [
> 79%]
> tests/test_tutorial/test_relationship_attributes/test_back_populates/test_tutorial002.py
> . [ 80%]
> [
> 80%]
> tests/test_tutorial/test_relationship_attributes/test_back_populates/test_tutorial003.py
> . [ 81%]
> [
> 81%]
> tests/test_tutorial/test_relationship_attributes/test_create_and_update_relationships/test_tutorial001.py
> . [ 81%]
> [
> 81%]
> tests/test_tutorial/test_relationship_attributes/test_define_relationship_attributes/test_tutorial001.py
> . [ 82%]
> [
> 82%]
> tests/test_tutorial/test_relationship_attributes/test_read_relationships/test_tutorial001.py
> . [ 83%]
> [
> 83%]
> tests/test_tutorial/test_relationship_attributes/test_read_relationships/test_tutorial002.py
> . [ 84%]
> [
> 84%]
> tests/test_tutorial/test_select/test_tutorial001_tutorial002.py .. [
> 86%]
> tests/test_tutorial/test_select/test_tutorial003_tutorial004.py .. [
> 87%]
> tests/test_tutorial/test_update/test_tutorial001_tutorial002.py .. [
> 89%]
> tests/test_tutorial/test_update/test_tutorial003_tutorial004.py .. [
> 90%]
> tests/test_tutorial/test_where/test_tutorial001.py . [
> 91%]
> tests/test_tutorial/test_where/test_tutorial002.py . [
> 92%]
> tests/test_tutorial/test_where/test_tutorial003.py . [
> 93%]
> tests/test_tutorial/test_where/test_tutorial004.py . [
> 94%]
> tests/test_tutorial/test_where/test_tutorial005.py . [
> 95%]
> tests/test_tutorial/test_where/test_tutorial006.py . [
> 95%]
> tests/test_tutorial/test_where/test_tutorial007.py . [
> 96%]
> tests/test_tutorial/test_where/test_tutorial008.py . [
> 97%]
> tests/test_tutorial/test_where/test_tutorial009.py . [
> 98%]
> tests/test_tutorial/test_where/test_tutorial010.py . [
> 99%]
> tests/test_tutorial/test_where/test_tutorial011.py .
> [100%]
>
> =================================== FAILURES
> ===================================
> ________________________________ test_tutorial
> _________________________________
>
> clear_sqlmodel = None
>
> def test_tutorial(clear_sqlmodel):
> from docs_src.tutorial.fastapi.delete import tutorial001 as mod
>
> mod.sqlite_url = "sqlite://"
> mod.engine = create_engine(
> mod.sqlite_url, connect_args=mod.connect_args,
> poolclass=StaticPool
> )
>
> with TestClient(mod.app) as client:
>
> hero1_data = {"name": "Deadpond", "secret_name": "Dive Wilson"}
> hero2_data = {
> "name": "Spider-Boy",
> "secret_name": "Pedro Parqueador",
> "id": 9000,
> }
> hero3_data = {
> "name": "Rusty-Man",
> "secret_name": "Tommy Sharp",
> "age": 48,
> }
> response = client.post("/heroes/", json=hero1_data)
> assert response.status_code == 200, response.text
> response = client.post("/heroes/", json=hero2_data)
> assert response.status_code == 200, response.text
> hero2 = response.json()
> hero2_id = hero2["id"]
> response = client.post("/heroes/", json=hero3_data)
> assert response.status_code == 200, response.text
> response = client.get(f"/heroes/{hero2_id}")
> assert response.status_code == 200, response.text
> response = client.get("/heroes/9000")
> assert response.status_code == 404, response.text
> response = client.get("/openapi.json")
> data = response.json()
> assert response.status_code == 200, response.text
> > assert data == openapi_schema
> E AssertionError: assert {'components'...or'}}, ...}}}} ==
> {'components'...or'}}, ...}}}}
> E Omitting 3 identical items, use -vv to show
> E Differing items:
> E {'openapi': '3.1.0'} != {'openapi': '3.0.2'}
> E Use -v to get more diff
>
> tests/test_tutorial/test_fastapi/test_delete/test_tutorial001.py:291:
> AssertionError
> ________________________________ test_tutorial
> _________________________________
>
> clear_sqlmodel = None
>
> def test_tutorial(clear_sqlmodel):
> from docs_src.tutorial.fastapi.limit_and_offset import tutorial001 as
> mod
>
> mod.sqlite_url = "sqlite://"
> mod.engine = create_engine(
> mod.sqlite_url, connect_args=mod.connect_args,
> poolclass=StaticPool
> )
>
> with TestClient(mod.app) as client:
>
> hero1_data = {"name": "Deadpond", "secret_name": "Dive Wilson"}
> hero2_data = {
> "name": "Spider-Boy",
> "secret_name": "Pedro Parqueador",
> "id": 9000,
> }
> hero3_data = {
> "name": "Rusty-Man",
> "secret_name": "Tommy Sharp",
> "age": 48,
> }
> response = client.post("/heroes/", json=hero1_data)
> assert response.status_code == 200, response.text
> response = client.post("/heroes/", json=hero2_data)
> assert response.status_code == 200, response.text
> hero2 = response.json()
> hero_id = hero2["id"]
> response = client.post("/heroes/", json=hero3_data)
> assert response.status_code == 200, response.text
> response = client.get(f"/heroes/{hero_id}")
> assert response.status_code == 200, response.text
> response = client.get("/heroes/9000")
> assert response.status_code == 404, response.text
> response = client.get("/openapi.json")
> data = response.json()
> assert response.status_code == 200, response.text
> > assert data == openapi_schema
> E AssertionError: assert {'components'...Read Hero'}}}} ==
> {'components'...Read Hero'}}}}
> E Omitting 3 identical items, use -vv to show
> E Differing items:
> E {'openapi': '3.1.0'} != {'openapi': '3.0.2'}
> E Use -v to get more diff
>
> tests/test_tutorial/test_fastapi/test_limit_and_offset/test_tutorial001.py:214:
> AssertionError
> ________________________________ test_tutorial
> _________________________________
>
> clear_sqlmodel = None
>
> def test_tutorial(clear_sqlmodel):
> from docs_src.tutorial.fastapi.multiple_models import tutorial001 as
> mod
>
> mod.sqlite_url = "sqlite://"
> mod.engine = create_engine(
> mod.sqlite_url, connect_args=mod.connect_args,
> poolclass=StaticPool
> )
>
> with TestClient(mod.app) as client:
>
> hero1_data = {"name": "Deadpond", "secret_name": "Dive Wilson"}
> hero2_data = {
> "name": "Spider-Boy",
> "secret_name": "Pedro Parqueador",
> "id": 9000,
> }
> response = client.post("/heroes/", json=hero1_data)
> data = response.json()
>
> assert response.status_code == 200, response.text
> assert data["name"] == hero1_data["name"]
> assert data["secret_name"] == hero1_data["secret_name"]
> assert data["id"] is not None
> assert data["age"] is None
>
> response = client.post("/heroes/", json=hero2_data)
> data = response.json()
>
> assert response.status_code == 200, response.text
> assert data["name"] == hero2_data["name"]
> assert data["secret_name"] == hero2_data["secret_name"]
> assert data["id"] != hero2_data["id"], (
> "Now it's not possible to predefine the ID from the request, "
> "it's now set by the database"
> )
> assert data["age"] is None
>
> response = client.get("/heroes/")
> data = response.json()
>
> assert response.status_code == 200, response.text
> assert len(data) == 2
> assert data[0]["name"] == hero1_data["name"]
> assert data[0]["secret_name"] == hero1_data["secret_name"]
> assert data[1]["name"] == hero2_data["name"]
> assert data[1]["secret_name"] == hero2_data["secret_name"]
> assert data[1]["id"] != hero2_data["id"]
>
> response = client.get("/openapi.json")
> data = response.json()
>
> assert response.status_code == 200, response.text
>
> > assert data == openapi_schema
> E AssertionError: assert {'components'...eate Hero'}}}} ==
> {'components'...eate Hero'}}}}
> E Omitting 3 identical items, use -vv to show
> E Differing items:
> E {'openapi': '3.1.0'} != {'openapi': '3.0.2'}
> E Use -v to get more diff
>
> tests/test_tutorial/test_fastapi/test_multiple_models/test_tutorial001.py:170:
> AssertionError
> ________________________________ test_tutorial
> _________________________________
>
> clear_sqlmodel = None
>
> def test_tutorial(clear_sqlmodel):
> from docs_src.tutorial.fastapi.multiple_models import tutorial002 as
> mod
>
> mod.sqlite_url = "sqlite://"
> mod.engine = create_engine(
> mod.sqlite_url, connect_args=mod.connect_args,
> poolclass=StaticPool
> )
>
> with TestClient(mod.app) as client:
>
> hero1_data = {"name": "Deadpond", "secret_name": "Dive Wilson"}
> hero2_data = {
> "name": "Spider-Boy",
> "secret_name": "Pedro Parqueador",
> "id": 9000,
> }
> response = client.post("/heroes/", json=hero1_data)
> data = response.json()
>
> assert response.status_code == 200, response.text
> assert data["name"] == hero1_data["name"]
> assert data["secret_name"] == hero1_data["secret_name"]
> assert data["id"] is not None
> assert data["age"] is None
>
> response = client.post("/heroes/", json=hero2_data)
> data = response.json()
>
> assert response.status_code == 200, response.text
> assert data["name"] == hero2_data["name"]
> assert data["secret_name"] == hero2_data["secret_name"]
> assert data["id"] != hero2_data["id"], (
> "Now it's not possible to predefine the ID from the request, "
> "it's now set by the database"
> )
> assert data["age"] is None
>
> response = client.get("/heroes/")
> data = response.json()
>
> assert response.status_code == 200, response.text
> assert len(data) == 2
> assert data[0]["name"] == hero1_data["name"]
> assert data[0]["secret_name"] == hero1_data["secret_name"]
> assert data[1]["name"] == hero2_data["name"]
> assert data[1]["secret_name"] == hero2_data["secret_name"]
> assert data[1]["id"] != hero2_data["id"]
>
> response = client.get("/openapi.json")
> data = response.json()
>
> assert response.status_code == 200, response.text
>
> > assert data == openapi_schema
> E AssertionError: assert {'components'...eate Hero'}}}} ==
> {'components'...eate Hero'}}}}
> E Omitting 3 identical items, use -vv to show
> E Differing items:
> E {'openapi': '3.1.0'} != {'openapi': '3.0.2'}
> E Use -v to get more diff
>
> tests/test_tutorial/test_fastapi/test_multiple_models/test_tutorial002.py:170:
> AssertionError
> ________________________________ test_tutorial
> _________________________________
>
> clear_sqlmodel = None
>
> def test_tutorial(clear_sqlmodel):
> from docs_src.tutorial.fastapi.read_one import tutorial001 as mod
>
> mod.sqlite_url = "sqlite://"
> mod.engine = create_engine(
> mod.sqlite_url, connect_args=mod.connect_args,
> poolclass=StaticPool
> )
>
> with TestClient(mod.app) as client:
>
> hero1_data = {"name": "Deadpond", "secret_name": "Dive Wilson"}
> hero2_data = {
> "name": "Spider-Boy",
> "secret_name": "Pedro Parqueador",
> "id": 9000,
> }
> response = client.post("/heroes/", json=hero1_data)
> assert response.status_code == 200, response.text
> response = client.post("/heroes/", json=hero2_data)
> assert response.status_code == 200, response.text
> hero2 = response.json()
> response = client.get("/heroes/")
> assert response.status_code == 200, response.text
> data = response.json()
> assert len(data) == 2
>
> hero_id = hero2["id"]
> response = client.get(f"/heroes/{hero_id}")
> assert response.status_code == 200, response.text
> data = response.json()
> assert data == hero2
>
> response = client.get("/heroes/9000")
> assert response.status_code == 404, response.text
>
> response = client.get("/openapi.json")
> data = response.json()
>
> assert response.status_code == 200, response.text
>
> > assert data == openapi_schema
> E AssertionError: assert {'components'...Read Hero'}}}} ==
> {'components'...Read Hero'}}}}
> E Omitting 3 identical items, use -vv to show
> E Differing items:
> E {'openapi': '3.1.0'} != {'openapi': '3.0.2'}
> E Use -v to get more diff
>
> tests/test_tutorial/test_fastapi/test_read_one/test_tutorial001.py:189:
> AssertionError
> ________________________________ test_tutorial
> _________________________________
>
> clear_sqlmodel = None
>
> def test_tutorial(clear_sqlmodel):
> from docs_src.tutorial.fastapi.relationships import tutorial001 as mod
>
> mod.sqlite_url = "sqlite://"
> mod.engine = create_engine(
> mod.sqlite_url, connect_args=mod.connect_args,
> poolclass=StaticPool
> )
>
> with TestClient(mod.app) as client:
> response = client.get("/openapi.json")
> data = response.json()
> assert response.status_code == 200, response.text
> > assert data == openapi_schema
> E AssertionError: assert {'components'...or'}}, ...}}}} ==
> {'components'...or'}}, ...}}}}
> E Omitting 3 identical items, use -vv to show
> E Differing items:
> E {'openapi': '3.1.0'} != {'openapi': '3.0.2'}
> E Use -v to get more diff
>
> tests/test_tutorial/test_fastapi/test_relationships/test_tutorial001.py:514:
> AssertionError
> ________________________________ test_tutorial
> _________________________________
>
> clear_sqlmodel = None
>
> def test_tutorial(clear_sqlmodel):
> from docs_src.tutorial.fastapi.response_model import tutorial001 as
> mod
>
> mod.sqlite_url = "sqlite://"
> mod.engine = create_engine(
> mod.sqlite_url, connect_args=mod.connect_args,
> poolclass=StaticPool
> )
>
> with TestClient(mod.app) as client:
>
> hero_data = {"name": "Deadpond", "secret_name": "Dive Wilson"}
> response = client.post("/heroes/", json=hero_data)
> data = response.json()
>
> assert response.status_code == 200, response.text
> assert data["name"] == hero_data["name"]
> assert data["secret_name"] == hero_data["secret_name"]
> assert data["id"] is not None
> assert data["age"] is None
>
> response = client.get("/heroes/")
> data = response.json()
>
> assert response.status_code == 200, response.text
> assert len(data) == 1
> assert data[0]["name"] == hero_data["name"]
> assert data[0]["secret_name"] == hero_data["secret_name"]
>
> response = client.get("/openapi.json")
> data = response.json()
>
> assert response.status_code == 200, response.text
>
> > assert data == openapi_schema
> E AssertionError: assert {'components'...eate Hero'}}}} ==
> {'components'...eate Hero'}}}}
> E Omitting 3 identical items, use -vv to show
> E Differing items:
> E {'openapi': '3.1.0'} != {'openapi': '3.0.2'}
> E Use -v to get more diff
>
> tests/test_tutorial/test_fastapi/test_response_model/test_tutorial001.py:138:
> AssertionError
> ________________________________ test_tutorial
> _________________________________
>
> clear_sqlmodel = None
>
> def test_tutorial(clear_sqlmodel):
> from docs_src.tutorial.fastapi.session_with_dependency import
> tutorial001 as mod
>
> mod.sqlite_url = "sqlite://"
> mod.engine = create_engine(
> mod.sqlite_url, connect_args=mod.connect_args,
> poolclass=StaticPool
> )
>
> with TestClient(mod.app) as client:
>
> hero1_data = {"name": "Deadpond", "secret_name": "Dive Wilson"}
> hero2_data = {
> "name": "Spider-Boy",
> "secret_name": "Pedro Parqueador",
> "id": 9000,
> }
> hero3_data = {
> "name": "Rusty-Man",
> "secret_name": "Tommy Sharp",
> "age": 48,
> }
> response = client.post("/heroes/", json=hero1_data)
> assert response.status_code == 200, response.text
> response = client.post("/heroes/", json=hero2_data)
> assert response.status_code == 200, response.text
> hero2 = response.json()
> hero2_id = hero2["id"]
> response = client.post("/heroes/", json=hero3_data)
> assert response.status_code == 200, response.text
> response = client.get(f"/heroes/{hero2_id}")
> assert response.status_code == 200, response.text
> response = client.get("/heroes/9000")
> assert response.status_code == 404, response.text
> response = client.get("/openapi.json")
> data = response.json()
> assert response.status_code == 200, response.text
> > assert data == openapi_schema
> E AssertionError: assert {'components'...or'}}, ...}}}} ==
> {'components'...or'}}, ...}}}}
> E Omitting 3 identical items, use -vv to show
> E Differing items:
> E {'openapi': '3.1.0'} != {'openapi': '3.0.2'}
> E Use -v to get more diff
>
> tests/test_tutorial/test_fastapi/test_session_with_dependency/test_tutorial001.py:291:
> AssertionError
> ________________________________ test_tutorial
> _________________________________
>
> clear_sqlmodel = None
>
> def test_tutorial(clear_sqlmodel):
> from docs_src.tutorial.fastapi.simple_hero_api import tutorial001 as
> mod
>
> mod.sqlite_url = "sqlite://"
> mod.engine = create_engine(
> mod.sqlite_url, connect_args=mod.connect_args,
> poolclass=StaticPool
> )
>
> with TestClient(mod.app) as client:
>
> hero1_data = {"name": "Deadpond", "secret_name": "Dive Wilson"}
> hero2_data = {
> "name": "Spider-Boy",
> "secret_name": "Pedro Parqueador",
> "id": 9000,
> }
> response = client.post("/heroes/", json=hero1_data)
> data = response.json()
>
> assert response.status_code == 200, response.text
> assert data["name"] == hero1_data["name"]
> assert data["secret_name"] == hero1_data["secret_name"]
> assert data["id"] is not None
> assert data["age"] is None
>
> response = client.post("/heroes/", json=hero2_data)
> data = response.json()
>
> assert response.status_code == 200, response.text
> assert data["name"] == hero2_data["name"]
> assert data["secret_name"] == hero2_data["secret_name"]
> assert data["id"] == hero2_data["id"], (
> "Up to this point it's still possible to "
> "set the ID of the hero in the request"
> )
> assert data["age"] is None
>
> response = client.get("/heroes/")
> data = response.json()
>
> assert response.status_code == 200, response.text
> assert len(data) == 2
> assert data[0]["name"] == hero1_data["name"]
> assert data[0]["secret_name"] == hero1_data["secret_name"]
> assert data[1]["name"] == hero2_data["name"]
> assert data[1]["secret_name"] == hero2_data["secret_name"]
> assert data[1]["id"] == hero2_data["id"]
>
> response = client.get("/openapi.json")
> data = response.json()
>
> assert response.status_code == 200, response.text
>
> > assert data == openapi_schema
> E AssertionError: assert {'components'...eate Hero'}}}} ==
> {'components'...eate Hero'}}}}
> E Omitting 3 identical items, use -vv to show
> E Differing items:
> E {'openapi': '3.1.0'} != {'openapi': '3.0.2'}
> E Use -v to get more diff
>
> tests/test_tutorial/test_fastapi/test_simple_hero_api/test_tutorial001.py:146:
> AssertionError
> ________________________________ test_tutorial
> _________________________________
>
> clear_sqlmodel = None
>
> def test_tutorial(clear_sqlmodel):
> from docs_src.tutorial.fastapi.teams import tutorial001 as mod
>
> mod.sqlite_url = "sqlite://"
> mod.engine = create_engine(
> mod.sqlite_url, connect_args=mod.connect_args,
> poolclass=StaticPool
> )
>
> with TestClient(mod.app) as client:
>
> hero1_data = {"name": "Deadpond", "secret_name": "Dive Wilson"}
> hero2_data = {
> "name": "Spider-Boy",
> "secret_name": "Pedro Parqueador",
> "id": 9000,
> }
> hero3_data = {
> "name": "Rusty-Man",
> "secret_name": "Tommy Sharp",
> "age": 48,
> }
> response = client.get("/openapi.json")
> data = response.json()
> assert response.status_code == 200, response.text
> > assert data == openapi_schema
> E AssertionError: assert {'components'...or'}}, ...}}}} ==
> {'components'...or'}}, ...}}}}
> E Omitting 3 identical items, use -vv to show
> E Differing items:
> E {'openapi': '3.1.0'} != {'openapi': '3.0.2'}
> E Use -v to get more diff
>
> tests/test_tutorial/test_fastapi/test_teams/test_tutorial001.py:492:
> AssertionError
> ________________________________ test_tutorial
> _________________________________
>
> clear_sqlmodel = None
>
> def test_tutorial(clear_sqlmodel):
> from docs_src.tutorial.fastapi.update import tutorial001 as mod
>
> mod.sqlite_url = "sqlite://"
> mod.engine = create_engine(
> mod.sqlite_url, connect_args=mod.connect_args,
> poolclass=StaticPool
> )
>
> with TestClient(mod.app) as client:
>
> hero1_data = {"name": "Deadpond", "secret_name": "Dive Wilson"}
> hero2_data = {
> "name": "Spider-Boy",
> "secret_name": "Pedro Parqueador",
> "id": 9000,
> }
> hero3_data = {
> "name": "Rusty-Man",
> "secret_name": "Tommy Sharp",
> "age": 48,
> }
> response = client.post("/heroes/", json=hero1_data)
> assert response.status_code == 200, response.text
> response = client.post("/heroes/", json=hero2_data)
> assert response.status_code == 200, response.text
> hero2 = response.json()
> hero2_id = hero2["id"]
> response = client.post("/heroes/", json=hero3_data)
> assert response.status_code == 200, response.text
> hero3 = response.json()
> hero3_id = hero3["id"]
> response = client.get(f"/heroes/{hero2_id}")
> assert response.status_code == 200, response.text
> response = client.get("/heroes/9000")
> assert response.status_code == 404, response.text
> response = client.get("/openapi.json")
> data = response.json()
> assert response.status_code == 200, response.text
> > assert data == openapi_schema
> E AssertionError: assert {'components'...or'}}, ...}}}} ==
> {'components'...or'}}, ...}}}}
> E Omitting 3 identical items, use -vv to show
> E Differing items:
> E {'openapi': '3.1.0'} != {'openapi': '3.0.2'}
> E Use -v to get more diff
>
> tests/test_tutorial/test_fastapi/test_update/test_tutorial001.py:265:
> AssertionError
> =============================== warnings summary
> ===============================
> tests/test_advanced/test_decimal/test_tutorial001.py::test_tutorial
> /<<PKGBUILDDIR>>/sqlmodel/orm/session.py:60: SAWarning: Dialect
> sqlite+pysqlite does *not* support Decimal objects natively, and SQLAlchemy
> must convert from floating point - rounding errors and other issues may
> occur. Please consider storing Decimal numbers as strings or integers on this
> platform for lossless storage.
> results = super().execute(
>
> tests/test_tutorial/test_many_to_many/test_tutorial003.py::test_tutorial
> /<<PKGBUILDDIR>>/sqlmodel/main.py:525: RemovedIn20Warning: Deprecated API
> features detected! These feature(s) are not compatible with SQLAlchemy 2.0.
> To prevent incompatible upgrades prior to updating applications, ensure
> requirements files are pinned to "sqlalchemy<2.0". Set environment variable
> SQLALCHEMY_WARN_20=1 to show all deprecation warnings. Set environment
> variable SQLALCHEMY_SILENCE_UBER_WARNING=1 to silence this message.
> (Background on SQLAlchemy 2.0 at: https://sqlalche.me/e/b8d9)
> set_attribute(self, name, value)
>
> -- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
> =========================== short test summary info
> ============================
> FAILED
> tests/test_tutorial/test_fastapi/test_delete/test_tutorial001.py::test_tutorial
> FAILED
> tests/test_tutorial/test_fastapi/test_limit_and_offset/test_tutorial001.py::test_tutorial
> FAILED
> tests/test_tutorial/test_fastapi/test_multiple_models/test_tutorial001.py::test_tutorial
> FAILED
> tests/test_tutorial/test_fastapi/test_multiple_models/test_tutorial002.py::test_tutorial
> FAILED
> tests/test_tutorial/test_fastapi/test_read_one/test_tutorial001.py::test_tutorial
> FAILED
> tests/test_tutorial/test_fastapi/test_relationships/test_tutorial001.py::test_tutorial
> FAILED
> tests/test_tutorial/test_fastapi/test_response_model/test_tutorial001.py::test_tutorial
> FAILED
> tests/test_tutorial/test_fastapi/test_session_with_dependency/test_tutorial001.py::test_tutorial
> FAILED
> tests/test_tutorial/test_fastapi/test_simple_hero_api/test_tutorial001.py::test_tutorial
> FAILED
> tests/test_tutorial/test_fastapi/test_teams/test_tutorial001.py::test_tutorial
> FAILED
> tests/test_tutorial/test_fastapi/test_update/test_tutorial001.py::test_tutorial
> =========== 11 failed, 111 passed, 3 deselected, 2 warnings in 3.11s
> ===========
> E: pybuild pybuild:388: test: plugin custom failed with: exit code=1:
> PYTHONPATH=/<<PKGBUILDDIR>> python3.11 -m pytest -k 'not
> test_create_db_and_table'
> rm -fr -- /tmp/dh-xdg-rundir-fZgx3_Xn
> dh_auto_test: error: pybuild --test --test-pytest -i python{version} -p 3.11
> returned exit code 13
The full build log is available from:
http://qa-logs.debian.net/2023/07/26/sqlmodel_0.0.8-4_unstable.log
All bugs filed during this archive rebuild are listed at:
https://bugs.debian.org/cgi-bin/pkgreport.cgi?tag=ftbfs-20230726;users=lu...@debian.org
or:
https://udd.debian.org/bugs/?release=na&merged=ign&fnewerval=7&flastmodval=7&fusertag=only&fusertagtag=ftbfs-20230726&fusertaguser=lu...@debian.org&allbugs=1&cseverity=1&ctags=1&caffected=1#results
A list of current common problems and possible solutions is available at
http://wiki.debian.org/qa.debian.org/FTBFS . You're welcome to contribute!
If you reassign this bug to another package, please mark it as 'affects'-ing
this package. See https://www.debian.org/Bugs/server-control#affects
If you fail to reproduce this, please provide a build log and diff it with mine
so that we can identify if something relevant changed in the meantime.
--- End Message ---