Skip to content

Commit 42dd64a

Browse files
committed
chore: revert gapic-generator template and noxfile changes in packages
1 parent 68a0bdf commit 42dd64a

418 files changed

Lines changed: 17427 additions & 6093 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

packages/bigframes/noxfile.py

Lines changed: 0 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,6 @@
4444
"3.10",
4545
# colab.research.google.com
4646
"3.11",
47-
"import_profile",
4847
]
4948

5049
PYTEST_VERSION = "pytest==8.4.2"
@@ -1093,23 +1092,3 @@ def mypy(session):
10931092
"--explicit-package-bases",
10941093
'--exclude="^third_party"',
10951094
)
1096-
1097-
1098-
@nox.session(python="3.15")
1099-
def import_profile(session):
1100-
"""Ensure import times remain below defined thresholds."""
1101-
profiler_script = (
1102-
CURRENT_DIRECTORY.parent.parent / "scripts" / "import_profiler" / "profiler.py"
1103-
)
1104-
if not profiler_script.exists():
1105-
session.skip("The import profiler script was not found.")
1106-
1107-
session.install(".")
1108-
session.run(
1109-
"python",
1110-
str(profiler_script),
1111-
"--module",
1112-
"google",
1113-
"--iterations",
1114-
"10",
1115-
)

packages/bigquery-magics/noxfile.py

Lines changed: 0 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,6 @@
4141
"3.12",
4242
"3.13",
4343
"3.14",
44-
"import_profile",
4544
]
4645

4746
UNIT_TEST_STANDARD_DEPENDENCIES = [
@@ -547,23 +546,3 @@ def mypy(session):
547546
# TODO(https://github.com/googleapis/google-cloud-python/issues/16014):
548547
# Add mypy tests
549548
session.skip("mypy tests are not yet supported")
550-
551-
552-
@nox.session(python="3.15")
553-
def import_profile(session):
554-
"""Ensure import times remain below defined thresholds."""
555-
profiler_script = (
556-
CURRENT_DIRECTORY.parent.parent / "scripts" / "import_profiler" / "profiler.py"
557-
)
558-
if not profiler_script.exists():
559-
session.skip("The import profiler script was not found.")
560-
561-
session.install(".")
562-
session.run(
563-
"python",
564-
str(profiler_script),
565-
"--module",
566-
"google",
567-
"--iterations",
568-
"10",
569-
)

packages/db-dtypes/noxfile.py

Lines changed: 0 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,6 @@
4242
"3.12",
4343
"3.13",
4444
"3.14",
45-
"import_profile",
4645
]
4746

4847
UNIT_TEST_STANDARD_DEPENDENCIES = [
@@ -548,23 +547,3 @@ def mypy(session):
548547
"--ignore-missing-imports",
549548
*session.posargs,
550549
)
551-
552-
553-
@nox.session(python="3.15")
554-
def import_profile(session):
555-
"""Ensure import times remain below defined thresholds."""
556-
profiler_script = (
557-
CURRENT_DIRECTORY.parent.parent / "scripts" / "import_profiler" / "profiler.py"
558-
)
559-
if not profiler_script.exists():
560-
session.skip("The import profiler script was not found.")
561-
562-
session.install(".")
563-
session.run(
564-
"python",
565-
str(profiler_script),
566-
"--module",
567-
"google",
568-
"--iterations",
569-
"10",
570-
)

packages/django-google-spanner/noxfile.py

Lines changed: 0 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -491,23 +491,3 @@ def format(session: nox.sessions.Session) -> None:
491491
"--line-length=88", # Standard Black line length
492492
*LINT_PATHS,
493493
)
494-
495-
496-
@nox.session(python="3.15")
497-
def import_profile(session):
498-
"""Ensure import times remain below defined thresholds."""
499-
profiler_script = (
500-
CURRENT_DIRECTORY.parent.parent / "scripts" / "import_profiler" / "profiler.py"
501-
)
502-
if not profiler_script.exists():
503-
session.skip("The import profiler script was not found.")
504-
505-
session.install(".")
506-
session.run(
507-
"python",
508-
str(profiler_script),
509-
"--module",
510-
"google",
511-
"--iterations",
512-
"10",
513-
)

packages/gapic-generator/gapic/templates/noxfile.py.j2

Lines changed: 0 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,6 @@ nox.options.sessions = [
8686
"lint_setup_py",
8787
"blacken",
8888
"docs",
89-
"import_profile",
9089
]
9190

9291
# Error if a python version is missing
@@ -642,35 +641,4 @@ def core_deps_from_source(session, protobuf_implementation):
642641
"PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION": protobuf_implementation,
643642
},
644643
)
645-
646-
647-
@nox.session(python="3.15")
648-
def import_profile(session):
649-
"""Ensure import times remain below defined thresholds."""
650-
profiler_script = (
651-
CURRENT_DIRECTORY.parent.parent / "scripts" / "import_profiler" / "profiler.py"
652-
)
653-
if not profiler_script.exists():
654-
session.skip("The import profiler script was not found.")
655-
656-
session.install(".")
657-
{% if api.naming.module_namespace %}
658-
session.run(
659-
"python",
660-
str(profiler_script),
661-
"--module",
662-
"{{ api.naming.module_namespace[0] }}",
663-
"--iterations",
664-
"10",
665-
)
666-
{% else %}
667-
session.run(
668-
"python",
669-
str(profiler_script),
670-
"--module",
671-
"{{ api.naming.versioned_module_name }}",
672-
"--iterations",
673-
"10",
674-
)
675-
{% endif %}
676644
{% endblock %}

packages/gapic-generator/noxfile.py

Lines changed: 1 addition & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -847,23 +847,4 @@ def core_deps_from_source(session, protobuf_implementation):
847847
"""Run all tests with core dependencies installed from source."""
848848
# TODO(https://github.com/googleapis/google-cloud-python/issues/16185):
849849
# Implement logic to install core packages directly from the mono-repo directories.
850-
session.skip("core_deps_from_source session is not yet implemented for gapic-generator-python.")
851-
852-
@nox.session(python="3.15")
853-
def import_profile(session):
854-
"""Ensure import times remain below defined thresholds."""
855-
profiler_script = (
856-
CURRENT_DIRECTORY.parent.parent / "scripts" / "import_profiler" / "profiler.py"
857-
)
858-
if not profiler_script.exists():
859-
session.skip("The import profiler script was not found.")
860-
861-
session.install(".")
862-
session.run(
863-
"python",
864-
str(profiler_script),
865-
"--module",
866-
"google",
867-
"--iterations",
868-
"10",
869-
)
850+
session.skip("core_deps_from_source session is not yet implemented for gapic-generator-python.")

packages/gapic-generator/tests/integration/goldens/asset/noxfile.py

Lines changed: 0 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,6 @@
9393
"lint_setup_py",
9494
"blacken",
9595
"docs",
96-
"import_profile",
9796
]
9897

9998
# Error if a python version is missing
@@ -634,23 +633,3 @@ def core_deps_from_source(session, protobuf_implementation):
634633
"PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION": protobuf_implementation,
635634
},
636635
)
637-
638-
639-
@nox.session(python="3.15")
640-
def import_profile(session):
641-
"""Ensure import times remain below defined thresholds."""
642-
profiler_script = (
643-
CURRENT_DIRECTORY.parent.parent / "scripts" / "import_profiler" / "profiler.py"
644-
)
645-
if not profiler_script.exists():
646-
session.skip("The import profiler script was not found.")
647-
648-
session.install(".")
649-
session.run(
650-
"python",
651-
str(profiler_script),
652-
"--module",
653-
"google",
654-
"--iterations",
655-
"10",
656-
)

packages/gapic-generator/tests/integration/goldens/credentials/noxfile.py

Lines changed: 0 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,6 @@
9393
"lint_setup_py",
9494
"blacken",
9595
"docs",
96-
"import_profile",
9796
]
9897

9998
# Error if a python version is missing
@@ -634,23 +633,3 @@ def core_deps_from_source(session, protobuf_implementation):
634633
"PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION": protobuf_implementation,
635634
},
636635
)
637-
638-
639-
@nox.session(python="3.15")
640-
def import_profile(session):
641-
"""Ensure import times remain below defined thresholds."""
642-
profiler_script = (
643-
CURRENT_DIRECTORY.parent.parent / "scripts" / "import_profiler" / "profiler.py"
644-
)
645-
if not profiler_script.exists():
646-
session.skip("The import profiler script was not found.")
647-
648-
session.install(".")
649-
session.run(
650-
"python",
651-
str(profiler_script),
652-
"--module",
653-
"google",
654-
"--iterations",
655-
"10",
656-
)

packages/gapic-generator/tests/integration/goldens/eventarc/noxfile.py

Lines changed: 0 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,6 @@
9393
"lint_setup_py",
9494
"blacken",
9595
"docs",
96-
"import_profile",
9796
]
9897

9998
# Error if a python version is missing
@@ -634,23 +633,3 @@ def core_deps_from_source(session, protobuf_implementation):
634633
"PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION": protobuf_implementation,
635634
},
636635
)
637-
638-
639-
@nox.session(python="3.15")
640-
def import_profile(session):
641-
"""Ensure import times remain below defined thresholds."""
642-
profiler_script = (
643-
CURRENT_DIRECTORY.parent.parent / "scripts" / "import_profiler" / "profiler.py"
644-
)
645-
if not profiler_script.exists():
646-
session.skip("The import profiler script was not found.")
647-
648-
session.install(".")
649-
session.run(
650-
"python",
651-
str(profiler_script),
652-
"--module",
653-
"google",
654-
"--iterations",
655-
"10",
656-
)

packages/gapic-generator/tests/integration/goldens/logging/noxfile.py

Lines changed: 0 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,6 @@
9393
"lint_setup_py",
9494
"blacken",
9595
"docs",
96-
"import_profile",
9796
]
9897

9998
# Error if a python version is missing
@@ -634,23 +633,3 @@ def core_deps_from_source(session, protobuf_implementation):
634633
"PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION": protobuf_implementation,
635634
},
636635
)
637-
638-
639-
@nox.session(python="3.15")
640-
def import_profile(session):
641-
"""Ensure import times remain below defined thresholds."""
642-
profiler_script = (
643-
CURRENT_DIRECTORY.parent.parent / "scripts" / "import_profiler" / "profiler.py"
644-
)
645-
if not profiler_script.exists():
646-
session.skip("The import profiler script was not found.")
647-
648-
session.install(".")
649-
session.run(
650-
"python",
651-
str(profiler_script),
652-
"--module",
653-
"google",
654-
"--iterations",
655-
"10",
656-
)

0 commit comments

Comments
 (0)