Skip to content

Commit

Permalink
Merge pull request #6 from ynput/enhancement/add-linux-usd-variant
Browse files Browse the repository at this point in the history
Add linux USD variant
  • Loading branch information
antirotor authored May 27, 2024
2 parents 21c645a + dca9ffb commit 20ceecd
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 1 deletion.
6 changes: 5 additions & 1 deletion client/ayon_usd/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
import subprocess
import zipfile
from pathlib import Path
from typing import Union

import ayon_api
from ayon_core.lib.local_settings import get_ayon_appdirs
Expand Down Expand Up @@ -170,12 +171,15 @@ def _find_file_info(name, files_info):
)


def get_downloaded_usd_root() -> str:
def get_downloaded_usd_root() -> Union[str, None]:
"""Get downloaded USD binary root path."""
if _USDOptions.downloaded_root is not NOT_SET:
return _USDOptions.downloaded_root

server_usd_info = _find_file_info("usd", get_server_files_info())
if not server_usd_info:
return None

root = None
for existing_info in get_downloaded_usd_info():
if existing_info["checksum"] != server_usd_info["checksum"]:
Expand Down
5 changes: 5 additions & 0 deletions create_package.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,11 @@
"url": f"{AYON_SOURCE_URL}/usd-24.03_win64_py39.zip",
"checksum": "7d7852b9c8e3501e5f64175decc08d70e3bf1c083faaaf2c1a8aa8f9af43ab30",
"checksum_algorithm": "sha256",
},
"linux": {
"url": f"{AYON_SOURCE_URL}/usd-24.03_linux_py39.zip",
"checksum": "27010ad67d5acd25e3c95b1ace4ab30e047b5a9e48082db0545ae44ae7ec9b09",
"checksum_algorithm": "sha256",
}
}
}
Expand Down
2 changes: 2 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ repository = "https://github.com/ynput/ayon-usd-resolver"

[tool.poetry.dependencies]
python = "^3.9"
ayon-python-api = "^1.0.5"

[tool.poetry.dev-dependencies]
pytest = "^8.2.0"
Expand All @@ -27,6 +28,7 @@ pre-commit = "^3.6.2"
codespell = "^2.2.6"
pydantic = "^2.7.1"
pydocstyle = "*"
requests = "^2.26.0"
semver = "^3.0.2" # needed for ayon-python-api to run tests
clique = "^2.0.0" # needed for ayon-python-api to run tests

Expand Down

0 comments on commit 20ceecd

Please sign in to comment.