MCPcopy
hub / github.com/redis/redis-py / load_scripts

Method load_scripts

redis/client.py:1990–2001  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

1988 return result
1989
1990 def load_scripts(self):
1991 # make sure all scripts that are about to be run on this pipeline exist
1992 scripts = list(self.scripts)
1993 immediate = self.immediate_execute_command
1994 shas = [s.sha for s in scripts]
1995 # we can't use the normal script_* methods because they would just
1996 # get buffered in the pipeline.
1997 exists = immediate("SCRIPT EXISTS", *shas)
1998 if not all(exists):
1999 for s, exist in zip(scripts, exists):
2000 if not exist:
2001 s.sha = immediate("SCRIPT LOAD", s.script)
2002
2003 def _disconnect_raise_on_watching(
2004 self,

Callers 2

executeMethod · 0.95
test_blocked_methodsMethod · 0.45

Calls

no outgoing calls

Tested by 1

test_blocked_methodsMethod · 0.36