Use `JsonSerializable` for `user_data` by Pijukatel · Pull Request #1193 · apify/crawlee-python · GitHub | Latest TMZ Celebrity News & Gossip | Watch TMZ Live
Skip to content

Use JsonSerializable for user_data #1193

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

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from
Draft

Conversation

Pijukatel
Copy link
Collaborator

Description

Use JsonSerializable type for user_data

Issues

@github-actions github-actions bot added this to the 114th sprint - Tooling team milestone May 7, 2025
@github-actions github-actions bot added the t-tooling Issues with this label are in the ownership of the tooling team. label May 7, 2025
@Pijukatel
Copy link
Collaborator Author

It seems ok according to mypy like this and unit tests are passing as well, but I am not really sure about this though. As discussed here: https://github.com/apify/crawlee-python/pull/1086/files/a67d3b3b42d2a1d59923810fe6f17dabeea3e98b#r1995086090

there are some casts down the road when it comes to user data, which makes me unsure about type checking result.

@janbuchar
Copy link
Collaborator

The reason this is uncool is that crawlee puts its own stuff into user_data (more precisely user_data['__crawlee']), and this depends on it being a dictionary. Not sure if the platform would accept anything other than a dict, too...

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.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Update push_data annotations to use JsonSerializable type
2 participants

TMZ Celebrity News – Breaking Stories, Videos & Gossip

Looking for the latest TMZ celebrity news? You've come to the right place. From shocking Hollywood scandals to exclusive videos, TMZ delivers it all in real time.

Whether it’s a red carpet slip-up, a viral paparazzi moment, or a legal drama involving your favorite stars, TMZ news is always first to break the story. Stay in the loop with daily updates, insider tips, and jaw-dropping photos.

🎥 Watch TMZ Live

TMZ Live brings you daily celebrity news and interviews straight from the TMZ newsroom. Don’t miss a beat—watch now and see what’s trending in Hollywood.