Skip to main content

object schema evaluation

Project description

pip install shape_eval

Guide

Schema Evaluation - shape(...)

from shape_eval.service import shape

model = [
  {'id': 1, 'name': "a", 'data': {'detail': "some string"} },
  {'id': 2, 'name': "b", 'data': {'detail': 123} },
  {'id': 3, 'name': "c", 'data': None }
]

shape(model)
[{'data?': {'detail': 'str|int'}, 'id': 'int', 'name': 'str'}]
  • Nullable properties have '?' appended at the end.
  • Values are replaced with string representation of data type.
  • If more than one data type is found, like the 'detail' property, union format is used.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

shape_eval-1.1.0.tar.gz (55.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

shape_eval-1.1.0-py3-none-any.whl (59.1 kB view details)

Uploaded Python 3

File details

Details for the file shape_eval-1.1.0.tar.gz.

File metadata

  • Download URL: shape_eval-1.1.0.tar.gz
  • Upload date:
  • Size: 55.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.13

File hashes

Hashes for shape_eval-1.1.0.tar.gz
Algorithm Hash digest
SHA256 02be045077fb6e2940e34ffea41881a291ea78478e231bbfebfa275c31fa54db
MD5 190c50dcdf5f6b534b6096214a6e2410
BLAKE2b-256 cf5d168e5ed47d082df3b0f374431c64f57850a669bc45422f96ac332db2ca6f

See more details on using hashes here.

File details

Details for the file shape_eval-1.1.0-py3-none-any.whl.

File metadata

  • Download URL: shape_eval-1.1.0-py3-none-any.whl
  • Upload date:
  • Size: 59.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.13

File hashes

Hashes for shape_eval-1.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 58957cf90e352381cc9bd3cb5078362da00b26bde59a898f888ca26c4d2235cb
MD5 f517441ed327990e6f478dc479dd28b7
BLAKE2b-256 47879847e6e3c5da75e929dceb53567c29a31c3793a4ef7c0de03002fc19d3d0

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page