-
Notifications
You must be signed in to change notification settings - Fork 579
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Add integration test for pydantic2 * Upgrade fastapi to >= 0.100 * This version of fastapi will work with pydantic2 * Add predict.py int-test * Fix pip freeze test
- Loading branch information
Showing
4 changed files
with
26 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 6 additions & 0 deletions
6
test-integration/test_integration/fixtures/pydantic2/cog.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
build: | ||
gpu: false | ||
python_version: "3.12" | ||
python_packages: | ||
- "pydantic>2" | ||
predict: "predict.py:Predictor" |
6 changes: 6 additions & 0 deletions
6
test-integration/test_integration/fixtures/pydantic2/predict.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
from cog import BasePredictor | ||
|
||
|
||
class Predictor(BasePredictor): | ||
def predict(self, s: str) -> str: | ||
return "hello " + s |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters