GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — fix: Unblock build (#174) · googleapis/python-aiplatform@3192485

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
  • google/cloud/aiplatform
    • base.py
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎google/cloud/aiplatform/base.py‎

Copy file name to clipboardExpand all lines: google/cloud/aiplatform/base.py
+6-6Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ def _submit(
123123
"""
124124

125125
def wait_for_dependencies_and_invoke(
126-
deps: Optional[Sequence[futures.Future]],
126+
deps: Sequence[futures.Future],
127127
method: Callable[..., Any],
128128
args: Sequence[Any],
129129
kwargs: Dict[str, Any],
@@ -143,11 +143,8 @@ def wait_for_dependencies_and_invoke(
143143
Callbacks that take the result of method.
144144
145145
"""
146-
# wait for all dependencies to complete
147-
futures_results = futures.wait(deps, return_when=futures.FIRST_EXCEPTION)
148146

149-
# check for raised exceptions before moving forward
150-
for future in futures_results.done:
147+
for future in set(deps):
151148
future.result()
152149

153150
result = method(*args, **kwargs)
@@ -163,9 +160,12 @@ def wait_for_dependencies_and_invoke(
163160
deps = [
164161
arg._latest_future
165162
for arg in list(args) + list(kwargs.values())
166-
if isinstance(arg, FutureManager) and arg._latest_future
163+
if isinstance(arg, FutureManager)
167164
]
168165

166+
# filter out objects that do not have pending tasks
167+
deps = [dep for dep in deps if dep]
168+
169169
if additional_dependencies:
170170
deps.extend(additional_dependencies)
171171

0 commit comments

Comments
0 (0)
You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.