gspread_asyncio icon indicating copy to clipboard operation
gspread_asyncio copied to clipboard

worksheet.freeze()

Open sak0v opened this issue 10 months ago • 0 comments

Hello! Keep on getting this error for some reason: asyncio.run(test()) File "/opt/homebrew/Cellar/[email protected]/3.11.6_1/Frameworks/Python.framework/Versions/3.11/lib/python3.11/asyncio/runners.py", line 190, in run return runner.run(main) ^^^^^^^^^^^^^^^^ File "/opt/homebrew/Cellar/[email protected]/3.11.6_1/Frameworks/Python.framework/Versions/3.11/lib/python3.11/asyncio/runners.py", line 118, in run return self._loop.run_until_complete(task) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/opt/homebrew/Cellar/[email protected]/3.11.6_1/Frameworks/Python.framework/Versions/3.11/lib/python3.11/asyncio/base_events.py", line 653, in run_until_complete return future.result() ^^^^^^^^^^^^^^^ File "/Users/amirsakov/Downloads/Telegram Bots/brmanager_reloaded/sheet.py", line 20, in test await worksheet.freeze() File "/Users/amirsakov/Downloads/Telegram Bots/brmanager_reloaded/.venv/lib/python3.11/site-packages/gspread_asyncio/__init__.py", line 1852, in freeze return await self.agcm._call(self.ws.format, rows=rows, cols=cols) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Users/amirsakov/Downloads/Telegram Bots/brmanager_reloaded/.venv/lib/python3.11/site-packages/gspread_asyncio/__init__.py", line 122, in _call rval = await self._loop.run_in_executor(None, fn) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/opt/homebrew/Cellar/[email protected]/3.11.6_1/Frameworks/Python.framework/Versions/3.11/lib/python3.11/concurrent/futures/thread.py", line 58, in run result = self.fn(*self.args, **self.kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ TypeError: Worksheet.format() got an unexpected keyword argument 'rows'

This is what I use in my code agcm = gspread_asyncio.AsyncioGspreadClientManager(get_creds) agc = await agcm.authorize() ss = await agc.open_by_url('https://docs.google.com/spreadsheets/d/14FzPFJ5Y7Sh9KkmALKA6-jj7TgYA9oqWLoWbTvXmOHk/edit#gid=543611067') worksheet = await ss.worksheet("Учётность состава") await worksheet.freeze(rows=1,cols=1)

Kindly advice on solving the issue

sak0v avatar Apr 13 '24 03:04 sak0v