Skip to content

v1.5.1 - [bugfix] Allow revalidation with proxied arrays

Compare
Choose a tag to compare
@sneakers-the-rat sneakers-the-rat released this 03 Sep 20:23
· 100 commits to main since this release
c46015d

See: #14

When a proxy object is passed to some validators after having already been validated, validation fails.

This should always succeed:

from numpydantic import NDArray
from pydantic import BaseModel

class MyModel(BaseModel):
    array: NDArray

instance = MyModel(array=valid_input)
_ = MyModel(array=instance.array)

but it's currently failing for the proxied interfaces.

This PR

  • adds passthrough checks for h5proxy and videoproxy
  • adds a testing module for tests against all interfaces, and tests that an already-instantiated model can be re-instantiated using the same array field after passing through the interface