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

Skip to content

Conversation

Pijukatel
Copy link
Contributor

@Pijukatel Pijukatel commented Aug 27, 2025

Description

  • Add specialized ApifyRequestQueueMetadata that contains Apify-specific RequestQueueStats
  • This enhances metadata of ApifyRequestQueueClient

Issues

@github-actions github-actions bot added this to the 122nd sprint - Tooling team milestone Aug 27, 2025
@github-actions github-actions bot added t-tooling Issues with this label are in the ownership of the tooling team. tested Temporary label used only programatically for some analytics. labels Aug 27, 2025
@Pijukatel Pijukatel changed the title Add stats to apify rq feat: Add stats to ApifyRequestQueueClient Aug 28, 2025
@Pijukatel Pijukatel requested review from vdusek and janbuchar August 28, 2025 11:50
@Pijukatel Pijukatel marked this pull request as ready for review August 28, 2025 11:51
Comment on lines +1299 to +1302
metadata = await request_queue_force_cloud.get_metadata()

assert hasattr(metadata, 'stats')
apify_metadata = cast('ApifyRequestQueueMetadata', metadata)
Copy link
Contributor

Choose a reason for hiding this comment

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

I don't see much value in this, since typing casts are required anyway, instead of simply allowing extra fields in the Pydantic model, or omitting this altogether and using the Apify client directly.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is more about showing that force_cloud=True created RQ will have the stats. If that is the case, then it is implicitly proven that even the client has them.

Copy link
Contributor

Choose a reason for hiding this comment

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

Sorry, I meant this whole PR, as we discussed on Slack here.

@Pijukatel Pijukatel requested a review from vdusek September 11, 2025 08:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
t-tooling Issues with this label are in the ownership of the tooling team. tested Temporary label used only programatically for some analytics.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add stats to RequestQueue
2 participants