[PATCH] gnu: Add python-canvasapi.

  • Done
  • quality assurance status badge
Details
2 participants
  • John Kehayias
  • Nicolas Goaziou
Owner
unassigned
Submitted by
John Kehayias
Severity
normal

Debbugs page

John Kehayias wrote 3 years ago
(name . Guix-patches)(address . guix-patches@gnu.org)
uLq9C09DP7ZZppiRYayaK8_Yb34csTYJfXrxCJCO4GpQhDK0GFDXhZEz34zjnsjFTeFxoQ0UKhaPopdKksKGWhKoOGnzYUqzFD_KaWbozf0=@protonmail.com
This is a patch to add the canvasapi python package, that lets you communicate with Instructure's Canvas platform (used at universities for course materials). I've tested it builds and works.
From 4aa7894d3786c1fe490d97b4b05c267956302d83 Mon Sep 17 00:00:00 2001
From: John Kehayias <john.kehayias@protonmail.com>
Date: Fri, 24 Dec 2021 10:34:21 -0500
Subject: [PATCH] gnu: Add python-canvasapi.

* gnu/packages/python-web.scm (python-canvasapi): New variable.
---
gnu/packages/python-web.scm | 20 ++++++++++++++++++++
1 file changed, 20 insertions(+)

Toggle diff (40 lines)
diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm
index 61a34bfc63..d2026af2c6 100644
--- a/gnu/packages/python-web.scm
+++ b/gnu/packages/python-web.scm
@@ -47,6 +47,7 @@
;;; Copyright © 2021 Arun Isaac <arunisaac@systemreboot.net>
;;; Copyright © 2021 jgart <jgart@dismail.de>
;;; Copyright © 2021 Alice Brenon <alice.brenon@ens-lyon.fr>
+;;; Copyright © 2021 John Kehayias <john.kehayias@protonmail.com>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -4198,6 +4199,25 @@ (define-public python-yarl
for URL parsing and changing.")
(license license:asl2.0)))
+(define-public python-canvasapi
+ (package
+ (name "python-canvasapi")
+ (version "2.2.0")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (pypi-uri "canvasapi" version))
+ (sha256
+ (base32 "0qizqj5l6bgfmw41hhh1d1iypv5y1lb3r6v0yks957dc7ivxp1sh"))))
+ (build-system python-build-system)
+ (propagated-inputs (list python-pytz python-requests))
+ (home-page "https://github.com/ucfopen/canvasapi")
+ (synopsis "API wrapper for the Canvas LMS")
+ (description "CanvasAPI is a Python library for accessing
+Instructure’s Canvas LMS API. The library enables developers to
+programmatically manage Canvas courses, users, gradebooks, and more.")
+ (license license:expat)))
+
(define-public python-google
(package
(name "python-google")
--
2.34.1
John Kehayias wrote 3 years ago
[PATCH v2] gnu: Add python-canvasapi.
(name . 52780@debbugs.gnu.org)(address . 52780@debbugs.gnu.org)
5yIzxI854z_hwfXEvFhTZRWu0L1oI3M5jCc6-gN40iFPW6vIqHk9ElrQkLcxxmBcrvR9M_buRv_oXJrydxdnKrwEN9vdT3_I_CKPqBSwA1M=@protonmail.com
Updated after discussion on IRC to use the GitHub source which includes tests. native-input added to run the tests, all pass.
From efae6b303534bd43ab8f7f260efbe17448cc677c Mon Sep 17 00:00:00 2001
From: John Kehayias <john.kehayias@protonmail.com>
Date: Tue, 11 Jan 2022 16:37:59 -0500
Subject: [PATCH] gnu: Add python-canvasapi.

* gnu/packages/python-web.scm (python-canvasapi): New variable.
---
gnu/packages/python-web.scm | 24 ++++++++++++++++++++++++
1 file changed, 24 insertions(+)

Toggle diff (37 lines)
diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm
index aaf8a57f6f..416703c143 100644
--- a/gnu/packages/python-web.scm
+++ b/gnu/packages/python-web.scm
@@ -4264,6 +4264,30 @@ (define-public python-yarl
for URL parsing and changing.")
(license license:asl2.0)))
+(define-public python-canvasapi
+ (package
+ (name "python-canvasapi")
+ (version "2.2.0")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/ucfopen/canvasapi")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "0i13wrq2czcaz3h98pvnsl237104v611y9636jf32b1nn76sbp0p"))))
+ (build-system python-build-system)
+ (propagated-inputs (list python-pytz python-requests))
+ (native-inputs (list python-requests-mock))
+ (home-page "https://github.com/ucfopen/canvasapi")
+ (synopsis "API wrapper for the Canvas LMS")
+ (description
+ "CanvasAPI is a Python library for accessing Instructure’s Canvas LMS API.
+The library enables developers to programmatically manage Canvas courses,
+users, gradebooks, and more.")
+ (license license:expat)))
+
(define-public python-google
(package
(name "python-google")
--
2.34.0
John Kehayias wrote 3 years ago
[PATCH v3] gnu: Add python-canvasapi.
(name . 52780@debbugs.gnu.org)(address . 52780@debbugs.gnu.org)
F1KrHzCSP7kdoF9C8yxeE06kA8zaKg6zm5187DH23xqsgbcynlkrxWPcJpcODUeeL4ufEH199GVEmIioD2gCkGdWLqxEbTWZdLYqmn2jhVU=@protonmail.com
Toggle quote (2 lines)
> Updated after discussion on IRC to use the GitHub source which includes tests. native-input added to run the tests, all pass.

And of course left off the copyright line from earlier, added back.
From 69c1f68741ca7be3650e87001869b82c7f2acd17 Mon Sep 17 00:00:00 2001
From: John Kehayias <john.kehayias@protonmail.com>
Date: Tue, 11 Jan 2022 16:37:59 -0500
Subject: [PATCH] gnu: Add python-canvasapi.

* gnu/packages/python-web.scm (python-canvasapi): New variable.
---
gnu/packages/python-web.scm | 25 +++++++++++++++++++++++++
1 file changed, 25 insertions(+)

Toggle diff (45 lines)
diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm
index aaf8a57f6f..951ab10903 100644
--- a/gnu/packages/python-web.scm
+++ b/gnu/packages/python-web.scm
@@ -47,6 +47,7 @@
;;; Copyright © 2021 Arun Isaac <arunisaac@systemreboot.net>
;;; Copyright © 2021 jgart <jgart@dismail.de>
;;; Copyright © 2021 Alice Brenon <alice.brenon@ens-lyon.fr>
+;;; Copyright © 2022 John Kehayias <john.kehayias@protonmail.com>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -4264,6 +4265,30 @@ (define-public python-yarl
for URL parsing and changing.")
(license license:asl2.0)))
+(define-public python-canvasapi
+ (package
+ (name "python-canvasapi")
+ (version "2.2.0")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/ucfopen/canvasapi")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "0i13wrq2czcaz3h98pvnsl237104v611y9636jf32b1nn76sbp0p"))))
+ (build-system python-build-system)
+ (propagated-inputs (list python-pytz python-requests))
+ (native-inputs (list python-requests-mock))
+ (home-page "https://github.com/ucfopen/canvasapi")
+ (synopsis "API wrapper for the Canvas LMS")
+ (description
+ "CanvasAPI is a Python library for accessing Instructure’s Canvas LMS API.
+The library enables developers to programmatically manage Canvas courses,
+users, gradebooks, and more.")
+ (license license:expat)))
+
(define-public python-google
(package
(name "python-google")
--
2.34.0
Nicolas Goaziou wrote 3 years ago
(name . John Kehayias via Guix-patches via)(address . guix-patches@gnu.org)(name . John Kehayias)(address . john.kehayias@protonmail.com)(name . 52780@debbugs.gnu.org)(address . 52780-done@debbugs.gnu.org)
87fsps63z5.fsf@nicolasgoaziou.fr
Hello,

John Kehayias via Guix-patches via <guix-patches@gnu.org> writes:

Toggle quote (4 lines)
> Subject: [PATCH] gnu: Add python-canvasapi.
>
> * gnu/packages/python-web.scm (python-canvasapi): New variable.

Applied. Thank you.

Regards,
--
Nicolas Goaziou
Closed
?
Your comment

This issue is archived.

To comment on this conversation send an email to 52780@debbugs.gnu.org

To respond to this issue using the mumi CLI, first switch to it
mumi current 52780
Then, you may apply the latest patchset in this issue (with sign off)
mumi am -- -s
Or, compose a reply to this issue
mumi compose
Or, send patches to this issue
mumi send-email *.patch
You may also tag this issue. See list of standard tags. For example, to set the confirmed and easy tags
mumi command -t +confirmed -t +easy
Or, remove the moreinfo tag and set the help tag
mumi command -t -moreinfo -t +help