Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[autoscaler] fix too many values to unpack (expected 2) bug #36231

Merged
merged 4 commits into from
Jun 9, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 10 additions & 6 deletions python/ray/autoscaler/_private/monitor.py
Original file line number Diff line number Diff line change
Expand Up @@ -400,11 +400,15 @@ def _run(self):
self.autoscaler.update()
status["autoscaler_update_time"] = time.time() - update_start_time
autoscaler_summary = self.autoscaler.summary()
self.emit_metrics(
load_metrics_summary,
autoscaler_summary,
self.autoscaler.all_node_types,
)
try:
self.emit_metrics(
load_metrics_summary,
autoscaler_summary,
self.autoscaler.all_node_types,
)
except Exception:
logger.exception("Error emitting metrics")

if autoscaler_summary:
status["autoscaler_report"] = asdict(autoscaler_summary)
status[
Expand Down Expand Up @@ -464,7 +468,7 @@ def emit_metrics(self, load_metrics_summary, autoscaler_summary, node_types):
for _, node_type, _ in autoscaler_summary.pending_nodes:
pending_node_count[node_type] += 1

for node_type, count in autoscaler_summary.pending_launches:
for node_type, count in autoscaler_summary.pending_launches.items():
pending_node_count[node_type] += count

for node_type in node_types:
Expand Down