Last active
May 23, 2022 20:31
-
-
Save zzstoatzz/b4b02251db42481c8399f11725506670 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from prefect.tasks import task_input_hash | |
@task(cache_key_fn=task_input_hash) | |
def get_games(url: str) -> List[Game]: | |
logger = get_run_logger() | |
logger.info(f"GET {url}") | |
return [Game(game['pgn'])for game in requests.get(url).json()['games']] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment