Another attempt: uninstall the old get-poetry.py
first then install the new poetry, as recommended in the official doc.
But failed due to OSError: [Errno 30] Read-only file system
in both cases. Now I have no idea what to try next…
curl -sSL https://raw.githubusercontent.com/python-poetry/poetry/901bdf0491005f1b3db41947d0d938da6838ecb9/get-poetry.py | python3 - --uninstall
poetry --version; curl -sSL https://install.python-poetry.org | python3 -
poetry install
Logs:
==> Using Python version: 3.10.10
==> Running build command 'curl -sSL https://raw.githubusercontent.com/python-poetry/poetry/901bdf0491005f1b3db41947d0d938da6838ecb9/get-poetry.py | python3 - --uninstall; poetry --version; curl -sSL https://install.python-poetry.org | python3 -; poetry install'...
Traceback (most recent call last):
File "<stdin>", line 1161, in <module>
File "<stdin>", line 1155, in main
# We are sorry to see you go!
This will uninstall Poetry.
It will remove the `poetry` command from Poetry's bin directory, located at:
/home/render/.python-poetry/bin
This will also remove Poetry from your system's PATH.
File "<stdin>", line 381, in uninstall
File "<stdin>", line 587, in remove_home
File "/opt/render/project/python/Python-3.10.10/lib/python3.10/shutil.py", line 725, in rmtree
_rmtree_safe_fd(fd, path, onerror)
File "/opt/render/project/python/Python-3.10.10/lib/python3.10/shutil.py", line 658, in _rmtree_safe_fd
_rmtree_safe_fd(dirfd, fullname, onerror)
File "/opt/render/project/python/Python-3.10.10/lib/python3.10/shutil.py", line 658, in _rmtree_safe_fd
_rmtree_safe_fd(dirfd, fullname, onerror)
File "/opt/render/project/python/Python-3.10.10/lib/python3.10/shutil.py", line 658, in _rmtree_safe_fd
_rmtree_safe_fd(dirfd, fullname, onerror)
[Previous line repeated 4 more times]
File "/opt/render/project/python/Python-3.10.10/lib/python3.10/shutil.py", line 681, in _rmtree_safe_fd
onerror(os.unlink, fullname, sys.exc_info())
File "/opt/render/project/python/Python-3.10.10/lib/python3.10/shutil.py", line 679, in _rmtree_safe_fd
os.unlink(entry.name, dir_fd=topfd)
OSError: [Errno 30] Read-only file system: 'thread.cpython-37.pyc'
Poetry version 1.1.14
Retrieving Poetry metadata
# Welcome to Poetry!
Traceback (most recent call last):
File "/opt/render/project/python/Python-3.10.10/lib/python3.10/shutil.py", line 816, in move
This will download and install the latest version of Poetry,
a dependency and package manager for Python.
It will add the `poetry` command to Poetry's bin directory, located at:
/home/render/.python-poetry/bin
You can uninstall at any time by executing this script with the --uninstall option,
and these changes will be reverted.
Installing Poetry (1.4.2)
Installing Poetry (1.4.2): Saving existing environment
os.rename(src, real_dst)
OSError: [Errno 30] Read-only file system: '/home/render/.python-poetry/venv' -> '/home/render/.python-poetry/venv.save'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "<stdin>", line 940, in <module>
File "<stdin>", line 919, in main
File "<stdin>", line 550, in run
File "<stdin>", line 571, in install
File "/opt/render/project/python/Python-3.10.10/lib/python3.10/contextlib.py", line 135, in __enter__
return next(self.gen)
File "<stdin>", line 625, in make_env
File "/opt/render/project/python/Python-3.10.10/lib/python3.10/shutil.py", line 832, in move
copytree(src, real_dst, copy_function=copy_function,
File "/opt/render/project/python/Python-3.10.10/lib/python3.10/shutil.py", line 559, in copytree
return _copytree(entries=entries, src=src, dst=dst, symlinks=symlinks,
File "/opt/render/project/python/Python-3.10.10/lib/python3.10/shutil.py", line 457, in _copytree
os.makedirs(dst, exist_ok=dirs_exist_ok)
File "/opt/render/project/python/Python-3.10.10/lib/python3.10/os.py", line 225, in makedirs
mkdir(name, mode)
OSError: [Errno 30] Read-only file system: '/home/render/.python-poetry/venv.save'
RuntimeError
The lock file is not compatible with the current version of Poetry.
Upgrade Poetry to be able to read the lock file or, alternatively, regenerate the lock file with the `poetry lock` command.
at /home/render/.python-poetry/venv/lib/python3.7/site-packages/poetry/packages/locker.py:482 in _get_lock_data
478│ "regenerate the lock file with the `poetry lock` command."
479│ )
480│ elif not lock_version_allowed:
481│ raise RuntimeError(
→ 482│ "The lock file is not compatible with the current version of Poetry.\n"
483│ "Upgrade Poetry to be able to read the lock file or, alternatively, "
484│ "regenerate the lock file with the `poetry lock` command."
485│ )
486│
==> Build failed 😞
(and now I had to change “http” in curl commands to “ttp” because of this error…)