pr-merge-queue 0.0.0-stage → 0.0.0

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 (331) hide show
  1. package/LICENSE +201 -0
  2. package/README.md +125 -2
  3. package/dist/claim-pr/claim-pr.d.mts +45 -0
  4. package/dist/claim-pr/claim-pr.d.mts.map +1 -0
  5. package/dist/claim-pr/claim-pr.mjs +217 -0
  6. package/dist/claim-pr/claim-pr.mjs.map +1 -0
  7. package/dist/claim-pr/index.d.mts +2 -0
  8. package/dist/claim-pr/index.d.mts.map +1 -0
  9. package/dist/claim-pr/index.mjs +2 -0
  10. package/dist/claim-pr/index.mjs.map +1 -0
  11. package/dist/cmd/claim-pr.d.mts +3 -0
  12. package/dist/cmd/claim-pr.d.mts.map +1 -0
  13. package/dist/cmd/claim-pr.mjs +20 -0
  14. package/dist/cmd/claim-pr.mjs.map +1 -0
  15. package/dist/cmd/open-pr.d.mts +3 -0
  16. package/dist/cmd/open-pr.d.mts.map +1 -0
  17. package/dist/cmd/open-pr.mjs +20 -0
  18. package/dist/cmd/open-pr.mjs.map +1 -0
  19. package/dist/cmd/pr-report.d.mts +3 -0
  20. package/dist/cmd/pr-report.d.mts.map +1 -0
  21. package/dist/cmd/pr-report.mjs +20 -0
  22. package/dist/cmd/pr-report.mjs.map +1 -0
  23. package/dist/cmd/push-fixed-pr.d.mts +3 -0
  24. package/dist/cmd/push-fixed-pr.d.mts.map +1 -0
  25. package/dist/cmd/push-fixed-pr.mjs +20 -0
  26. package/dist/cmd/push-fixed-pr.mjs.map +1 -0
  27. package/dist/cmd/report-unowned-prs.d.mts +3 -0
  28. package/dist/cmd/report-unowned-prs.d.mts.map +1 -0
  29. package/dist/cmd/report-unowned-prs.mjs +20 -0
  30. package/dist/cmd/report-unowned-prs.mjs.map +1 -0
  31. package/dist/cmd/unblock-prs.d.mts +3 -0
  32. package/dist/cmd/unblock-prs.d.mts.map +1 -0
  33. package/dist/cmd/unblock-prs.mjs +19 -0
  34. package/dist/cmd/unblock-prs.mjs.map +1 -0
  35. package/dist/entry-point.d.mts +3 -0
  36. package/dist/entry-point.d.mts.map +1 -0
  37. package/dist/entry-point.mjs +3 -0
  38. package/dist/entry-point.mjs.map +1 -0
  39. package/dist/lib/cli-args.d.mts +27 -0
  40. package/dist/lib/cli-args.d.mts.map +1 -0
  41. package/dist/lib/cli-args.mjs +55 -0
  42. package/dist/lib/cli-args.mjs.map +1 -0
  43. package/dist/lib/github-api.d.mts +153 -0
  44. package/dist/lib/github-api.d.mts.map +1 -0
  45. package/dist/lib/github-api.mjs +291 -0
  46. package/dist/lib/github-api.mjs.map +1 -0
  47. package/dist/lib/index.d.mts +7 -0
  48. package/dist/lib/index.d.mts.map +1 -0
  49. package/dist/lib/index.mjs +7 -0
  50. package/dist/lib/index.mjs.map +1 -0
  51. package/dist/lib/json.d.mts +12 -0
  52. package/dist/lib/json.d.mts.map +1 -0
  53. package/dist/lib/json.mjs +28 -0
  54. package/dist/lib/json.mjs.map +1 -0
  55. package/dist/lib/log.d.mts +10 -0
  56. package/dist/lib/log.d.mts.map +1 -0
  57. package/dist/lib/log.mjs +13 -0
  58. package/dist/lib/log.mjs.map +1 -0
  59. package/dist/lib/shell.d.mts +18 -0
  60. package/dist/lib/shell.d.mts.map +1 -0
  61. package/dist/lib/shell.mjs +42 -0
  62. package/dist/lib/shell.mjs.map +1 -0
  63. package/dist/lib/time.d.mts +17 -0
  64. package/dist/lib/time.d.mts.map +1 -0
  65. package/dist/lib/time.mjs +35 -0
  66. package/dist/lib/time.mjs.map +1 -0
  67. package/dist/open-pr/github.d.mts +72 -0
  68. package/dist/open-pr/github.d.mts.map +1 -0
  69. package/dist/open-pr/github.mjs +249 -0
  70. package/dist/open-pr/github.mjs.map +1 -0
  71. package/dist/open-pr/index.d.mts +6 -0
  72. package/dist/open-pr/index.d.mts.map +1 -0
  73. package/dist/open-pr/index.mjs +6 -0
  74. package/dist/open-pr/index.mjs.map +1 -0
  75. package/dist/open-pr/main.d.mts +36 -0
  76. package/dist/open-pr/main.d.mts.map +1 -0
  77. package/dist/open-pr/main.mjs +204 -0
  78. package/dist/open-pr/main.mjs.map +1 -0
  79. package/dist/open-pr/options.d.mts +20 -0
  80. package/dist/open-pr/options.d.mts.map +1 -0
  81. package/dist/open-pr/options.mjs +66 -0
  82. package/dist/open-pr/options.mjs.map +1 -0
  83. package/dist/open-pr/steps.d.mts +23 -0
  84. package/dist/open-pr/steps.d.mts.map +1 -0
  85. package/dist/open-pr/steps.mjs +38 -0
  86. package/dist/open-pr/steps.mjs.map +1 -0
  87. package/dist/open-pr/types.d.mts +179 -0
  88. package/dist/open-pr/types.d.mts.map +1 -0
  89. package/dist/open-pr/types.mjs +20 -0
  90. package/dist/open-pr/types.mjs.map +1 -0
  91. package/dist/pr-report/github.d.mts +59 -0
  92. package/dist/pr-report/github.d.mts.map +1 -0
  93. package/dist/pr-report/github.mjs +561 -0
  94. package/dist/pr-report/github.mjs.map +1 -0
  95. package/dist/pr-report/index.d.mts +8 -0
  96. package/dist/pr-report/index.d.mts.map +1 -0
  97. package/dist/pr-report/index.mjs +8 -0
  98. package/dist/pr-report/index.mjs.map +1 -0
  99. package/dist/pr-report/linked-issues.d.mts +15 -0
  100. package/dist/pr-report/linked-issues.d.mts.map +1 -0
  101. package/dist/pr-report/linked-issues.mjs +39 -0
  102. package/dist/pr-report/linked-issues.mjs.map +1 -0
  103. package/dist/pr-report/main.d.mts +42 -0
  104. package/dist/pr-report/main.d.mts.map +1 -0
  105. package/dist/pr-report/main.mjs +163 -0
  106. package/dist/pr-report/main.mjs.map +1 -0
  107. package/dist/pr-report/options.d.mts +36 -0
  108. package/dist/pr-report/options.d.mts.map +1 -0
  109. package/dist/pr-report/options.mjs +90 -0
  110. package/dist/pr-report/options.mjs.map +1 -0
  111. package/dist/pr-report/queue.d.mts +28 -0
  112. package/dist/pr-report/queue.d.mts.map +1 -0
  113. package/dist/pr-report/queue.mjs +74 -0
  114. package/dist/pr-report/queue.mjs.map +1 -0
  115. package/dist/pr-report/render.d.mts +14 -0
  116. package/dist/pr-report/render.d.mts.map +1 -0
  117. package/dist/pr-report/render.mjs +318 -0
  118. package/dist/pr-report/render.mjs.map +1 -0
  119. package/dist/pr-report/repo-settings.d.mts +12 -0
  120. package/dist/pr-report/repo-settings.d.mts.map +1 -0
  121. package/dist/pr-report/repo-settings.mjs +22 -0
  122. package/dist/pr-report/repo-settings.mjs.map +1 -0
  123. package/dist/push-fixed-pr/index.d.mts +2 -0
  124. package/dist/push-fixed-pr/index.d.mts.map +1 -0
  125. package/dist/push-fixed-pr/index.mjs +2 -0
  126. package/dist/push-fixed-pr/index.mjs.map +1 -0
  127. package/dist/push-fixed-pr/push-fixed-pr.d.mts +54 -0
  128. package/dist/push-fixed-pr/push-fixed-pr.d.mts.map +1 -0
  129. package/dist/push-fixed-pr/push-fixed-pr.mjs +172 -0
  130. package/dist/push-fixed-pr/push-fixed-pr.mjs.map +1 -0
  131. package/dist/report-unowned-prs/index.d.mts +2 -0
  132. package/dist/report-unowned-prs/index.d.mts.map +1 -0
  133. package/dist/report-unowned-prs/index.mjs +2 -0
  134. package/dist/report-unowned-prs/index.mjs.map +1 -0
  135. package/dist/report-unowned-prs/report-unowned-prs.d.mts +49 -0
  136. package/dist/report-unowned-prs/report-unowned-prs.d.mts.map +1 -0
  137. package/dist/report-unowned-prs/report-unowned-prs.mjs +127 -0
  138. package/dist/report-unowned-prs/report-unowned-prs.mjs.map +1 -0
  139. package/dist/tsconfig.json +1 -0
  140. package/dist/unblock-prs/auto-fix.d.mts +45 -0
  141. package/dist/unblock-prs/auto-fix.d.mts.map +1 -0
  142. package/dist/unblock-prs/auto-fix.mjs +207 -0
  143. package/dist/unblock-prs/auto-fix.mjs.map +1 -0
  144. package/dist/unblock-prs/checks.d.mts +307 -0
  145. package/dist/unblock-prs/checks.d.mts.map +1 -0
  146. package/dist/unblock-prs/checks.mjs +372 -0
  147. package/dist/unblock-prs/checks.mjs.map +1 -0
  148. package/dist/unblock-prs/claims.d.mts +21 -0
  149. package/dist/unblock-prs/claims.d.mts.map +1 -0
  150. package/dist/unblock-prs/claims.mjs +23 -0
  151. package/dist/unblock-prs/claims.mjs.map +1 -0
  152. package/dist/unblock-prs/config.d.mts +487 -0
  153. package/dist/unblock-prs/config.d.mts.map +1 -0
  154. package/dist/unblock-prs/config.mjs +119 -0
  155. package/dist/unblock-prs/config.mjs.map +1 -0
  156. package/dist/unblock-prs/constants.d.mts +28 -0
  157. package/dist/unblock-prs/constants.d.mts.map +1 -0
  158. package/dist/unblock-prs/constants.mjs +28 -0
  159. package/dist/unblock-prs/constants.mjs.map +1 -0
  160. package/dist/unblock-prs/demotions.d.mts +42 -0
  161. package/dist/unblock-prs/demotions.d.mts.map +1 -0
  162. package/dist/unblock-prs/demotions.mjs +50 -0
  163. package/dist/unblock-prs/demotions.mjs.map +1 -0
  164. package/dist/unblock-prs/github.d.mts +739 -0
  165. package/dist/unblock-prs/github.d.mts.map +1 -0
  166. package/dist/unblock-prs/github.mjs +626 -0
  167. package/dist/unblock-prs/github.mjs.map +1 -0
  168. package/dist/unblock-prs/index.d.mts +25 -0
  169. package/dist/unblock-prs/index.d.mts.map +1 -0
  170. package/dist/unblock-prs/index.mjs +25 -0
  171. package/dist/unblock-prs/index.mjs.map +1 -0
  172. package/dist/unblock-prs/labels.d.mts +49 -0
  173. package/dist/unblock-prs/labels.d.mts.map +1 -0
  174. package/dist/unblock-prs/labels.mjs +49 -0
  175. package/dist/unblock-prs/labels.mjs.map +1 -0
  176. package/dist/unblock-prs/main.d.mts +179 -0
  177. package/dist/unblock-prs/main.d.mts.map +1 -0
  178. package/dist/unblock-prs/main.mjs +640 -0
  179. package/dist/unblock-prs/main.mjs.map +1 -0
  180. package/dist/unblock-prs/merge-after.d.mts +46 -0
  181. package/dist/unblock-prs/merge-after.d.mts.map +1 -0
  182. package/dist/unblock-prs/merge-after.mjs +65 -0
  183. package/dist/unblock-prs/merge-after.mjs.map +1 -0
  184. package/dist/unblock-prs/options.d.mts +35 -0
  185. package/dist/unblock-prs/options.d.mts.map +1 -0
  186. package/dist/unblock-prs/options.mjs +88 -0
  187. package/dist/unblock-prs/options.mjs.map +1 -0
  188. package/dist/unblock-prs/owner.d.mts +32 -0
  189. package/dist/unblock-prs/owner.d.mts.map +1 -0
  190. package/dist/unblock-prs/owner.mjs +63 -0
  191. package/dist/unblock-prs/owner.mjs.map +1 -0
  192. package/dist/unblock-prs/quiet.d.mts +21 -0
  193. package/dist/unblock-prs/quiet.d.mts.map +1 -0
  194. package/dist/unblock-prs/quiet.mjs +42 -0
  195. package/dist/unblock-prs/quiet.mjs.map +1 -0
  196. package/dist/unblock-prs/rebase.d.mts +120 -0
  197. package/dist/unblock-prs/rebase.d.mts.map +1 -0
  198. package/dist/unblock-prs/rebase.mjs +576 -0
  199. package/dist/unblock-prs/rebase.mjs.map +1 -0
  200. package/dist/unblock-prs/release.d.mts +62 -0
  201. package/dist/unblock-prs/release.d.mts.map +1 -0
  202. package/dist/unblock-prs/release.mjs +94 -0
  203. package/dist/unblock-prs/release.mjs.map +1 -0
  204. package/dist/unblock-prs/set-aside-comment.d.mts +20 -0
  205. package/dist/unblock-prs/set-aside-comment.d.mts.map +1 -0
  206. package/dist/unblock-prs/set-aside-comment.mjs +93 -0
  207. package/dist/unblock-prs/set-aside-comment.mjs.map +1 -0
  208. package/dist/unblock-prs/set-aside-detail.d.mts +41 -0
  209. package/dist/unblock-prs/set-aside-detail.d.mts.map +1 -0
  210. package/dist/unblock-prs/set-aside-detail.mjs +56 -0
  211. package/dist/unblock-prs/set-aside-detail.mjs.map +1 -0
  212. package/dist/unblock-prs/skips.d.mts +85 -0
  213. package/dist/unblock-prs/skips.d.mts.map +1 -0
  214. package/dist/unblock-prs/skips.mjs +141 -0
  215. package/dist/unblock-prs/skips.mjs.map +1 -0
  216. package/dist/unblock-prs/stack.d.mts +98 -0
  217. package/dist/unblock-prs/stack.d.mts.map +1 -0
  218. package/dist/unblock-prs/stack.mjs +141 -0
  219. package/dist/unblock-prs/stack.mjs.map +1 -0
  220. package/dist/unblock-prs/triage.d.mts +28 -0
  221. package/dist/unblock-prs/triage.d.mts.map +1 -0
  222. package/dist/unblock-prs/triage.mjs +396 -0
  223. package/dist/unblock-prs/triage.mjs.map +1 -0
  224. package/dist/unblock-prs/types.d.mts +793 -0
  225. package/dist/unblock-prs/types.d.mts.map +1 -0
  226. package/dist/unblock-prs/types.mjs +26 -0
  227. package/dist/unblock-prs/types.mjs.map +1 -0
  228. package/dist/unblock-prs/util.d.mts +23 -0
  229. package/dist/unblock-prs/util.d.mts.map +1 -0
  230. package/dist/unblock-prs/util.mjs +60 -0
  231. package/dist/unblock-prs/util.mjs.map +1 -0
  232. package/dist/unblock-prs/version-pr.d.mts +57 -0
  233. package/dist/unblock-prs/version-pr.d.mts.map +1 -0
  234. package/dist/unblock-prs/version-pr.mjs +79 -0
  235. package/dist/unblock-prs/version-pr.mjs.map +1 -0
  236. package/dist/unblock-prs/watch.d.mts +17 -0
  237. package/dist/unblock-prs/watch.d.mts.map +1 -0
  238. package/dist/unblock-prs/watch.mjs +128 -0
  239. package/dist/unblock-prs/watch.mjs.map +1 -0
  240. package/package.json +118 -3
  241. package/src/claim-pr/claim-pr.mts +380 -0
  242. package/src/claim-pr/claim-pr.test.mts +176 -0
  243. package/src/claim-pr/index.mts +1 -0
  244. package/src/cmd/claim-pr.mts +32 -0
  245. package/src/cmd/open-pr.mts +28 -0
  246. package/src/cmd/pr-report.mts +28 -0
  247. package/src/cmd/push-fixed-pr.mts +36 -0
  248. package/src/cmd/report-unowned-prs.mts +37 -0
  249. package/src/cmd/unblock-prs.mts +24 -0
  250. package/src/entry-point.mts +3 -0
  251. package/src/lib/cli-args.mts +86 -0
  252. package/src/lib/cli-args.test.mts +92 -0
  253. package/src/lib/github-api.mts +463 -0
  254. package/src/lib/github-api.test.mts +40 -0
  255. package/src/lib/index.mts +6 -0
  256. package/src/lib/json.mts +43 -0
  257. package/src/lib/json.test.mts +34 -0
  258. package/src/lib/log.mts +19 -0
  259. package/src/lib/log.test.mts +45 -0
  260. package/src/lib/shell.mts +52 -0
  261. package/src/lib/time.mts +49 -0
  262. package/src/open-pr/README.md +237 -0
  263. package/src/open-pr/github.mts +444 -0
  264. package/src/open-pr/index.mts +5 -0
  265. package/src/open-pr/main.mts +327 -0
  266. package/src/open-pr/options.mts +101 -0
  267. package/src/open-pr/options.test.mts +67 -0
  268. package/src/open-pr/steps.mts +57 -0
  269. package/src/open-pr/steps.test.mts +59 -0
  270. package/src/open-pr/types.mts +42 -0
  271. package/src/pr-report/README.md +244 -0
  272. package/src/pr-report/github.mts +911 -0
  273. package/src/pr-report/index.mts +7 -0
  274. package/src/pr-report/linked-issues.mts +51 -0
  275. package/src/pr-report/linked-issues.test.mts +65 -0
  276. package/src/pr-report/main.mts +257 -0
  277. package/src/pr-report/options.mts +140 -0
  278. package/src/pr-report/queue.mts +125 -0
  279. package/src/pr-report/render.mts +428 -0
  280. package/src/pr-report/render.test.mts +379 -0
  281. package/src/pr-report/repo-settings.mts +34 -0
  282. package/src/push-fixed-pr/index.mts +1 -0
  283. package/src/push-fixed-pr/push-fixed-pr.mts +276 -0
  284. package/src/push-fixed-pr/push-fixed-pr.test.mts +228 -0
  285. package/src/report-unowned-prs/index.mts +1 -0
  286. package/src/report-unowned-prs/report-unowned-prs.mts +190 -0
  287. package/src/report-unowned-prs/report-unowned-prs.test.mts +87 -0
  288. package/src/unblock-prs/README.md +1616 -0
  289. package/src/unblock-prs/auto-fix.mts +334 -0
  290. package/src/unblock-prs/auto-fix.test.mts +159 -0
  291. package/src/unblock-prs/checks.mts +538 -0
  292. package/src/unblock-prs/checks.test.mts +507 -0
  293. package/src/unblock-prs/claims.mts +33 -0
  294. package/src/unblock-prs/claims.test.mts +64 -0
  295. package/src/unblock-prs/config.mts +187 -0
  296. package/src/unblock-prs/config.schema.json +71 -0
  297. package/src/unblock-prs/config.test.mts +139 -0
  298. package/src/unblock-prs/constants.mts +33 -0
  299. package/src/unblock-prs/demotions.mts +73 -0
  300. package/src/unblock-prs/demotions.test.mts +100 -0
  301. package/src/unblock-prs/github.mts +1042 -0
  302. package/src/unblock-prs/github.test.mts +84 -0
  303. package/src/unblock-prs/index.mts +24 -0
  304. package/src/unblock-prs/labels.mts +70 -0
  305. package/src/unblock-prs/main.mts +1051 -0
  306. package/src/unblock-prs/merge-after.mts +117 -0
  307. package/src/unblock-prs/merge-after.test.mts +120 -0
  308. package/src/unblock-prs/options.mts +157 -0
  309. package/src/unblock-prs/owner.mts +91 -0
  310. package/src/unblock-prs/owner.test.mts +114 -0
  311. package/src/unblock-prs/quiet.mts +62 -0
  312. package/src/unblock-prs/quiet.test.mts +175 -0
  313. package/src/unblock-prs/rebase.mts +962 -0
  314. package/src/unblock-prs/release.mts +149 -0
  315. package/src/unblock-prs/release.test.mts +209 -0
  316. package/src/unblock-prs/set-aside-comment.mts +143 -0
  317. package/src/unblock-prs/set-aside-comment.test.mts +148 -0
  318. package/src/unblock-prs/set-aside-detail.mts +82 -0
  319. package/src/unblock-prs/set-aside-detail.test.mts +131 -0
  320. package/src/unblock-prs/skips.mts +215 -0
  321. package/src/unblock-prs/skips.test.mts +280 -0
  322. package/src/unblock-prs/stack.mts +220 -0
  323. package/src/unblock-prs/stack.test.mts +449 -0
  324. package/src/unblock-prs/triage.mts +669 -0
  325. package/src/unblock-prs/triage.test.mts +100 -0
  326. package/src/unblock-prs/types.mts +358 -0
  327. package/src/unblock-prs/util.mts +78 -0
  328. package/src/unblock-prs/util.test.mts +26 -0
  329. package/src/unblock-prs/version-pr.mts +112 -0
  330. package/src/unblock-prs/version-pr.test.mts +78 -0
  331. package/src/unblock-prs/watch.mts +219 -0
