Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@pvditt
Copy link
Contributor

@pvditt pvditt commented May 7, 2025

Why are the changes needed?

Upstreaming idl change from https://github.com/unionai/flyte/pull/500

What changes were proposed in this pull request?

add log context to idl

How was this patch tested?

n/a

Setup process

Screenshots

Check all the applicable boxes

  • I updated the documentation accordingly.
  • All new and existing tests passed.
  • All commits are signed-off.

Related PRs

Docs link

Summary by Bito

This pull request introduces a new LogContext API across multiple components to enhance log metadata tracking. It adds LogContext, PodLogContext, and ContainerContext structures to improve traceability between logs and execution contexts. The changes span Go, TypeScript, JavaScript, Python, and Rust implementations for consistent logging support.

Unit tests added: False

Estimated effort to review (1-5, lower is better): 5

Signed-off-by: Paul Dittamo <[email protected]>
@flyte-bot
Copy link
Collaborator

flyte-bot commented May 7, 2025

Code Review Agent Run #810bc8

Actionable Suggestions - 0
Additional Suggestions - 6
  • flyteidl/gen/pb-js/flyteidl.js - 4
  • flyteidl/gen/pb-js/flyteidl.d.ts - 2
    • Missing semicolons in ContainerContext property declarations · Line 6117-6120
    • Missing semicolons in ProcessContext property declarations · Line 6177-6180
Review Details
  • Files reviewed - 20 · Commit Range: c711f88..c711f88
    • flyteidl/gen/pb-es/flyteidl/admin/task_execution_pb.ts
    • flyteidl/gen/pb-es/flyteidl/core/execution_pb.ts
    • flyteidl/gen/pb-es/flyteidl/event/event_pb.ts
    • flyteidl/gen/pb-go/flyteidl/admin/task_execution.pb.go
    • flyteidl/gen/pb-go/flyteidl/core/execution.pb.go
    • flyteidl/gen/pb-go/flyteidl/event/event.pb.go
    • flyteidl/gen/pb-js/flyteidl.d.ts
    • flyteidl/gen/pb-js/flyteidl.js
    • flyteidl/gen/pb_python/flyteidl/admin/task_execution_pb2.py
    • flyteidl/gen/pb_python/flyteidl/admin/task_execution_pb2.pyi
    • flyteidl/gen/pb_python/flyteidl/core/execution_pb2.py
    • flyteidl/gen/pb_python/flyteidl/core/execution_pb2.pyi
    • flyteidl/gen/pb_python/flyteidl/event/event_pb2.py
    • flyteidl/gen/pb_python/flyteidl/event/event_pb2.pyi
    • flyteidl/gen/pb_rust/flyteidl.admin.rs
    • flyteidl/gen/pb_rust/flyteidl.core.rs
    • flyteidl/gen/pb_rust/flyteidl.event.rs
    • flyteidl/protos/flyteidl/admin/task_execution.proto
    • flyteidl/protos/flyteidl/core/execution.proto
    • flyteidl/protos/flyteidl/event/event.proto
  • Files skipped - 2
    • flyteidl/clients/go/assets/admin.swagger.json - Reason: Filter setting
    • flyteidl/gen/pb-go/gateway/flyteidl/service/admin.swagger.json - Reason: Filter setting
  • Tools
    • Whispers (Secret Scanner) - ✔︎ Successful
    • Detect-secrets (Secret Scanner) - ✔︎ Successful

Bito Usage Guide

Commands

Type the following command in the pull request comment and save the comment.

  • /review - Manually triggers a full AI review.

Refer to the documentation for additional commands.

Configuration

This repository uses code_review_bito You can customize the agent settings here or contact your Bito workspace admin at [email protected].

Documentation & Help

AI Code Review powered by Bito Logo

@codecov
Copy link

codecov bot commented May 7, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 58.48%. Comparing base (3b7e6bd) to head (c711f88).
Report is 1 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #6443   +/-   ##
=======================================
  Coverage   58.48%   58.48%           
=======================================
  Files         940      940           
  Lines       71579    71579           
=======================================
  Hits        41865    41865           
  Misses      26531    26531           
  Partials     3183     3183           
Flag Coverage Δ
unittests-datacatalog 59.03% <ø> (ø)
unittests-flyteadmin 56.27% <ø> (ø)
unittests-flytecopilot 30.99% <ø> (ø)
unittests-flytectl 64.72% <ø> (ø)
unittests-flyteidl 76.12% <ø> (ø)
unittests-flyteplugins 60.95% <ø> (ø)
unittests-flytepropeller 54.78% <ø> (ø)
unittests-flytestdlib 64.04% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@pvditt pvditt added the added Merged changes that add new functionality label May 7, 2025
@pvditt pvditt requested review from andrewwdye and hamersaw May 7, 2025 00:13
@flyte-bot
Copy link
Collaborator

Changelist by Bito

This pull request implements the following key changes.

Key Change Files Impacted
New Feature - New Log Context API

flyteidl.core.rs - Introduced new Rust structures for LogContext, PodLogContext, and ContainerContext to enable detailed logging of pod and container metadata.

task_execution.proto - Added log_context field to the admin task execution proto to support improved log metadata identification.

execution.proto - Defined new LogContext, PodLogContext, and ContainerContext messages to facilitate enhanced log tracking.

execution_pb2.py - Updated serialized descriptors and integrated new LogContext-related fields to support enhanced logging capabilities.

execution_pb2.pyi - Added LogContext, PodLogContext, and ContainerContext type definitions to enable detailed log metadata tracking.

flyteidl.admin.rs - Incorporated log_context field to bridge logging metadata with task execution data in the Rust admin module.

execution.pb.go - Enhanced core execution definitions by adding LogContext, PodLogContext, and ContainerContext along with exporter methods for better log metadata tracking.

execution_pb.ts - Added LogContext message definitions with support for pod and container context to enhance log metadata.

flyteidl.d.ts - Introduced LogContext interfaces and classes along with methods for encoding and decoding to support detailed logging in TypeScript.

flyteidl.js - Implemented new log context methods and added support for encoding, decoding, and verifying logContext fields, further reinforcing logging capabilities.

task_execution_pb2.py - Introduced logContext field in TaskExecutionClosure and updated serialized boundaries to support enhanced logging.

task_execution_pb2.pyi - Added logContext field definition and corresponding type annotations to improve log metadata integration.

Feature Improvement - Enhanced Logging Integration

flyteidl.event.rs - Enhanced event definitions by embedding log_context fields to associate log metadata with task execution.

event.proto - Updated event messages to integrate log_context for improved tracking of log metadata in task execution events.

event_pb2.py - Updated event message definitions to integrate log_context field for better log metadata propagation.

event_pb2.pyi - Enhanced type annotations by introducing log_context in task execution events and external resource info.

task_execution.pb.go - Integrated LogContext support through updated dependency indices and field types for improved log detail retrieval in task execution.

task_execution_pb.ts - Updated import statements and added a logContext field with detailed comments to refine task execution log tracking.

event_pb.ts - Introduced logContext fields in various event messages to capture and relay log metadata.

event.pb.go - Refactored event definitions to incorporate extensive LogContext support and updated message fields for improved log metadata propagation.

@pvditt pvditt requested a review from wild-endeavor May 7, 2025 00:27
@pvditt pvditt merged commit d4a450a into master May 7, 2025
49 checks passed
@pvditt pvditt deleted the update-idl branch May 7, 2025 04:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

added Merged changes that add new functionality

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants