Loading pkgs/development/python-modules/wandb/default.nix +11 −3 Original line number Diff line number Diff line Loading @@ -16,6 +16,7 @@ ## wandb buildPythonPackage, replaceVars, fetchpatch, # build-system hatchling, Loading Loading @@ -75,12 +76,12 @@ }: let version = "0.25.0"; version = "0.25.1"; src = fetchFromGitHub { owner = "wandb"; repo = "wandb"; tag = "v${version}"; hash = "sha256-ouJHMPcWiHn2p0mFatmC28xUmjzxsoDW9WBX6FzjyDc="; hash = "sha256-jrHj+dNW/eUMcqT5XJbiAz1tlviVBhdtroJ8dA7GBr4="; }; gpu-stats = rustPlatform.buildRustPackage { Loading @@ -107,7 +108,7 @@ let }; }; wandb-core = buildGoModule rec { wandb-core = buildGoModule { pname = "wandb-core"; inherit src version; Loading Loading @@ -162,6 +163,13 @@ buildPythonPackage (finalAttrs: { (replaceVars ./hardcode-git-path.patch { git = lib.getExe gitMinimal; }) # https://github.com/wandb/wandb/pull/11552 (fetchpatch { name = "add-protobuf-7-compatibility"; url = "https://github.com/wandb/wandb/commit/4ef09f3dd1ee408eb9194ea8b7feea2b1128839c.patch"; hash = "sha256-6weMJI51cWXz2mCxOGWYGrh0QCxtMGqz6HAVRF5b1xs="; }) ]; postPatch = Loading pkgs/development/python-modules/wandb/hardcode-git-path.patch +8 −21 Original line number Diff line number Diff line diff --git a/landfill/functional_tests/kfp/wandb_probe.py b/landfill/functional_tests/kfp/wandb_probe.py index 86b18a438..23e237e3b 100644 --- a/landfill/functional_tests/kfp/wandb_probe.py +++ b/landfill/functional_tests/kfp/wandb_probe.py @@ -5,7 +5,7 @@ import subprocess def wandb_probe_package(): if not os.environ.get("WB_PROBE_PACKAGE"): return - s, o = subprocess.getstatusoutput("git rev-parse HEAD") + s, o = subprocess.getstatusoutput("@git@ rev-parse HEAD") if s: return wandb_local = f"git+https://github.com/wandb/wandb.git@{o}#egg=wandb" diff --git a/wandb/cli/cli.py b/wandb/cli/cli.py index 1453100cc..9dc468201 100644 index a87b17c96..21c851992 100644 --- a/wandb/cli/cli.py +++ b/wandb/cli/cli.py @@ -2531,7 +2531,7 @@ def restore(ctx, run, no_git, branch, project, entity): @@ -2672,7 +2672,7 @@ def restore(ctx, run, no_git, branch, project, entity): commit, json_config, patch_content, metadata = api.run_config( project, run=run, entity=entity ) - repo = metadata.get("git", {}).get("repo") + repo = metadata.get("@git@", {}).get("repo") image = metadata.get("docker") restore_message = """`wandb restore` needs to be run from the same git repository as the original run. Run `git clone {}` and restore from there or pass the --no-git flag.""".format(repo) @@ -2547,7 +2547,7 @@ Run `git clone {}` and restore from there or pass the --no-git flag.""".format(r restore_message = f"""`wandb restore` needs to be run from the same git repository as the original run. Run `git clone {repo}` and restore from there or pass the --no-git flag.""" @@ -2691,7 +2691,7 @@ Run `git clone {repo}` and restore from there or pass the --no-git flag.""" if commit and api.git.enabled: if commit and git.enabled: wandb.termlog(f"Fetching origin and finding commit: {commit}") - subprocess.check_call(["git", "fetch", "--all"]) + subprocess.check_call(["@git@", "fetch", "--all"]) try: api.git.repo.commit(commit) git.repo.commit(commit) except ValueError: @@ -2604,7 +2604,7 @@ Run `git clone {}` and restore from there or pass the --no-git flag.""".format(r @@ -2744,7 +2744,7 @@ Run `git clone {repo}` and restore from there or pass the --no-git flag.""" # --reject is necessary or else this fails any time a binary file # occurs in the diff exit_code = subprocess.call( Loading Loading
pkgs/development/python-modules/wandb/default.nix +11 −3 Original line number Diff line number Diff line Loading @@ -16,6 +16,7 @@ ## wandb buildPythonPackage, replaceVars, fetchpatch, # build-system hatchling, Loading Loading @@ -75,12 +76,12 @@ }: let version = "0.25.0"; version = "0.25.1"; src = fetchFromGitHub { owner = "wandb"; repo = "wandb"; tag = "v${version}"; hash = "sha256-ouJHMPcWiHn2p0mFatmC28xUmjzxsoDW9WBX6FzjyDc="; hash = "sha256-jrHj+dNW/eUMcqT5XJbiAz1tlviVBhdtroJ8dA7GBr4="; }; gpu-stats = rustPlatform.buildRustPackage { Loading @@ -107,7 +108,7 @@ let }; }; wandb-core = buildGoModule rec { wandb-core = buildGoModule { pname = "wandb-core"; inherit src version; Loading Loading @@ -162,6 +163,13 @@ buildPythonPackage (finalAttrs: { (replaceVars ./hardcode-git-path.patch { git = lib.getExe gitMinimal; }) # https://github.com/wandb/wandb/pull/11552 (fetchpatch { name = "add-protobuf-7-compatibility"; url = "https://github.com/wandb/wandb/commit/4ef09f3dd1ee408eb9194ea8b7feea2b1128839c.patch"; hash = "sha256-6weMJI51cWXz2mCxOGWYGrh0QCxtMGqz6HAVRF5b1xs="; }) ]; postPatch = Loading
pkgs/development/python-modules/wandb/hardcode-git-path.patch +8 −21 Original line number Diff line number Diff line diff --git a/landfill/functional_tests/kfp/wandb_probe.py b/landfill/functional_tests/kfp/wandb_probe.py index 86b18a438..23e237e3b 100644 --- a/landfill/functional_tests/kfp/wandb_probe.py +++ b/landfill/functional_tests/kfp/wandb_probe.py @@ -5,7 +5,7 @@ import subprocess def wandb_probe_package(): if not os.environ.get("WB_PROBE_PACKAGE"): return - s, o = subprocess.getstatusoutput("git rev-parse HEAD") + s, o = subprocess.getstatusoutput("@git@ rev-parse HEAD") if s: return wandb_local = f"git+https://github.com/wandb/wandb.git@{o}#egg=wandb" diff --git a/wandb/cli/cli.py b/wandb/cli/cli.py index 1453100cc..9dc468201 100644 index a87b17c96..21c851992 100644 --- a/wandb/cli/cli.py +++ b/wandb/cli/cli.py @@ -2531,7 +2531,7 @@ def restore(ctx, run, no_git, branch, project, entity): @@ -2672,7 +2672,7 @@ def restore(ctx, run, no_git, branch, project, entity): commit, json_config, patch_content, metadata = api.run_config( project, run=run, entity=entity ) - repo = metadata.get("git", {}).get("repo") + repo = metadata.get("@git@", {}).get("repo") image = metadata.get("docker") restore_message = """`wandb restore` needs to be run from the same git repository as the original run. Run `git clone {}` and restore from there or pass the --no-git flag.""".format(repo) @@ -2547,7 +2547,7 @@ Run `git clone {}` and restore from there or pass the --no-git flag.""".format(r restore_message = f"""`wandb restore` needs to be run from the same git repository as the original run. Run `git clone {repo}` and restore from there or pass the --no-git flag.""" @@ -2691,7 +2691,7 @@ Run `git clone {repo}` and restore from there or pass the --no-git flag.""" if commit and api.git.enabled: if commit and git.enabled: wandb.termlog(f"Fetching origin and finding commit: {commit}") - subprocess.check_call(["git", "fetch", "--all"]) + subprocess.check_call(["@git@", "fetch", "--all"]) try: api.git.repo.commit(commit) git.repo.commit(commit) except ValueError: @@ -2604,7 +2604,7 @@ Run `git clone {}` and restore from there or pass the --no-git flag.""".format(r @@ -2744,7 +2744,7 @@ Run `git clone {repo}` and restore from there or pass the --no-git flag.""" # --reject is necessary or else this fails any time a binary file # occurs in the diff exit_code = subprocess.call( Loading