@@ -0,0 +1,46 @@
1
+ /**
2
+ * What the declared order means for picking a pull request, as a note, and
3
+ * the order the issues the pull requests close add to it. Reading the
4
+ * `Merge-After:` trailers and the `Start-After:` lines, finding the cycles in
5
+ * them and deciding that a pull request waits is `pr-report-core`'s, because
6
+ * the Pull Requests Manager page draws the same queue.
7
+ */
8
+ import { type RepoRef } from 'pr-report-core';
9
+ import type { Classification, IssueOrder, PullRequest } from './types.mjs';
10
+ /**
11
+ * The note to report instead of picking this pull request while what it
12
+ * must merge after is still open. Picking is all this constrains: a pull
13
+ * request that is already up to date and merging is left to auto-merge,
14
+ * which takes no notice of anything declared here.
15
+ */
16
+ export declare const waitingOnNote: (pr: PullRequest, on: readonly number[], cyclic: boolean, inherited?: readonly number[]) => Classification;
17
+ /** One issue as the closing-issue reads answer it. */
18
+ export type ClosingIssueAnswer = Readonly<{
19
+ number: number;
20
+ /** `OPEN` or `CLOSED`. */
21
+ state: string;
22
+ body: string;
23
+ /** The issues of this repository GitHub records as blocking it. */
24
+ blockedBy: readonly number[];
25
+ }>;
26
+ /**
27
+ * Which open issues each pull request closes, and what those declare with
28
+ * `Start-After:`, for `queueGraph` to inherit.
29
+ *
30
+ * An issue closes when GitHub links it (`linked`, this repository's only) or
31
+ * when the body closes it by keyword, as GitHub marked it in `bodyHtml` —
32
+ * the one way to tell for a stacked pull request, which GitHub links
33
+ * nothing on. `described` is what was read of the keyword ones GitHub did
34
+ * not link; one it would not describe is left out, being unknown.
35
+ */
36
+ export declare const issueOrderOf: (repo: RepoRef, pulls: readonly Readonly<{
37
+ number: number;
38
+ bodyHtml: string;
39
+ linked: readonly ClosingIssueAnswer[];
40
+ }>[], described: ReadonlyMap<number, ClosingIssueAnswer>) => IssueOrder;
41
+ /** The keyword-closed issues of `pulls` that GitHub did not link. */
42
+ export declare const unlinkedClosingIssues: (repo: RepoRef, pulls: readonly Readonly<{
43
+ bodyHtml: string;
44
+ linked: readonly ClosingIssueAnswer[];
45
+ }>[]) => readonly number[];
46
+ //# sourceMappingURL=merge-after.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"merge-after.d.mts","sourceRoot":"","sources":["../../src/unblock-prs/merge-after.mts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAoC,KAAK,OAAO,EAAE,MAAM,gBAAgB,CAAC;AAEhF,OAAO,KAAK,EAAE,cAAc,EAAE,UAAU,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAE3E;;;;;GAKG;AACH,eAAO,MAAM,aAAa,OACpB,WAAW,MACX,SAAS,MAAM,EAAE,UACb,OAAO,cACJ,SAAS,MAAM,EAAE,KAC3B,cAeF,CAAC;AAEF,sDAAsD;AACtD,MAAM,MAAM,kBAAkB,GAAG,QAAQ,CAAC;IACxC,MAAM,EAAE,MAAM,CAAC;IACf,0BAA0B;IAC1B,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,MAAM,CAAC;IACb,mEAAmE;IACnE,SAAS,EAAE,SAAS,MAAM,EAAE,CAAC;CAC9B,CAAC,CAAC;AAEH;;;;;;;;;GASG;AACH,eAAO,MAAM,YAAY,SACjB,OAAO,SACN,SAAS,QAAQ,CAAC;IACvB,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,SAAS,kBAAkB,EAAE,CAAC;CACvC,CAAC,EAAE,aACO,WAAW,CAAC,MAAM,EAAE,kBAAkB,CAAC,KACjD,UA6BF,CAAC;AAEF,qEAAqE;AACrE,eAAO,MAAM,qBAAqB,SAC1B,OAAO,SACN,SAAS,QAAQ,CAAC;IACvB,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,SAAS,kBAAkB,EAAE,CAAC;CACvC,CAAC,EAAE,KACH,SAAS,MAAM,EAUjB,CAAC"}
@@ -0,0 +1,65 @@
1
+
2
+
3
+
4
+
5
+
6
+
7
+
8
+ import { closingKeywordIssuesIn, waitsFor } from 'pr-report-core';
9
+ import { Arr } from 'ts-data-forge';
10
+
11
+
12
+
13
+
14
+
15
+
16
+ export const waitingOnNote = (pr, on, cyclic, inherited = []) => {
17
+ const fromIssues = on.filter((number) => inherited.includes(number));
18
+ return {
19
+ kind: 'note',
20
+ note: `#${pr.number}: Merge-After ${on.map((number) => `#${number}`).join(', ')}, still open${Arr.isNonEmpty(fromIssues)
21
+ ? ` (${fromIssues.map((number) => `#${number}`).join(', ')} from the Start-After of an issue it closes)`
22
+ : ''}${cyclic
23
+ ? ' — and on a Merge-After cycle, so nothing here will move it'
24
+ : ''}`,
25
+ };
26
+ };
27
+
28
+
29
+
30
+
31
+
32
+
33
+
34
+
35
+
36
+
37
+ export const issueOrderOf = (repo, pulls, described) => {
38
+ const mut_issues = new Map(described);
39
+ for (const issue of pulls.flatMap(({ linked }) => linked)) {
40
+ mut_issues.set(issue.number, issue);
41
+ }
42
+ const issues = mut_issues;
43
+ const isOpen = (number) => issues.get(number)?.state.toUpperCase() === 'OPEN';
44
+ return {
45
+ closes: new Map(pulls.map(({ number, bodyHtml, linked }) => [
46
+ number,
47
+ Arr.uniq([
48
+ ...linked.map((issue) => issue.number),
49
+ ...closingKeywordIssuesIn(repo, bodyHtml),
50
+ ]).filter(isOpen),
51
+ ])),
52
+ startAfter: new Map(Array.from(issues.values(), ({ number, body, blockedBy }) => [
53
+ number,
54
+ waitsFor(body, blockedBy),
55
+ ])),
56
+ };
57
+ };
58
+
59
+ export const unlinkedClosingIssues = (repo, pulls) => {
60
+ const linked = new Set(pulls.flatMap((pull) => pull.linked.map(({ number }) => number)));
61
+ return Arr.uniq(pulls.flatMap(({ bodyHtml }) => closingKeywordIssuesIn(repo, bodyHtml)))
62
+ .filter((number) => !linked.has(number))
63
+ .toSorted((a, b) => a - b);
64
+ };
65
+ //# sourceMappingURL=merge-after.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"merge-after.mjs","sourceRoot":"","sources":["../../src/unblock-prs/merge-after.mts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,sBAAsB,EAAE,QAAQ,EAAgB,MAAM,gBAAgB,CAAC;AAChF,OAAO,EAAE,GAAG,EAAE,MAAM,eAAe,CAAC;AAGpC;;;;;GAKG;AACH,MAAM,CAAC,MAAM,aAAa,GAA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C,EAAE,EAAE,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC;AAC/B,CAAC,CAAC"}
@@ -0,0 +1,35 @@
1
+ /** What the command line says, and how it is read. */
2
+ import { Result } from 'ts-data-forge';
3
+ export type Options = Readonly<{
4
+ /** Run one cycle — survey, act on one pull request, report — and exit. */
5
+ once: boolean;
6
+ /** Survey and say what would be done, without rebasing or pushing. */
7
+ dryRun: boolean;
8
+ /** How long to wait between surveys while the list is still changing. */
9
+ activeIntervalSec: number;
10
+ /**
11
+ * How many surveys in a row must see an unchanged list before the wait
12
+ * between them grows to `idleIntervalSec`.
13
+ */
14
+ idleAfter: number;
15
+ /** How long to wait between surveys once the list has sat still. */
16
+ idleIntervalSec: number;
17
+ /** How often to poll the pull request being watched. */
18
+ pollIntervalSec: number;
19
+ /** How long to watch one pull request before giving up on it. */
20
+ watchTimeoutMin: number;
21
+ /**
22
+ * Whether a watched pull request whose failure is only a fixer's diff has
23
+ * the fixer run, amended onto its commit and pushed. See `auto-fix.mts`.
24
+ */
25
+ autoFix: boolean;
26
+ /**
27
+ * The repository, `owner/name`, when it is not the one `origin` names
28
+ * (`lib/github-api.mts`'s `resolveRepo`).
29
+ */
30
+ repo: string | undefined;
31
+ }>;
32
+ export declare const defaultOptions: Options;
33
+ export declare const HELP: string;
34
+ export declare const parseOptions: (args: readonly string[]) => Result<Options | 'help', string>;
35
+ //# sourceMappingURL=options.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"options.d.mts","sourceRoot":"","sources":["../../src/unblock-prs/options.mts"],"names":[],"mappings":"AAAA,sDAAsD;AAGtD,OAAO,EAAE,MAAM,EAAE,MAAM,eAAe,CAAC;AAGvC,MAAM,MAAM,OAAO,GAAG,QAAQ,CAAC;IAC7B,0EAA0E;IAC1E,IAAI,EAAE,OAAO,CAAC;IACd,sEAAsE;IACtE,MAAM,EAAE,OAAO,CAAC;IAChB,yEAAyE;IACzE,iBAAiB,EAAE,MAAM,CAAC;IAC1B;;;OAGG;IACH,SAAS,EAAE,MAAM,CAAC;IAClB,oEAAoE;IACpE,eAAe,EAAE,MAAM,CAAC;IACxB,wDAAwD;IACxD,eAAe,EAAE,MAAM,CAAC;IACxB,iEAAiE;IACjE,eAAe,EAAE,MAAM,CAAC;IACxB;;;OAGG;IACH,OAAO,EAAE,OAAO,CAAC;IACjB;;;OAGG;IACH,IAAI,EAAE,MAAM,GAAG,SAAS,CAAC;CAC1B,CAAC,CAAC;AAEH,eAAO,MAAM,cAAc,EAAE,OAUnB,CAAC;AAEX,eAAO,MAAM,IAAI,QAoBL,CAAC;AAEb,eAAO,MAAM,YAAY,SACjB,SAAS,MAAM,EAAE,KACtB,MAAM,CAAC,OAAO,GAAG,MAAM,EAAE,MAAM,CAoFjC,CAAC"}
@@ -0,0 +1,88 @@
1
+
2
+ import { MERGE_QUEUED_LABEL, SKIP_CI_LABEL } from 'pr-report-core';
3
+ import { Result } from 'ts-data-forge';
4
+ import { parseCommandArgs, positiveInteger } from '../lib/index.mjs';
5
+ export const defaultOptions = {
6
+ once: false,
7
+ dryRun: false,
8
+ activeIntervalSec: 30,
9
+ idleAfter: 10,
10
+ idleIntervalSec: 300,
11
+ pollIntervalSec: 30,
12
+ watchTimeoutMin: 90,
13
+ autoFix: true,
14
+ repo: undefined,
15
+ };
16
+ export const HELP = [
17
+ 'Usage: unblock-prs [options]',
18
+ '',
19
+ `Takes the ${MERGE_QUEUED_LABEL} pull requests in the order they declare with`,
20
+ '`Merge-After:`, one at a time: rebases the one that is out of date with the',
21
+ `default branch, takes ${SKIP_CI_LABEL} off it, and waits for GitHub to merge it.`,
22
+ 'When its checks fail only because a fix: or gen: entry of the check matrices',
23
+ 'left a diff, runs that command, amends the result and pushes it, once.',
24
+ '',
25
+ 'Options:',
26
+ ' --once run one cycle and exit',
27
+ ' --dry-run survey and report what would be done, then exit',
28
+ ` --active-interval <sec> wait between surveys while the list is changing (default ${defaultOptions.activeIntervalSec})`,
29
+ ` --idle-after <n> unchanged surveys before slowing to --idle-interval (default ${defaultOptions.idleAfter})`,
30
+ ` --idle-interval <sec> wait between surveys once the list has sat still (default ${defaultOptions.idleIntervalSec})`,
31
+ ` --poll-interval <sec> wait between polls of the watched pull request (default ${defaultOptions.pollIntervalSec})`,
32
+ ` --watch-timeout <min> give up on a pull request after this long (default ${defaultOptions.watchTimeoutMin})`,
33
+ " --no-auto-fix leave a failure that is only a fixer's diff as it is",
34
+ ' --repo <owner/name> the repository, when origin does not name it',
35
+ ' -h, --help show this help',
36
+ ].join('\n');
37
+ export const parseOptions = (args) => {
38
+ const parsed = parseCommandArgs(args, {
39
+ once: { type: 'boolean', default: false },
40
+ 'dry-run': { type: 'boolean', default: false },
41
+ 'active-interval': { type: 'string' },
42
+ 'idle-after': { type: 'string' },
43
+ 'idle-interval': { type: 'string' },
44
+ 'poll-interval': { type: 'string' },
45
+ 'watch-timeout': { type: 'string' },
46
+ 'no-auto-fix': { type: 'boolean', default: false },
47
+ repo: { type: 'string' },
48
+ });
49
+ if (Result.isErr(parsed)) {
50
+ return parsed;
51
+ }
52
+ if (parsed.value === 'help') {
53
+ return Result.ok('help');
54
+ }
55
+ const values = parsed.value;
56
+ const activeIntervalSec = positiveInteger('active-interval', values['active-interval'], defaultOptions.activeIntervalSec);
57
+ if (Result.isErr(activeIntervalSec)) {
58
+ return activeIntervalSec;
59
+ }
60
+ const idleAfter = positiveInteger('idle-after', values['idle-after'], defaultOptions.idleAfter);
61
+ if (Result.isErr(idleAfter)) {
62
+ return idleAfter;
63
+ }
64
+ const idleIntervalSec = positiveInteger('idle-interval', values['idle-interval'], defaultOptions.idleIntervalSec);
65
+ if (Result.isErr(idleIntervalSec)) {
66
+ return idleIntervalSec;
67
+ }
68
+ const pollIntervalSec = positiveInteger('poll-interval', values['poll-interval'], defaultOptions.pollIntervalSec);
69
+ if (Result.isErr(pollIntervalSec)) {
70
+ return pollIntervalSec;
71
+ }
72
+ const watchTimeoutMin = positiveInteger('watch-timeout', values['watch-timeout'], defaultOptions.watchTimeoutMin);
73
+ if (Result.isErr(watchTimeoutMin)) {
74
+ return watchTimeoutMin;
75
+ }
76
+ return Result.ok({
77
+ once: values.once,
78
+ dryRun: values['dry-run'],
79
+ activeIntervalSec: activeIntervalSec.value,
80
+ idleAfter: idleAfter.value,
81
+ idleIntervalSec: idleIntervalSec.value,
82
+ pollIntervalSec: pollIntervalSec.value,
83
+ watchTimeoutMin: watchTimeoutMin.value,
84
+ autoFix: !values['no-auto-fix'],
85
+ repo: values.repo,
86
+ });
87
+ };
88
+ //# sourceMappingURL=options.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"options.mjs","sourceRoot":"","sources":["../../src/unblock-prs/options.mts"],"names":[],"mappings":"AAAA,sDAAsD;AAEtD,OAAO,EAAE,kBAAkB,EAAE,aAAa,EAAE,MAAM,gBAAgB,CAAC;AACnE,OAAO,EAAE,MAAM,EAAE,MAAM,eAAe,CAAC;AACvC,OAAO,EAAE,gBAAgB,EAAE,eAAe,EAAE,MAAM,kBAAkB,CAAC;AAgCrE,MAAM,CAAC,MAAM,cAAc,GAAY;IACrC,IAAI,EAAE,KAAK;IACX,MAAM,EAAE,KAAK;IACb,iBAAiB,EAAE,EAAE;IACrB,SAAS,EAAE,EAAE;IACb,eAAe,EAAE,GAAG;IACpB,eAAe,EAAE,EAAE;IACnB,eAAe,EAAE,EAAE;IACnB,OAAO,EAAE,IAAI;IACb,IAAI,EAAE,SAAS;CACP,CAAC;AAEX,MAAM,CAAC,MAAM,IAAI,GAAG;IAClB,8BAA8B;IAC9B,EAAE;IACF,aAAa,kBAAkB,+CAA+C;IAC9E,6EAA6E;IAC7E,yBAAyB,aAAa,4CAA4C;IAClF,8EAA8E;IAC9E,wEAAwE;IACxE,EAAE;IACF,UAAU;IACV,mDAAmD;IACnD,4EAA4E;IAC5E,uFAAuF,cAAc,CAAC,iBAAiB,GAAG;IAC1H,2FAA2F,cAAc,CAAC,SAAS,GAAG;IACtH,wFAAwF,cAAc,CAAC,eAAe,GAAG;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B,IAAI,EAAE,MAAM,CAAC,IAAI;KAClB,CAAC,CAAC;AACL,CAAC,CAAC"}
@@ -0,0 +1,32 @@
1
+ /**
2
+ * Who moves each pull request next, as the worker reads it: `pr-report-core`'s
3
+ * `queueOwner`, the one function `pr-report`, `claim-pr` and every other
4
+ * command a session runs read it through, given the facts GitHub returned.
5
+ *
6
+ * The set-aside comes from the records, which by the time triage reads them
7
+ * are what this account's comments say (`settleSkips`): a record the base
8
+ * moved under is pruned as its comment is rewritten as resolved, and one an
9
+ * earlier run left is taken up from its comment. The claims are the ones
10
+ * that still hold (`claims.mts`).
11
+ */
12
+ import { type Claim, type QueueOwner } from 'pr-report-core';
13
+ import type { Classification, PullRequest, SkipRecords } from './types.mjs';
14
+ export type OwnerContext = Readonly<{
15
+ defaultBranch: string;
16
+ skipped: SkipRecords;
17
+ claimed: ReadonlyMap<number, Claim>;
18
+ /** Which open pull request each stacked one is on: child → parent. */
19
+ stackParents: ReadonlyMap<number, number>;
20
+ /** Every number that sits on a `Merge-After` cycle. */
21
+ cyclic: ReadonlySet<number>;
22
+ nowEpochMs: number;
23
+ }>;
24
+ /** Who moves `pr` next, or `undefined` outside the queue. */
25
+ export declare const ownerOf: (pr: PullRequest, context: OwnerContext) => QueueOwner | undefined;
26
+ /**
27
+ * What triage says about a pull request that is not the worker's to move: a
28
+ * note naming its owner and why, with the record's detail when one set it
29
+ * aside. `undefined` for one the worker moves, or one outside the queue.
30
+ */
31
+ export declare const ownerNote: (pr: PullRequest, owner: QueueOwner | undefined, skipped: SkipRecords) => Classification | undefined;
32
+ //# sourceMappingURL=owner.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"owner.d.mts","sourceRoot":"","sources":["../../src/unblock-prs/owner.mts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,EAAc,KAAK,KAAK,EAAE,KAAK,UAAU,EAAE,MAAM,gBAAgB,CAAC;AACzE,OAAO,KAAK,EAAE,cAAc,EAAE,WAAW,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAE5E,MAAM,MAAM,YAAY,GAAG,QAAQ,CAAC;IAClC,aAAa,EAAE,MAAM,CAAC;IACtB,OAAO,EAAE,WAAW,CAAC;IACrB,OAAO,EAAE,WAAW,CAAC,MAAM,EAAE,KAAK,CAAC,CAAC;IACpC,sEAAsE;IACtE,YAAY,EAAE,WAAW,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAC1C,uDAAuD;IACvD,MAAM,EAAE,WAAW,CAAC,MAAM,CAAC,CAAC;IAC5B,UAAU,EAAE,MAAM,CAAC;CACpB,CAAC,CAAC;AAEH,6DAA6D;AAC7D,eAAO,MAAM,OAAO,OACd,WAAW,WACN,YAAY,KACpB,UAAU,GAAG,SA+Bf,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,SAAS,OAChB,WAAW,SACR,UAAU,GAAG,SAAS,WACpB,WAAW,KACnB,cAAc,GAAG,SAkBnB,CAAC"}
@@ -0,0 +1,63 @@
1
+
2
+
3
+
4
+
5
+
6
+
7
+
8
+
9
+
10
+
11
+
12
+ import { queueOwner } from 'pr-report-core';
13
+
14
+ export const ownerOf = (pr, context) => {
15
+ const skip = context.skipped.get(pr.number);
16
+ const claim = context.claimed.get(pr.number);
17
+ return queueOwner({
18
+ number: pr.number,
19
+ labels: pr.labels.map(({ name }) => name),
20
+ isDraft: pr.isDraft,
21
+ fromFork: pr.isCrossRepository,
22
+ headRef: pr.headRefName,
23
+ headSha: pr.headRefOid,
24
+ baseRef: pr.baseRefName,
25
+ defaultBranch: context.defaultBranch,
26
+ stackedOn: context.stackParents.get(pr.number),
27
+ inCycle: context.cyclic.has(pr.number),
28
+ setAside: skip === undefined
29
+ ? undefined
30
+ : {
31
+ kind: 'standing',
32
+ setAside: {
33
+ reason: skip.reason,
34
+ headSha: skip.headSha,
35
+ baseSha: skip.baseSha,
36
+ },
37
+ retry: false,
38
+ },
39
+ claim: claim === undefined ? undefined : { kind: 'standing', claim },
40
+ nowEpochMs: context.nowEpochMs,
41
+ });
42
+ };
43
+
44
+
45
+
46
+
47
+
48
+ export const ownerNote = (pr, owner, skipped) => {
49
+ if (owner === undefined || owner.owner === 'worker') {
50
+ return undefined;
51
+ }
52
+ const skip = skipped.get(pr.number);
53
+ const whose = owner.owner === 'skill'
54
+ ? "the /unblock-prs skill's"
55
+ : owner.owner === 'human'
56
+ ? "a person's"
57
+ : "nobody's — a bug";
58
+ return {
59
+ kind: 'note',
60
+ note: `#${pr.number}: ${whose} (${owner.reason})${skip === undefined ? '' : `; set aside: ${skip.detail}`}`,
61
+ };
62
+ };
63
+ //# sourceMappingURL=owner.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"owner.mjs","sourceRoot":"","sources":["../../src/unblock-prs/owner.mts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,EAAE,UAAU,EAA+B,MAAM,gBAAgB,CAAC;AAczE,6DAA6D;AAC7D,MAAM,CAAC,MAAM,OAAO,GAAG,CACrB,EAAe,EACf,OAAqB,EACG,EAAE;IAC1B,MAAM,IAAI,GAAG,OAAO,CAAC,OAAO,CAAC,GAAG,CAAC,EAAE,CAAC,MAAM,CAAC,CAAC;IAE5C,MAAM,KAAK,GAAG,OAAO,CAAC,OAAO,CAAC,GAAG,CAAC,EAAE,CAAC,MAAM,CAAC,CAAC;IAE7C,OAAO,UAAU,CAAC;QAChB,MAAM,EAAE,EAAE,CAAC,MAAM;QACjB,MAAM,EAAE,EAAE,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,EAAE,IAAI,EAAE,EAAE,EAAE,CAAC,IAAI,CAAC;QACzC,OAAO,EAAE,EAAE,CAAC,OAAO;QACnB,QAAQ,EAAE,EAAE,CAAC,iBAAiB;QAC9B,OAAO,EAAE,EAAE,CAAC,WAAW;QACvB,OAAO,EAAE,EAAE,CAAC,UAAU;QACtB,OAAO,EAAE,EAAE,CAAC,WAAW;QACvB,aAAa,EAAE,OAAO,CAAC,aAA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SAAS,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,gBAAgB,IAAI,CAAC,MAAM,EAAE,EAAE;KAC5G,CAAC;AACJ,CAAC,CAAC"}
@@ -0,0 +1,21 @@
1
+ /**
2
+ * How long the loop sleeps when there is nothing to do: briefly while the
3
+ * list is still changing, so a pull request queued a moment ago is picked up
4
+ * in seconds, and at the idle interval once it has sat still for a while.
5
+ */
6
+ import type { StrictPick } from 'ts-type-forge';
7
+ import type { Options } from './options.mjs';
8
+ import type { Quiet, Survey } from './types.mjs';
9
+ export declare const initialQuiet: Quiet;
10
+ /**
11
+ * The part of a survey triage reads: the base, and for every open pull
12
+ * request its head, merge state, labels, auto-merge, draft flag and body —
13
+ * the body because that is where `Merge-After:` is declared — and what the
14
+ * reviews hold, which triage reads separately: an approval or a resolved
15
+ * conversation is exactly what a held pull request is waiting for. The title
16
+ * is left out, as is the order GitHub lists things in.
17
+ */
18
+ export declare const surveyFingerprint: (survey: StrictPick<Survey, 'baseSha' | 'pullRequests'>, reviewHolds?: readonly string[]) => string;
19
+ export declare const observeSurvey: (quiet: Quiet, fingerprint: string) => Quiet;
20
+ export declare const idleWaitSec: (quiet: Quiet, options: StrictPick<Options, 'activeIntervalSec' | 'idleAfter' | 'idleIntervalSec'>) => number;
21
+ //# sourceMappingURL=quiet.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"quiet.d.mts","sourceRoot":"","sources":["../../src/unblock-prs/quiet.mts"],"names":[],"mappings":"AAAA;;;;GAIG;AAGH,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAChD,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AAC7C,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AAEjD,eAAO,MAAM,YAAY,EAAE,KAGjB,CAAC;AAEX;;;;;;;GAOG;AACH,eAAO,MAAM,iBAAiB,WACpB,UAAU,CAAC,MAAM,EAAE,SAAS,GAAG,cAAc,CAAC,gBACzC,SAAS,MAAM,EAAE,KAC7B,MAgBC,CAAC;AAEL,eAAO,MAAM,aAAa,UAAW,KAAK,eAAe,MAAM,KAAG,KAKrD,CAAC;AAEd,eAAO,MAAM,WAAW,UACf,KAAK,WACH,UAAU,CACjB,OAAO,EACP,mBAAmB,GAAG,WAAW,GAAG,iBAAiB,CACtD,KACA,MAG4B,CAAC"}
@@ -0,0 +1,42 @@
1
+
2
+
3
+
4
+
5
+
6
+ import { isRecord } from 'ts-data-forge';
7
+ export const initialQuiet = {
8
+ fingerprint: undefined,
9
+ unchanged: 0,
10
+ };
11
+
12
+
13
+
14
+
15
+
16
+
17
+
18
+
19
+ export const surveyFingerprint = (survey, reviewHolds = []) => JSON.stringify({
20
+ baseSha: survey.baseSha,
21
+ reviewHolds: reviewHolds.toSorted(),
22
+ pullRequests: survey.pullRequests
23
+ .toSorted((a, b) => a.number - b.number)
24
+ .map((pr) => [
25
+ pr.number,
26
+ pr.headRefOid,
27
+ pr.baseRefName,
28
+ pr.mergeStateStatus,
29
+ pr.isDraft,
30
+ isRecord(pr.autoMergeRequest),
31
+ pr.labels.map((label) => label.name).toSorted(),
32
+ pr.body,
33
+ ]),
34
+ });
35
+ export const observeSurvey = (quiet, fingerprint) => ({
36
+ fingerprint,
37
+ unchanged: quiet.fingerprint === fingerprint ? quiet.unchanged + 1 : 0,
38
+ });
39
+ export const idleWaitSec = (quiet, options) => quiet.unchanged >= options.idleAfter
40
+ ? options.idleIntervalSec
41
+ : options.activeIntervalSec;
42
+ //# sourceMappingURL=quiet.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"quiet.mjs","sourceRoot":"","sources":["../../src/unblock-prs/quiet.mts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC;AAKzC,MAAM,CAAC,MAAM,YAAY,GAAU;IACjC,WAAW,EAAE,SAAS;IACtB,SAAS,EAAE,CAA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r-report-core';
2
+ import { Result } from 'ts-data-forge';
3
+ import { type ApiContext } from '../lib/index.mjs';
4
+ import type { Advanced, AdvancePlan, BranchOf, PullRequest, RebaseFailure, SkipRecords, StackedOn } from './types.mjs';
5
+ /**
6
+ * Force-pushes `sha` to `branch`, leased against `lease`: `moved` when the
7
+ * lease lost to someone else's push, an error when the push was refused for
8
+ * any other reason. The worker's rebases and restacks push through here, and
9
+ * so does `push-fixed-pr`, which a session runs.
10
+ */
11
+ export declare const pushLeased: (branch: string, sha: string, lease: string, cwd?: string) => Promise<Result<'moved' | 'pushed', string>>;
12
+ /**
13
+ * Brings one pull request as close to merging as this script can: onto the
14
+ * tip of the base, with the layers stacked on it carried along, armed, and
15
+ * out from under `skip-ci`.
16
+ *
17
+ * The order is the point. While `skip-ci` is on, the push the rebase makes
18
+ * fires a `synchronize` whose every check workflow skips, so it costs
19
+ * nothing; removing the label afterwards fires `unlabeled`, and the matrix
20
+ * that starts then runs once, on the head that will actually be merged. Doing
21
+ * it the other way round starts a full matrix on the pre-rebase head and has
22
+ * the push cancel it through the concurrency group. Arming comes between
23
+ * the two, so that while it happens the label still holds the merge.
24
+ *
25
+ * A pull request GitHub moved off a stack is rebased with `--onto` from the
26
+ * head its merged parent was merged at, when it still contains that head —
27
+ * GitHub's own rebase on retargeting can fail, and then the branch still
28
+ * carries the parent's commits, whose patches match the squash commit only
29
+ * if nothing changed them on the way in. Otherwise the plain rebase drops
30
+ * them by patch, as it always has.
31
+ *
32
+ * A rebase that changes nothing is a failure only when there was no label to
33
+ * take off either: then GitHub's `BEHIND` or `DIRTY` was stale and the survey
34
+ * has to start over. A paused pull request that is already on top of the base
35
+ * is simply one whose only obstacle was the label.
36
+ *
37
+ * A branch that moves while this is moving it is someone else moving the same
38
+ * pull request — the skill runs beside this script, and a person may push —
39
+ * so it resolves to `moved` and leaves the rest to that someone. Recording it
40
+ * as a failure would set a pull request aside for being worked on, and trying
41
+ * the next candidate would start a second matrix beside the one the other
42
+ * writer is about to start.
43
+ *
44
+ * The version pull request is the exception: only the label comes off it.
45
+ * `changesets/action` rebuilds that branch from the tip of the base itself
46
+ * and force-pushes the result, so rebasing it here would be a second thing
47
+ * force-pushing one branch — and would carry the old version commit onto a
48
+ * tip whose changesets it never consumed. Triage has already established
49
+ * that the branch is on the tip; there is nothing left to move.
50
+ */
51
+ export declare const advance: (api: ApiContext, pr: PullRequest, defaultBranch: string, plan: AdvancePlan) => Promise<Result<Advanced, RebaseFailure>>;
52
+ /**
53
+ * Rebases every pull request GitHub moved onto the default branch when the
54
+ * layer below it merged, and that still carries that layer's commits, off
55
+ * them: `--onto` from the head the layer merged at to the squash commit it
56
+ * merged as, carrying the layers stacked on it along. `stack.mts` says why
57
+ * this waits for no queue, and why the tree comes out as it went in.
58
+ *
59
+ * Nothing is armed or released: `skip-ci` stays as it is, and a push under
60
+ * it fires a `synchronize` whose every check skips. Resolves to whether any
61
+ * branch moved — by this, or by someone else under it — since either makes
62
+ * the heads the survey read stale.
63
+ */
64
+ export declare const restackRetargeted: (api: ApiContext, before: StackedOn | undefined, pullRequests: readonly PullRequest[], defaultBranch: string, dryRun: boolean) => Promise<boolean>;
65
+ /**
66
+ * Rebases the pull requests that asked for it and are paused by `skip-ci`
67
+ * and behind the default branch onto it, carrying the layers stacked on each
68
+ * along, so that a stack waiting for review or for its turn keeps a diff of
69
+ * its own changes only. The push runs no checks: the label skips every workflow.
70
+ * `stack.mts` says which pull requests are eligible.
71
+ *
72
+ * A rebase that conflicts, or a push that is refused, is a set-aside like any
73
+ * other and is returned as one, tied to the head and the base it was tried at.
74
+ * Resolves to those records and whether any branch moved — by this, or by
75
+ * someone else under it — since either makes the survey stale.
76
+ */
77
+ export declare const restackBehind: (pullRequests: readonly PullRequest[], defaultBranch: string, context: Readonly<{
78
+ baseSha: string;
79
+ skipped: SkipRecords;
80
+ owners: ReadonlyMap<number, QueueOwner>;
81
+ dryRun: boolean;
82
+ }>) => Promise<Readonly<{
83
+ skipped: SkipRecords;
84
+ moved: boolean;
85
+ }>>;
86
+ /**
87
+ * Carries every layer stacked on `pr` along after it moved from its old head
88
+ * to `head`: each is replayed with `--onto` from the head it was on to the
89
+ * one that replaced it, lowest layer first so that each finds its own new
90
+ * base already pushed. A layer that cannot be moved, or that someone else
91
+ * moved first, is reported and left where it is, and so is everything on
92
+ * it; none of this stops `pr` itself, whose turn it is. `push-fixed-pr`
93
+ * carries a session's layers along through here too.
94
+ */
95
+ export declare const restack: (pr: BranchOf, head: string, descendants: readonly BranchOf[]) => Promise<void>;
96
+ /**
97
+ * Arms auto-merge on the pull request this cycle picked, having first asked
98
+ * whether it is still what triage saw: open, on the default branch, queued,
99
+ * at `head`. A head other than that is someone else moving it, as in
100
+ * `removeSkipCiLabel`.
101
+ *
102
+ * Called for one it rebases after the push and before `skip-ci` comes off, so
103
+ * that the label holds the merge until the matrix that decides it starts; and
104
+ * for one already up to date before it is watched.
105
+ *
106
+ * Nothing else arms one. `open-pr` opens a pull request with none, and the
107
+ * author queueing it with `merge-queued` is the request to land it. Arming at
108
+ * pick time rather than at opening is what keeps a stacked pull request
109
+ * unarmed while it is stacked: its base is another pull request's branch,
110
+ * which no ruleset covers, so armed there it would merge into that branch
111
+ * the moment nothing held it. It is picked only once GitHub has moved it onto
112
+ * the default branch, where the ruleset gates the merge.
113
+ *
114
+ * `merge-queued` is the only thing read as permission, so one that has lost
115
+ * its auto-merge — GitHub disarms it when the base changes, and a person may
116
+ * switch it off — is armed again when it is next picked. Holding one back is
117
+ * taking `merge-queued` off.
118
+ */
119
+ export declare const armOnPick: (api: ApiContext, pr: PullRequest, head: string, defaultBranch: string) => Promise<Result<'armed' | 'moved', RebaseFailure>>;
120
+ //# sourceMappingURL=rebase.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"rebase.d.mts","sourceRoot":"","sources":["../../src/unblock-prs/rebase.mts"],"names":[],"mappings":"AAUA,OAAO,EAKL,KAAK,UAAU,EAChB,MAAM,gBAAgB,CAAC;AACxB,OAAO,EA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