sase-github 0.2.10__tar.gz → 0.2.11__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (46) hide show
  1. sase_github-0.2.11/.release-please-manifest.json +3 -0
  2. {sase_github-0.2.10 → sase_github-0.2.11}/CHANGELOG.md +7 -0
  3. {sase_github-0.2.10 → sase_github-0.2.11}/PKG-INFO +1 -1
  4. {sase_github-0.2.10 → sase_github-0.2.11}/pyproject.toml +1 -1
  5. {sase_github-0.2.10 → sase_github-0.2.11}/src/sase_github/scripts/gh_setup.py +14 -1
  6. {sase_github-0.2.10 → sase_github-0.2.11}/tests/test_gh_workspace_claims.py +4 -1
  7. {sase_github-0.2.10 → sase_github-0.2.11}/tests/test_workspace_plugin.py +52 -0
  8. sase_github-0.2.10/.release-please-manifest.json +0 -3
  9. {sase_github-0.2.10 → sase_github-0.2.11}/.github/workflows/ci.yml +0 -0
  10. {sase_github-0.2.10 → sase_github-0.2.11}/.github/workflows/pr-title.yml +0 -0
  11. {sase_github-0.2.10 → sase_github-0.2.11}/.github/workflows/publish.yml +0 -0
  12. {sase_github-0.2.10 → sase_github-0.2.11}/.sase_beads/beads.db +0 -0
  13. {sase_github-0.2.10 → sase_github-0.2.11}/.sase_beads/config.json +0 -0
  14. {sase_github-0.2.10 → sase_github-0.2.11}/.sase_beads/issues.jsonl +0 -0
  15. {sase_github-0.2.10 → sase_github-0.2.11}/CLAUDE.md +0 -0
  16. {sase_github-0.2.10 → sase_github-0.2.11}/Justfile +0 -0
  17. {sase_github-0.2.10 → sase_github-0.2.11}/LICENSE +0 -0
  18. {sase_github-0.2.10 → sase_github-0.2.11}/README.md +0 -0
  19. {sase_github-0.2.10 → sase_github-0.2.11}/docs/architecture.md +0 -0
  20. {sase_github-0.2.10 → sase_github-0.2.11}/docs/configuration.md +0 -0
  21. {sase_github-0.2.10 → sase_github-0.2.11}/docs/xprompts.md +0 -0
  22. {sase_github-0.2.10 → sase_github-0.2.11}/release-please-config.json +0 -0
  23. {sase_github-0.2.10 → sase_github-0.2.11}/src/sase_github/__init__.py +0 -0
  24. {sase_github-0.2.10 → sase_github-0.2.11}/src/sase_github/config.py +0 -0
  25. {sase_github-0.2.10 → sase_github-0.2.11}/src/sase_github/default_config.yml +0 -0
  26. {sase_github-0.2.10 → sase_github-0.2.11}/src/sase_github/errors.py +0 -0
  27. {sase_github-0.2.10 → sase_github-0.2.11}/src/sase_github/plugin.py +0 -0
  28. {sase_github-0.2.10 → sase_github-0.2.11}/src/sase_github/scripts/__init__.py +0 -0
  29. {sase_github-0.2.10 → sase_github-0.2.11}/src/sase_github/scripts/gh_release.py +0 -0
  30. {sase_github-0.2.10 → sase_github-0.2.11}/src/sase_github/scripts/new_pr_desc_get_context.py +0 -0
  31. {sase_github-0.2.10 → sase_github-0.2.11}/src/sase_github/task_types.py +0 -0
  32. {sase_github-0.2.10 → sase_github-0.2.11}/src/sase_github/workspace_plugin.py +0 -0
  33. {sase_github-0.2.10 → sase_github-0.2.11}/src/sase_github/xprompts/gh.yml +0 -0
  34. {sase_github-0.2.10 → sase_github-0.2.11}/src/sase_github/xprompts/new_pr_desc.yml +0 -0
  35. {sase_github-0.2.10 → sase_github-0.2.11}/src/sase_github/xprompts/pr_diff.yml +0 -0
  36. {sase_github-0.2.10 → sase_github-0.2.11}/src/sase_github/xprompts/prdd.yml +0 -0
  37. {sase_github-0.2.10 → sase_github-0.2.11}/tests/__init__.py +0 -0
  38. {sase_github-0.2.10 → sase_github-0.2.11}/tests/test_ci_install_contract.py +0 -0
  39. {sase_github-0.2.10 → sase_github-0.2.11}/tests/test_config.py +0 -0
  40. {sase_github-0.2.10 → sase_github-0.2.11}/tests/test_github_issues.py +0 -0
  41. {sase_github-0.2.10 → sase_github-0.2.11}/tests/test_github_plugin.py +0 -0
  42. {sase_github-0.2.10 → sase_github-0.2.11}/tests/test_github_pull_requests.py +0 -0
  43. {sase_github-0.2.10 → sase_github-0.2.11}/tests/test_new_pr_desc_get_context.py +0 -0
  44. {sase_github-0.2.10 → sase_github-0.2.11}/tests/test_submit_with_recorded_pr.py +0 -0
  45. {sase_github-0.2.10 → sase_github-0.2.11}/tests/test_task_types.py +0 -0
  46. {sase_github-0.2.10 → sase_github-0.2.11}/uv.lock +0 -0
@@ -0,0 +1,3 @@
1
+ {
2
+ ".": "0.2.11"
3
+ }
@@ -1,5 +1,12 @@
1
1
  # Changelog
2
2
 
3
+ ## [0.2.11](https://github.com/sase-org/sase-github/compare/v0.2.10...v0.2.11) (2026-09-08)
4
+
5
+
6
+ ### Bug Fixes
7
+
8
+ * **github:** preflight managed clone origins in setup ([d09ee25](https://github.com/sase-org/sase-github/commit/d09ee25f3fac18cd874afb78143d8dfcb6449709))
9
+
3
10
  ## [0.2.10](https://github.com/sase-org/sase-github/compare/v0.2.9...v0.2.10) (2026-09-08)
4
11
 
5
12
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.5
2
2
  Name: sase-github
3
- Version: 0.2.10
3
+ Version: 0.2.11
4
4
  Summary: GitHub VCS plugin for sase
5
5
  License-Expression: MIT
6
6
  License-File: LICENSE
@@ -4,7 +4,7 @@ build-backend = "hatchling.build"
4
4
 
5
5
  [project]
6
6
  name = "sase-github"
7
- version = "0.2.10"
7
+ version = "0.2.11"
8
8
  description = "GitHub VCS plugin for sase"
9
9
  requires-python = ">=3.12"
10
10
  license = "MIT"
@@ -17,7 +17,10 @@ from sase.running_field import (
17
17
  from sase.sdd.store import materialize_sdd_store
18
18
  from sase.workspace_provider import resolve_ref
19
19
  from sase.workspace_provider.occupant import new_occupant_record, write_occupant_record
20
- from sase.workspace_provider.utils import ensure_workspace_checkout
20
+ from sase.workspace_provider.utils import (
21
+ ensure_workspace_checkout,
22
+ reconcile_managed_checkout_origin,
23
+ )
21
24
 
22
25
  _CALLER_TAG = "gh-setup"
23
26
 
@@ -86,6 +89,16 @@ def main(
86
89
  )
87
90
 
88
91
  try:
92
+ if (
93
+ pre_allocated
94
+ and workspace_num > 1
95
+ and os.path.isdir(workspace_dir.rstrip("/"))
96
+ ):
97
+ reconcile_managed_checkout_origin(
98
+ workspace_dir,
99
+ primary_workspace_dir=resolved.primary_workspace_dir,
100
+ assume_managed_checkout=True,
101
+ )
89
102
  _assert_github_vcs_provider(
90
103
  workspace_dir=workspace_dir,
91
104
  primary_workspace_dir=resolved.primary_workspace_dir,
@@ -32,7 +32,10 @@ ROOT = Path(__file__).resolve().parents[1]
32
32
 
33
33
  @pytest.fixture(autouse=True)
34
34
  def _github_provider_guard_passes() -> Iterator[None]:
35
- with patch("sase_github.scripts.gh_setup._assert_github_vcs_provider"):
35
+ with (
36
+ patch("sase_github.scripts.gh_setup._assert_github_vcs_provider"),
37
+ patch("sase_github.scripts.gh_setup.reconcile_managed_checkout_origin"),
38
+ ):
36
39
  yield
37
40
 
38
41
 
@@ -2062,6 +2062,58 @@ class TestWsResolveRef:
2062
2062
 
2063
2063
 
2064
2064
  class TestGhSetup:
2065
+ def test_preallocated_workspace_reconciles_origin_before_provider_assertion(
2066
+ self, tmp_path: Path
2067
+ ) -> None:
2068
+ from sase_github.scripts import gh_setup
2069
+
2070
+ workspace_dir = str(tmp_path / "prealloc")
2071
+ Path(workspace_dir).mkdir()
2072
+ resolved = ResolvedRef(
2073
+ project_file="/tmp/gh_acme__widget.sase",
2074
+ project_name="gh_acme__widget",
2075
+ primary_workspace_dir="/work/widget/",
2076
+ checkout_target="origin/main",
2077
+ canonical_ref="gh_acme__widget",
2078
+ )
2079
+ order: list[str] = []
2080
+
2081
+ def reconcile(*_args: object, **_kwargs: object) -> None:
2082
+ order.append("reconcile")
2083
+
2084
+ def assert_provider(*_args: object, **_kwargs: object) -> None:
2085
+ order.append("provider")
2086
+
2087
+ with (
2088
+ patch("sase_github.scripts.gh_setup.resolve_ref", return_value=resolved),
2089
+ patch.dict(
2090
+ os.environ,
2091
+ {
2092
+ "SASE_GH_PRE_ALLOCATED": "1",
2093
+ "SASE_GH_WORKSPACE_NUM": "13",
2094
+ "SASE_GH_WORKSPACE_DIR": workspace_dir,
2095
+ },
2096
+ ),
2097
+ patch("sase_github.scripts.gh_setup.materialize_sdd_store"),
2098
+ patch(
2099
+ "sase_github.scripts.gh_setup.reconcile_managed_checkout_origin",
2100
+ side_effect=reconcile,
2101
+ ) as mock_reconcile,
2102
+ patch(
2103
+ "sase_github.scripts.gh_setup._assert_github_vcs_provider",
2104
+ side_effect=assert_provider,
2105
+ ),
2106
+ patch("sase_github.scripts.gh_setup.ensure_workspace_not_occupied"),
2107
+ ):
2108
+ gh_setup.main(gh_ref="acme/widget", n=None, release=True)
2109
+
2110
+ assert order[:2] == ["reconcile", "provider"]
2111
+ mock_reconcile.assert_called_once_with(
2112
+ workspace_dir,
2113
+ primary_workspace_dir="/work/widget/",
2114
+ assume_managed_checkout=True,
2115
+ )
2116
+
2065
2117
  def test_materializes_sdd_store_after_atomic_claim(self) -> None:
2066
2118
  from sase_github.scripts import gh_setup
2067
2119
 
@@ -1,3 +0,0 @@
1
- {
2
- ".": "0.2.10"
3
- }
File without changes
File without changes
File without changes
File without changes
File without changes