-
Notifications
You must be signed in to change notification settings - Fork 148
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
PiperOrigin-RevId: 570818380 Change-Id: I94d0b2861648bc088cd367d488ac16aab8599f43
- Loading branch information
1 parent
74c408b
commit 2570355
Showing
6 changed files
with
64 additions
and
4 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
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
2 changes: 1 addition & 1 deletion
2
builders/testdata/python/appengine/requirements_bin_conflict/requirements.txt
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 |
---|---|---|
@@ -1,4 +1,4 @@ | ||
flask==2.0.3 | ||
gunicorn==20.0.4 # gunicorn installs an executable into bin. | ||
spacy==3.2.1 # spacy installs executables into bin and site-packages/bin. | ||
spacy==3.7.0 # spacy installs executables into bin and site-packages/bin. | ||
Werkzeug==2.2.2 # Flask 2.x incompatible with latest Werkzeug 3.x as of 10/2023 |
2 changes: 1 addition & 1 deletion
2
builders/testdata/python/functions/with_framework_bin_conflict/requirements.txt
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 |
---|---|---|
@@ -1,2 +1,2 @@ | ||
functions-framework==3.0.0 | ||
spacy==3.2.1 # spacy installs executables into bin and site-packages/bin. | ||
spacy==3.7.0 # spacy installs executables into bin and site-packages/bin |
45 changes: 45 additions & 0 deletions
45
builders/testdata/python/generic/native_extensions_above_python39/main.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,45 @@ | ||
# Copyright 2020 Google LLC | ||
# | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
|
||
"""Simple flask web server used in acceptance tests. | ||
""" | ||
import os | ||
|
||
from flask import Flask | ||
import numpy as np | ||
from numpy.ctypeslib import load_library | ||
|
||
app = Flask(__name__) | ||
|
||
|
||
def test_multiarray_umath(): | ||
try: | ||
# Should succeed | ||
load_library("_multiarray_umath", np.core._multiarray_umath.__file__) | ||
except ImportError as e: | ||
msg = ("Import error was: %s" % str(e)) | ||
print(msg) | ||
return e | ||
|
||
|
||
@app.route("/") | ||
def hello(): | ||
if test_multiarray_umath() is None: | ||
return "PASS" | ||
else: | ||
return "FAILED" | ||
|
||
if __name__ == "__main__": | ||
app.run(port=os.environ["PORT"], debug=True) | ||
|
5 changes: 5 additions & 0 deletions
5
builders/testdata/python/generic/native_extensions_above_python39/requirements.txt
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,5 @@ | ||
flask==2.0.3 | ||
gunicorn==20.0.4 | ||
numpy==1.26.0 # Python 3.12.0 is supported by numpy >= 1.26.0 | ||
setuptools==66.1.0 # Python 3.12.0 is supported by setuptools >= 1.26.0 | ||
Werkzeug==2.2.2 # Flask 2.x incompatible with latest Werkzeug 3.x as of 10/2023 |