Skip to content

Commit

Permalink
Colab Pydantic fix
Browse files Browse the repository at this point in the history
  • Loading branch information
olokobayusuf committed Jan 12, 2024
1 parent a4514de commit e62e2f2
Show file tree
Hide file tree
Showing 34 changed files with 35 additions and 35 deletions.
2 changes: 1 addition & 1 deletion Changelog.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
## 0.0.27
*INCOMPLETE*
+ Fixed `model_dump` error when making predictions in Google Colab due to outdated `pydantic` dependency.

## 0.0.26
+ Added support for serializing `BytesIO` instances in `fxn.predictions.to_value` method.
Expand Down
2 changes: 1 addition & 1 deletion conftest.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#
# Function
# Copyright © 2023 NatML Inc. All Rights Reserved.
# Copyright © 2024 NatML Inc. All Rights Reserved.
#
2 changes: 1 addition & 1 deletion fxn/__init__.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# Function
# Copyright © 2023 NatML Inc. All Rights Reserved.
# Copyright © 2024 NatML Inc. All Rights Reserved.
#

from .function import Function
Expand Down
2 changes: 1 addition & 1 deletion fxn/cli/__init__.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# Function
# Copyright © 2023 NatML Inc. All Rights Reserved.
# Copyright © 2024 NatML Inc. All Rights Reserved.
#

from typer import Typer
Expand Down
2 changes: 1 addition & 1 deletion fxn/cli/auth.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# Function
# Copyright © 2023 NatML Inc. All Rights Reserved.
# Copyright © 2024 NatML Inc. All Rights Reserved.
#

from pathlib import Path
Expand Down
2 changes: 1 addition & 1 deletion fxn/cli/env.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# Function
# Copyright © 2023 NatML Inc. All Rights Reserved.
# Copyright © 2024 NatML Inc. All Rights Reserved.
#

from rich import print_json
Expand Down
2 changes: 1 addition & 1 deletion fxn/cli/misc.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# Function
# Copyright © 2023 NatML Inc. All Rights Reserved.
# Copyright © 2024 NatML Inc. All Rights Reserved.
#

from rich import print
Expand Down
2 changes: 1 addition & 1 deletion fxn/cli/predict.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# Function
# Copyright © 2023 NatML Inc. All Rights Reserved.
# Copyright © 2024 NatML Inc. All Rights Reserved.
#

from io import BytesIO
Expand Down
2 changes: 1 addition & 1 deletion fxn/cli/predictors.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# Function
# Copyright © 2023 NatML Inc. All Rights Reserved.
# Copyright © 2024 NatML Inc. All Rights Reserved.
#

from rich import print_json
Expand Down
2 changes: 1 addition & 1 deletion fxn/function.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# Function
# Copyright © 2023 NatML Inc. All Rights Reserved.
# Copyright © 2024 NatML Inc. All Rights Reserved.
#

from os import environ
Expand Down
2 changes: 1 addition & 1 deletion fxn/graph/__init__.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# Function
# Copyright © 2023 NatML Inc. All Rights Reserved.
# Copyright © 2024 NatML Inc. All Rights Reserved.
#

from .client import GraphClient
2 changes: 1 addition & 1 deletion fxn/graph/client.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# Function
# Copyright © 2023 NatML Inc. All Rights Reserved.
# Copyright © 2024 NatML Inc. All Rights Reserved.
#

from requests import post
Expand Down
2 changes: 1 addition & 1 deletion fxn/magic.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# Function
# Copyright © 2023 NatML Inc. All Rights Reserved.
# Copyright © 2024 NatML Inc. All Rights Reserved.
#

from IPython.core.interactiveshell import InteractiveShell
Expand Down
2 changes: 1 addition & 1 deletion fxn/services/__init__.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# Function
# Copyright © 2023 NatML Inc. All Rights Reserved.
# Copyright © 2024 NatML Inc. All Rights Reserved.
#

from .user import UserService, PROFILE_FIELDS, USER_FIELDS
Expand Down
2 changes: 1 addition & 1 deletion fxn/services/environment.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# Function
# Copyright © 2023 NatML Inc. All Rights Reserved.
# Copyright © 2024 NatML Inc. All Rights Reserved.
#

from typing import List
Expand Down
2 changes: 1 addition & 1 deletion fxn/services/prediction.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# Function
# Copyright © 2023 NatML Inc. All Rights Reserved.
# Copyright © 2024 NatML Inc. All Rights Reserved.
#

from aiohttp import ClientSession
Expand Down
2 changes: 1 addition & 1 deletion fxn/services/predictor.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# Function
# Copyright © 2023 NatML Inc. All Rights Reserved.
# Copyright © 2024 NatML Inc. All Rights Reserved.
#

from pathlib import Path
Expand Down
2 changes: 1 addition & 1 deletion fxn/services/storage.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# Function
# Copyright © 2023 NatML Inc. All Rights Reserved.
# Copyright © 2024 NatML Inc. All Rights Reserved.
#

from base64 import b64encode
Expand Down
2 changes: 1 addition & 1 deletion fxn/services/user.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# Function
# Copyright © 2023 NatML Inc. All Rights Reserved.
# Copyright © 2024 NatML Inc. All Rights Reserved.
#

from ..graph import GraphClient
Expand Down
2 changes: 1 addition & 1 deletion fxn/types/__init__.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# Function
# Copyright © 2023 NatML Inc. All Rights Reserved.
# Copyright © 2024 NatML Inc. All Rights Reserved.
#

from .dtype import Dtype
Expand Down
2 changes: 1 addition & 1 deletion fxn/types/dtype.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# Function
# Copyright © 2023 NatML Inc. All Rights Reserved.
# Copyright © 2024 NatML Inc. All Rights Reserved.
#

from enum import Enum
Expand Down
2 changes: 1 addition & 1 deletion fxn/types/environment.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# Function
# Copyright © 2023 NatML Inc. All Rights Reserved.
# Copyright © 2024 NatML Inc. All Rights Reserved.
#

from __future__ import annotations
Expand Down
2 changes: 1 addition & 1 deletion fxn/types/prediction.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# Function
# Copyright © 2023 NatML Inc. All Rights Reserved.
# Copyright © 2024 NatML Inc. All Rights Reserved.
#

from __future__ import annotations
Expand Down
2 changes: 1 addition & 1 deletion fxn/types/predictor.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# Function
# Copyright © 2023 NatML Inc. All Rights Reserved.
# Copyright © 2024 NatML Inc. All Rights Reserved.
#

from __future__ import annotations
Expand Down
2 changes: 1 addition & 1 deletion fxn/types/profile.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# Function
# Copyright © 2023 NatML Inc. All Rights Reserved.
# Copyright © 2024 NatML Inc. All Rights Reserved.
#

from pydantic import BaseModel
Expand Down
2 changes: 1 addition & 1 deletion fxn/types/storage.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# Function
# Copyright © 2023 NatML Inc. All Rights Reserved.
# Copyright © 2024 NatML Inc. All Rights Reserved.
#

from enum import Enum
Expand Down
2 changes: 1 addition & 1 deletion fxn/types/tag.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# Function
# Copyright © 2023 NatML Inc. All Rights Reserved.
# Copyright © 2024 NatML Inc. All Rights Reserved.
#

class Tag:
Expand Down
2 changes: 1 addition & 1 deletion fxn/types/user.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# Function
# Copyright © 2023 NatML Inc. All Rights Reserved.
# Copyright © 2024 NatML Inc. All Rights Reserved.
#

from .profile import Profile
Expand Down
2 changes: 1 addition & 1 deletion fxn/types/value.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# Function
# Copyright © 2023 NatML Inc. All Rights Reserved.
# Copyright © 2024 NatML Inc. All Rights Reserved.
#

from __future__ import annotations
Expand Down
2 changes: 1 addition & 1 deletion fxn/version.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# Function
# Copyright © 2023 NatML Inc. All Rights Reserved.
# Copyright © 2024 NatML Inc. All Rights Reserved.
#

__version__ = "0.0.27"
4 changes: 2 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# Function
# Copyright © 2023 NatML Inc. All Rights Reserved.
# Copyright © 2024 NatML Inc. All Rights Reserved.
#

from setuptools import find_packages, setup
Expand Down Expand Up @@ -31,7 +31,7 @@
"filetype",
"numpy",
"pillow",
"pydantic",
"pydantic>=2.0",
"requests",
"rich",
"typer"
Expand Down
2 changes: 1 addition & 1 deletion test/prediction_test.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# Function
# Copyright © 2023 NatML Inc. All Rights Reserved.
# Copyright © 2024 NatML Inc. All Rights Reserved.
#

from fxn import Function
Expand Down
2 changes: 1 addition & 1 deletion test/storage_test.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# Function
# Copyright © 2023 NatML Inc. All Rights Reserved.
# Copyright © 2024 NatML Inc. All Rights Reserved.
#

from fxn import Function, UploadType
Expand Down
2 changes: 1 addition & 1 deletion test/value_test.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# Function
# Copyright © 2023 NatML Inc. All Rights Reserved.
# Copyright © 2024 NatML Inc. All Rights Reserved.
#

from dataclasses import dataclass
Expand Down

0 comments on commit e62e2f2

Please sign in to comment.