Skip to content

Commit

Permalink
Deprecate spawning generator functions.
Browse files Browse the repository at this point in the history
  • Loading branch information
danielshaar committed Dec 11, 2024
1 parent e91c6d5 commit ef915de
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions modal/functions.py
Original file line number Diff line number Diff line change
Expand Up @@ -1275,6 +1275,10 @@ async def _call_generator(self, args, kwargs):

@synchronizer.no_io_translation
async def _call_generator_nowait(self, args, kwargs):
deprecation_warning(
(2024, 12, 11),
"Calling spawn on a generator function is deprecated and will soon be removed.",
)
return await _Invocation.create(
self,
args,
Expand Down

0 comments on commit ef915de

Please sign in to comment.