Skip to content

Conversation

Pijukatel
Copy link
Contributor

Description

Add log redirection guide

Issues

@github-actions github-actions bot added this to the 119th sprint - Tooling team milestone Jul 15, 2025
@github-actions github-actions bot added the t-tooling Issues with this label are in the ownership of the tooling team. label Jul 15, 2025
@Pijukatel Pijukatel added documentation Improvements or additions to documentation. adhoc Ad-hoc unplanned task added during the sprint. labels Jul 15, 2025
@Pijukatel Pijukatel requested a review from Copilot July 15, 2025 08:50
Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds a new guide on redirecting logs from other Actor runs, showcasing both calling new runs and attaching to existing ones.

  • Introduces two Python code examples for log redirection: one for Actor.call and one for streaming logs from an existing run.
  • Updates the main logging concept page to import and display these new examples.

Reviewed Changes

Copilot reviewed 3 out of 5 changed files in this pull request and generated no comments.

File Description
docs/03_concepts/code/10_redirect_log.py New example showing default, disabled, and custom log redirection when calling another Actor.
docs/03_concepts/code/10_redirect_log_existing_run.py New example demonstrating redirecting logs from an already running Actor, with context and manual control.
docs/03_concepts/10_logging.mdx Added a section on log redirection and imported the two new code samples into the docs.
Comments suppressed due to low confidence (3)

docs/03_concepts/code/10_redirect_log_existing_run.py:17

  • [nitpick] The placeholder actor ID 'some_id' differs from 'some_actor_id' used earlier; consider using a consistent placeholder for clarity.
        streamed_log = await Actor.apify_client.run('some_id').get_streamed_log(

docs/03_concepts/code/10_redirect_log_existing_run.py:24

  • [nitpick] Add an entrypoint guard (e.g., if __name__ == '__main__': asyncio.run(main())) so that the example is self-contained and directly runnable.
        await streamed_log.stop()

docs/03_concepts/code/10_redirect_log.py:15

  • [nitpick] Consider adding if __name__ == '__main__': asyncio.run(main()) at the end to make this snippet executable out of the box.
        )

@Pijukatel Pijukatel marked this pull request as ready for review July 15, 2025 08:52
@Pijukatel Pijukatel requested a review from vdusek July 15, 2025 08:53
Copy link
Contributor

@vdusek vdusek left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use webp for images please.

@Pijukatel Pijukatel requested a review from vdusek July 15, 2025 12:21
Copy link
Contributor

@vdusek vdusek left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

a few comments

Co-authored-by: Vlada Dusek <v.dusek96@gmail.com>
@Pijukatel Pijukatel requested a review from vdusek July 15, 2025 12:31
Copy link
Contributor

@vdusek vdusek left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@Pijukatel Pijukatel merged commit c681f09 into master Jul 15, 2025
23 checks passed
@Pijukatel Pijukatel deleted the redirect-logs-guide branch July 15, 2025 12:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
adhoc Ad-hoc unplanned task added during the sprint. documentation Improvements or additions to documentation. t-tooling Issues with this label are in the ownership of the tooling team.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants