sdtk-code-kit 0.6.0 → 0.6.1

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.
package/README.md CHANGED
@@ -17,7 +17,7 @@ For the full end-user guide, use:
17
17
  ## Public Package Truth
18
18
 
19
19
  - package: `sdtk-code-kit`
20
- - version in this source snapshot: `0.6.0`
20
+ - version in this source snapshot: `0.6.1`
21
21
  - command: `sdtk-code`
22
22
  - latest published version lookup: `npm view sdtk-code-kit version`
23
23
  - primary workflow-first surface:
@@ -1,6 +1,6 @@
1
1
  {
2
- "version": "0.6.0",
3
- "sourceCommit": "4b8f40a5d114a946af7e89badd43b48fb6b38692",
2
+ "version": "0.6.1",
3
+ "sourceCommit": "6f433df20e20216d4d542250e8b375041b365015",
4
4
  "fileCount": 54,
5
5
  "files": [
6
6
  {
@@ -110,13 +110,13 @@
110
110
  },
111
111
  {
112
112
  "path": "toolkit/skills/code-issue/scripts/test_tracker.py",
113
- "sha256": "8bb62dffd925cddb986cc5fa7221854d8d61842c813eddd2995994997cc18a84",
114
- "size": 14435
113
+ "sha256": "7fb4c2bae9c20dc1555c4ebcf6a02b2279dab2208ac6479dc247efb949bbabca",
114
+ "size": 15241
115
115
  },
116
116
  {
117
117
  "path": "toolkit/skills/code-issue/scripts/tracker.py",
118
- "sha256": "4e6d62892428e59abf77c38e7afa745349149b4e75b7788e824b0e5ebd6c3547",
119
- "size": 22394
118
+ "sha256": "f1b3beb83266127ba575d6cd9ba335eb0f71483d25ae4a76b46d715fb3947681",
119
+ "size": 22671
120
120
  },
121
121
  {
122
122
  "path": "toolkit/skills/code-issue/SKILL.md",
@@ -19,8 +19,8 @@ b77f92e57ea8a04b933d43268f3195ad86365f34c888925f6e5456deacbad023 toolkit/skills
19
19
  aa0d7a843fbb8cb3978618c2bb70e16f49436cf69cc259f0fb2a6ce222f5bcdf toolkit/skills/code-issue/references/MODE_REVIEW.md
20
20
  8f49cdf7b576ff8be444446ba04a3598ef1a3c7336067e1fbbef90b93287e663 toolkit/skills/code-issue/references/PROFILE_TEMPLATE.md
21
21
  6b2ffffdc40d5c17ff8aa0e8601facbd27db51b72aa60b60f89f669b82fb7c9e toolkit/skills/code-issue/references/RECORDS.md
22
- 8bb62dffd925cddb986cc5fa7221854d8d61842c813eddd2995994997cc18a84 toolkit/skills/code-issue/scripts/test_tracker.py
23
- 4e6d62892428e59abf77c38e7afa745349149b4e75b7788e824b0e5ebd6c3547 toolkit/skills/code-issue/scripts/tracker.py
22
+ 7fb4c2bae9c20dc1555c4ebcf6a02b2279dab2208ac6479dc247efb949bbabca toolkit/skills/code-issue/scripts/test_tracker.py
23
+ f1b3beb83266127ba575d6cd9ba335eb0f71483d25ae4a76b46d715fb3947681 toolkit/skills/code-issue/scripts/tracker.py
24
24
  8e4b4ce1918bbead512d9e975fe5cf39a05c4b7ce4c99f6c39124b1238be4356 toolkit/skills/code-issue/SKILL.md
25
25
  5fec663aa52b7fd2b942f71a0755f0cd109d2273a5cd21c7c24eeed7684a4cc9 toolkit/skills/code-parallel/references/code-quality-reviewer-prompt.md
26
26
  10bc07e6498e6a1e54805cce4d964545f2c1614e6679b0c1c4eb7d17b894e3a6 toolkit/skills/code-parallel/references/implementer-prompt.md
@@ -188,6 +188,23 @@ class TrackerTests(unittest.TestCase):
188
188
  f.write("ISSUE_TRACKER_TOKEN=near-value\n")
189
189
  self.assertEqual(tracker.credentials(tracker.load_profile(path))["token"], "near-value")
190
190
 
191
+ def test_github_check_accepts_the_signed_in_gh_like_every_call_does(self):
192
+ path = self.profile("github")
193
+ del os.environ["ISSUE_TRACKER_TOKEN"]
194
+ real = tracker.gh_token
195
+ try:
196
+ tracker.gh_token = lambda timeout: "gho_from_gh"
197
+ code, out, _ = self.cli("--profile", path, "check")
198
+ self.assertEqual((code, out.splitlines()[-1]), (0, "credentials: ok (via the signed-in gh)"))
199
+ self.assertNotIn("gho_from_gh", out)
200
+ tracker.gh_token = lambda timeout: None
201
+ code, out, _ = self.cli("--profile", path, "check")
202
+ self.assertEqual(code, 2)
203
+ self.assertIn("missing ISSUE_TRACKER_TOKEN", out)
204
+ self.assertIn("gh auth login", out)
205
+ finally:
206
+ tracker.gh_token = real
207
+
191
208
  def test_missing_credential_is_named(self):
192
209
  path = self.profile("jira")
193
210
  del os.environ["ISSUE_TRACKER_USER"]
@@ -415,10 +415,15 @@ def main(argv=None) -> int:
415
415
  creds = credentials(prof)
416
416
  missing = [v for k, v in creds["_names"].items() if k not in creds
417
417
  and not (k == "user" and prof["tracker"] != "jira")]
418
+ via = ""
419
+ if missing and prof["tracker"] == "github" and gh_token(args.timeout):
420
+ missing, via = [], " (via the signed-in gh)" # the same fallback every GitHub call uses
418
421
  print("profile: %s (%s, project %s)" % (path, prof["tracker"], prof["project"]))
419
- print("credentials: " + ("ok" if not missing else "missing " + ", ".join(missing)
420
- + " (environment, or .env beside the profile or at the repository root; never commit it)"))
421
- return 0 if not missing or prof["tracker"] == "github" else 2
422
+ hint = " (environment, or .env beside the profile or at the repository root; never commit it)"
423
+ if prof["tracker"] == "github":
424
+ hint += " or sign in with `gh auth login`"
425
+ print("credentials: " + ("ok" + via if not missing else "missing " + ", ".join(missing) + hint))
426
+ return 0 if not missing else 2
422
427
  ad = adapter(prof, args.timeout)
423
428
  if args.cmd == "list":
424
429
  data = ad.list(mine=not args.all)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sdtk-code-kit",
3
- "version": "0.6.0",
3
+ "version": "0.6.1",
4
4
  "description": "Workflow-first coding process toolkit: start, plan, build, verify, ship, and runtime setup.",
5
5
  "bin": {
6
6
  "sdtk-code": "bin/sdtk-code.js"