You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have some ELisp code which uses the ghub package to find the pull request for a branch in GitHub. Since there are many pull requests open, my code uses ghub-continue inside the callback for ghub-request to retrieve additional page (using unpaginate is inefficient since there are many pages and the pull request I look for is usually on the first few pages).
This strategy used to work, but when I updated to the recent version of this package from MELPA it broke, as in ghub-continue keeps retrieving the same page and never finishes retrieving pages as there is always a next one.
The fix that I found was to update ghub--handle-respones to prepare the next URL even if unpaginate is not set:
diff --git a/ghub.el~ b/ghub.el
index 2658546..c0a7673 100644
--- a/ghub.el~+++ b/ghub.el@@ -525,6 +525,9 @@ and https://debbugs.gnu.org/cgi/bugreport.cgi?bug=34341.")
req headers payload)))))
(when (numberp unpaginate)
(cl-decf unpaginate))
+ ;; AH (30/Jul/2020) update the next link even if we don't unpaginate+ (when next + (setf (ghub--req-url req) (url-generic-parse-url next)))
(or (and next
unpaginate
(or (eq unpaginate t)
For reference, this is the code that I am using (it is part of a larger package):
I have some ELisp code which uses the
ghub
package to find the pull request for a branch in GitHub. Since there are many pull requests open, my code usesghub-continue
inside the callback forghub-request
to retrieve additional page (using unpaginate is inefficient since there are many pages and the pull request I look for is usually on the first few pages).This strategy used to work, but when I updated to the recent version of this package from MELPA it broke, as in
ghub-continue
keeps retrieving the same page and never finishes retrieving pages as there is always a next one.The fix that I found was to update
ghub--handle-respones
to prepare the next URL even ifunpaginate
is not set:For reference, this is the code that I am using (it is part of a larger package):
The text was updated successfully, but these errors were encountered: