To use ayon-launcher --use-dev bundles with server 1.0.0-rc.1, use ayon_python_api 1.0.0rc3

If you have problems using dev bundles (ayon-launcher: python start.py --use-dev) with server 1.0.0-rc1+202312131444, use ayon_python_api 1.0.0rc3

You may need to create a local wheel for 1.0.0rc3 since ayon_python_api 1.0.0rc1 is the latest on Index of /wheels


my problem with dev bundles was the following:
ayon-launcher was working before server 1.0.0-rc.1+202312131444

python start.py --debug --use-dev

with the new server,
I was able to track the problem down to the code in ayon_api/server_api.py

backward compatibility code for AYON server < 0.3.0
if-then logic treated AYON server 1.0.0 and <0.3.0 the same

if major == 0 and minor >= 3:
    url = "settings"
else:

I was getting the following error:

ayon-launcher>python start.py --debug --use-dev
Traceback (most recent call last):
  File "C:\Test\dev\AyonOpenPype\ayon-launcher\.venv\lib\site-packages\ayon_api\server_api.py", line 190, in raise_for_status
    self._response.raise_for_status()
  File "C:\Test\dev\AyonOpenPype\ayon-launcher\.venv\lib\site-packages\requests\models.py", line 1021, in raise_for_status
    raise HTTPError(http_error_msg, response=self)
requests.exceptions.HTTPError: 400 Client Error: Bad Request for url: https://onchain.ayon.cloud/api/settings/addons?variant=dev-Studio-Name-2023-11-16&site=stylish-neon-beagle

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "c:\Test\dev\AyonOpenPype\ayon-launcher\start.py", line 856, in <module>
    main()
  File "c:\Test\dev\AyonOpenPype\ayon-launcher\start.py", line 846, in main
    boot()
  File "c:\Test\dev\AyonOpenPype\ayon-launcher\start.py", line 646, in boot
    _start_distribution()
  File "c:\Test\dev\AyonOpenPype\ayon-launcher\start.py", line 585, in _start_distribution
    _run_disk_mapping(bundle_name)
  File "c:\Test\dev\AyonOpenPype\ayon-launcher\start.py", line 493, in _run_disk_mapping
    settings = get_addons_studio_settings(bundle_name)
  File "C:\Test\dev\AyonOpenPype\ayon-launcher\.venv\lib\site-packages\ayon_api\_api.py", line 736, in get_addons_studio_settings
    return con.get_addons_studio_settings(*args, **kwargs)
  File "C:\Test\dev\AyonOpenPype\ayon-launcher\.venv\lib\site-packages\ayon_api\server_api.py", line 3190, in get_addons_studio_settings
    output = self.get_bundle_settings(
  File "C:\Test\dev\AyonOpenPype\ayon-launcher\.venv\lib\site-packages\ayon_api\server_api.py", line 3155, in get_bundle_settings
    response.raise_for_status()
  File "C:\Test\dev\AyonOpenPype\ayon-launcher\.venv\lib\site-packages\ayon_api\server_api.py", line 194, in raise_for_status
    raise HTTPRequestError(message, exc.response)
ayon_api.exceptions.HTTPRequestError: 400 Client Error: Bad Request for url: https://onchain.ayon.cloud/api/settings/addons?variant=dev-Studio-Name-2023-11-16&site=stylish-neon-beagle

While I can’t help with the issue…
But, I thought about replicating it on my side.

I couldn’t replicate the issue…
Roughly, These are my steps to update Ayon:

  1. update server

    cd your-ayon-docker-repo-clone
    sudo docker compose pull
    sudo docker compose up -d
    
  2. update OpenPype and Ayon launcher repos

    git checkout develop
    git pull origin develop
    
  3. update OpenPype and Ayon python env
    In Ayon Launcher Repo:

    • ./tools/manage.ps1 create-env which updates poetry.lock
    • ./tools/manage.ps1 install-runtime-dependencies which updates your libs as configured in project.toml

    In OpenPype Repo:

    • .\tools\create_env.ps1
    • .\tools\fetch_thirdparty_libs.ps1

These steps were discussed here How to keep up with Ayon updates?

Thanks!
you may want to update the pypi.org version to 1.0.0-rc.3 instead of 0.5.4

I am using windows 10/11. I have not tested on macOS and linux.

For ayon-launcher, I would type the following:

poetry shell
pip list
...
ayon-python-api 1.0.0rc1
...

running the following would not upgrade ayon-python-api
pip install ayon-python-api --upgrade

also, the following would not show ayon-python-api as outdated
pip list --outdated

I just noticed the version.py in github.com/ayon-python-api/ayon_api
has 1.0.0-rc.3
and ayon-python-api · PyPI
has 0.5.4
which is lower than 1.0.0-rc.1

To install and list pre-release, use pip --pre
This will grab the latest pre-release, 1.0.0-rc.3

pip list --outdated --pre

pip install ayon-python-api --upgrade --pre

Oh yeah, we’re hitting limitations of pypi versioning system. Because we’ve already published versions without rc (up to 0.5.4) it still think that latest version is 0.5.4 because 1.0.0rc3 is pre release.

But I’m afraid we can’t do much about it now until 1.0.0 is released.