Wauplin HF staff commited on
Commit
d56a645
·
1 Parent(s): 058d3f8

Do need to use iter over `list_spaces` anymore

Browse files

Really just a nit FYI :)

`list(list_spaces(full=True, limit=None))` is valid in the most recent versions of `huggingface_hub`(at least the last 2 versions _I think_). You'll not get a warning when doing so :wink:

Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -6,7 +6,7 @@ from toolz import groupby, valmap
6
 
7
  @cached(cache=TTLCache(maxsize=100, ttl=60 * 10))
8
  def get_spaces():
9
- return list(iter(list_spaces(full=True, limit=None)))
10
 
11
 
12
  get_spaces() # to warm up the cache
 
6
 
7
  @cached(cache=TTLCache(maxsize=100, ttl=60 * 10))
8
  def get_spaces():
9
+ return list(list_spaces(full=True, limit=None))
10
 
11
 
12
  get_spaces() # to warm up the cache