Skip to content

Commit 524bfd7

Browse files
ThetwambennettscienceCaitlin-Fabian
authored
Release v3.2.0 (#626)
* Allow PaginatedList to use metadata for pagination (#614) * Update `PaginatedList` Based on #605, `PaginatedList` could not process requests which return pagination info in the response body. This update checks for `Link` headers before checking the `meta` property in the response body. * Update based on review * Update pag list test with no header no next meta to run properly. Update changelog. --------- Co-authored-by: Matthew Emond <me@ucf.edu> * New Quizzes (#612) * Begin adding coverage for New Quizzes (WIP) * Finish New Quizzes endpoints * Pin urllib3 to <2 for tests due to issue with requests-mock. jamielennox/requests-mock#228 * Course Create Discussion Attach Files #621 (#622) * Fix issue where Course.create_discussion_topic doesn't accept attachment files * Add file tests for create_discussion_topic * Delete method for course and group pages (#624) * method delete group and course pages, update tests * format fix * Add Caitlin to authors. Add contribution to changelog. Formwatting tweaks. --------- Co-authored-by: Matthew Emond <me@ucf.edu> * Remove Jesse as codeowner. Add Matthew Jones and Brian Bennett * Add support for Python 3.11 (#625) * markdown styling tweak to be in line with prettier's defaults * Bump version to 3.2.0 --------- Co-authored-by: Brian <brian.bennett2@gmail.com> Co-authored-by: Caitlin Fabian <89735646+Caitlin-Fabian@users.noreply.github.com>
1 parent edaf85f commit 524bfd7

23 files changed

+746
-237
lines changed

.github/CODEOWNERS

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
* @Thetwam @jessemcbride
1+
* @Thetwam @bennettscience @jonespm

.github/workflows/run-tests.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ jobs:
1111
runs-on: ubuntu-latest
1212
strategy:
1313
matrix:
14-
python-version: ['3.7', '3.8', '3.9', '3.10']
14+
python-version: ["3.7", "3.8", "3.9", "3.10", "3.11"]
1515

1616
steps:
1717
- uses: actions/checkout@v2

AUTHORS.md

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,17 @@
1-
Authors
2-
=======
1+
# Authors
32

4-
Development Lead
5-
----------------
3+
## Original Authors
64

75
- Matthew Emond <me@ucf.edu> [@Thetwam](https://github.com/Thetwam)
86
- Jesse McBride <jm@ucf.edu> [@jessemcbride](https://github.com/jessemcbride)
97

10-
Patches and Suggestions
11-
-----------------------
8+
## Maintainers
9+
10+
- Matthew Emond [@Thetwam](https://github.com/Thetwam) (Lead)
11+
- Brian Bennett [@bennettscience](https://github.com/bennettscience)
12+
- Matthew Jones [@jonespm](https://github.com/jonespm)
13+
14+
## Patches and Suggestions
1215

1316
- Abrahan Nevarez [@zenith110](https://github.com/zenith110)
1417
- Adrian Goetz [@a-goetz](https://github.com/a-goetz)
@@ -24,10 +27,10 @@ Patches and Suggestions
2427
- [@Birdmaaan4](https://github.com/Birdmaaan4)
2528
- [@blepabyte](https://github.com/blepabyte)
2629
- Bradford Lynch [@bradfordlynch](https://github.com/bradfordlynch)
27-
- Brian Bennett [@bennettscience](https://github.com/bennettscience)
2830
- Bruce Spang [@brucespang](https://github.com/brucespang)
29-
- Catherine Abbruzzese [@cat0698](https://github.com/cat0698))
31+
- Caitlin Fabian [@Caitlin-Fabian](https://github.com/Caitlin-Fabian)
3032
- Cameron Cuff [@ctcuff](https://github.com/ctcuff)
33+
- Catherine Abbruzzese [@cat0698](https://github.com/cat0698)
3134
- Craig Thompson [@craigdsthompson](https://github.com/craigdsthompson)
3235
- Dalton Durst [@UniversalSuperBox](https://github.com/UniversalSuperBox)
3336
- Damian Sweeney [@damianfs](https://github.com/damianfs)
@@ -67,7 +70,6 @@ Patches and Suggestions
6770
- Mark Lalor [@MarkLalor](https://github.com/MarkLalor)
6871
- Markus [@elec3647](https://github.com/elec3647)
6972
- Matthew Fedder [@matthewf-ucsd](https://github.com/matthewf-ucsd)
70-
- Matthew Jones [@jonespm](https://github.com/jonespm)
7173
- Michael Phelps [@nottheswimmer](https://github.com/nottheswimmer)
7274
- Mike Nahmias [@Mike-Nahmias](https://github.com/Mike-Nahmias)
7375
- Mike Suhan [@mikesuhan](https://github.com/mikesuhan)

CHANGELOG.md

Lines changed: 80 additions & 63 deletions
Original file line numberDiff line numberDiff line change
@@ -2,35 +2,51 @@
22

33
## [Unreleased]
44

5+
## [3.2.0] - 2023-05-25
6+
7+
### New Endpoint Coverage
8+
9+
- New Quizzes
10+
- Delete Page in Groups (Thanks, [@Caitlin-Fabian](https://github.com/Caitlin-Fabian))
11+
12+
### General
13+
14+
- Added support for pagination with metadata when headers are missing (Thanks, [@bennettscience](https://github.com/bennettscience))
15+
- Added support for Python 3.11
16+
17+
### Bugfixes
18+
19+
- Fixed an issue where `Course.create_discussion_topic` wouldn't accept attachment files.
20+
521
## [3.1.0] - 2023-04-21
622

723
### New Endpoint Coverage
824

925
- Account Calendars (Thanks, [@dmols](https://github.com/dmols))
10-
- List available account calendars
11-
- Get a single account calendar
12-
- Update a calendar's visibility
13-
- Update many calendars' visibility
14-
- List all account calendars
26+
- List available account calendars
27+
- Get a single account calendar
28+
- Update a calendar's visibility
29+
- Update many calendars' visibility
30+
- List all account calendars
1531
- Enrollments (Thanks, [@svanderwulp](https://github.com/svanderwulp))
16-
- Accept Course Invitation
17-
- Reject Course Invitation
32+
- Accept Course Invitation
33+
- Reject Course Invitation
1834
- File (Thanks, [@bennettscience](https://github.com/bennettscience))
19-
- Update File
35+
- Update File
2036
- JWTs (Thanks [@dmols](https://github.com/dmols))
21-
- Create JWTs
22-
- Refresh JWTs
37+
- Create JWTs
38+
- Refresh JWTs
2339
- Moderation Grading (Moderation Set)
24-
- List students selected for moderation
25-
- Select students for moderation
40+
- List students selected for moderation
41+
- Select students for moderation
2642
- Query Course Events (Thanks, [@dmols](https://github.com/dmols))
27-
- Query by course
28-
- Query by account
43+
- Query by course
44+
- Query by account
2945
- Rubrics (Thanks, [@bennettscience](https://github.com/bennettscience))
30-
- Create, Update, and Delete Rubric Assessments
31-
- Create a Rubric Association
46+
- Create, Update, and Delete Rubric Assessments
47+
- Create a Rubric Association
3248
- Users
33-
- Terminate all user sessions (Thanks, [@lucas-salas](https://github.com/lucas-salas))
49+
- Terminate all user sessions (Thanks, [@lucas-salas](https://github.com/lucas-salas))
3450

3551
### General
3652

@@ -130,11 +146,11 @@
130146

131147
- Custom Gradebook Columns (Thanks,[@aileenpongnon](https://github.com/aileenpongnon))
132148
- Files
133-
- Resolve Path (Thanks,[@dsavransky](https://github.com/dsavransky))
149+
- Resolve Path (Thanks,[@dsavransky](https://github.com/dsavransky))
134150

135151
### Bugfixes
136152

137-
- Fixed an issue where `Quiz.get_quiz_group` incorrectly set `course_id` to the quiz ID. (Thanks,[@hcolclou](https://github.com/hcolclou))
153+
- Fixed an issue where `Quiz.get_quiz_group` incorrectly set `course_id` to the quiz ID. (Thanks,[@hcolclou](https://github.com/hcolclou))
138154
- Fixed an issue where `Course.create_external_tool` didn't accept `client_id` (LTI 1.3 support).
139155
- Fixed an issue where `Module.create_module_item` didn't (Thanks,[@aileenpongnon](https://github.com/aileenpongnon) and [@onomou](https://github.com/onomou))
140156
- Fixed an issue where `Page.revert_to_revision` would incorrectly always set `group_id` to the page ID. Now correctly sets `group_id` or `course_id` appropriately.
@@ -170,9 +186,9 @@
170186
### New Endpoint Coverage
171187

172188
- Enrollment Terms
173-
- Get a Single Enrollment Term (Thanks, [@lcamacho](https://github.com/lcamacho))
189+
- Get a Single Enrollment Term (Thanks, [@lcamacho](https://github.com/lcamacho))
174190
- Files
175-
- Resolve Path for Course (Thanks,[@dsavransky](https://github.com/dsavransky))
191+
- Resolve Path for Course (Thanks,[@dsavransky](https://github.com/dsavransky))
176192
- GraphQL (Thanks,[@jonespm](https://github.com/jonespm))
177193
- Late Policy (Thanks, [@kennygperez](https://github.com/kennygperez))
178194
- Quiz Assignment Overrides (Thanks, [@kennygperez](https://github.com/kennygperez))
@@ -185,11 +201,11 @@
185201
### Deprecation Warnings
186202

187203
- :warning: **_This is the final release with support for Python 2.7_** :warning:
188-
- [Python 2.7 is end-of-life as of January 2020](https://www.python.org/doc/sunset-python-2/)
189-
- Future releases of CanvasAPI will *NOT* support any version of Python 2
204+
- [Python 2.7 is end-of-life as of January 2020](https://www.python.org/doc/sunset-python-2/)
205+
- Future releases of CanvasAPI will _NOT_ support any version of Python 2
190206
- :warning: **_This is the final release with support for Python 3.4_** :warning:
191-
- [Python 3.4 is end-of-life as of March 2019](https://www.python.org/downloads/release/python-3410/)
192-
- Future releases of CanvasAPI will *NOT* support Python 3.4 or below
207+
- [Python 3.4 is end-of-life as of March 2019](https://www.python.org/downloads/release/python-3410/)
208+
- Future releases of CanvasAPI will _NOT_ support Python 3.4 or below
193209
- This is the final deprecation warning for all methods marked as deprecated in this changelog or in our documentation. They will be removed in the next release.
194210

195211
### Bugfixes
@@ -208,7 +224,7 @@
208224

209225
- Assignment Extensions (Thanks, [@ljoks](https://github.com/ljoks))
210226
- AssignmentGroup (Thanks, [@ctcuff](https://github.com/ctcuff))
211-
- List Assignments
227+
- List Assignments
212228
- Authentications Log (Thanks, [@weining-li](https://github.com/weining-li))
213229
- Brand Configs (Thanks, [@bennettscience](https://github.com/bennettscience))
214230
- Comm Messages (Thanks, [@ljoks](https://github.com/ljoks))
@@ -242,30 +258,30 @@
242258
### New Endpoint Coverage
243259

244260
- API Token scopes (Thanks, [@jrsilveti](https://github.com/jrsilveti))
245-
- List scopes
261+
- List scopes
246262
- Account Notifications (Thanks, [@jrsilveti](https://github.com/jrsilveti))
247-
- Show a global notification
248-
- Update a global notification
263+
- Show a global notification
264+
- Update a global notification
249265
- Account Reports (Thanks, [@jrsilveti](https://github.com/jrsilveti))
250-
- Start a report
251-
- Status of a report
252-
- Delete a report
266+
- Start a report
267+
- Status of a report
268+
- Delete a report
253269
- Collaborations (Thanks, [@jrsilveti](https://github.com/jrsilveti))
254-
- List collaborations
255-
- List members of a collaboration
270+
- List collaborations
271+
- List members of a collaboration
256272
- Feature Flags (Thanks, [@cat0698](https://github.com/cat0698))
257-
- List features
258-
- List enabled features
259-
- Get feature flag
260-
- Set feature flag
261-
- Remove feature flag
273+
- List features
274+
- List enabled features
275+
- Get feature flag
276+
- Set feature flag
277+
- Remove feature flag
262278
- Rubric (Thanks, [@cat0698](https://github.com/cat0698))
263-
- Create a single rubric
279+
- Create a single rubric
264280

265281
### General
266282

267283
- Removed overzealous global enabling of `DeprecationWarning`. (Thanks, [@Screeeech](https://github.com/Screeeech))
268-
- *Note:* `DeprecationWarnings` are disabled by default, so you may need to run your code with `python -Wd` to see them.
284+
- _Note:_ `DeprecationWarnings` are disabled by default, so you may need to run your code with `python -Wd` to see them.
269285

270286
## [0.13.0] - 2019-07-08
271287

@@ -278,14 +294,14 @@
278294
- Outcome Import (Thanks, [@jrsilveti](https://github.com/jrsilveti))
279295
- Peer Reviews (Thanks, [@vutoan1245](https://github.com/vutoan1245))
280296
- Planner (Thanks, [@weining-li](https://github.com/weining-li))
281-
- Planner
282-
- Planner Notes
283-
- Planner Overrides
297+
- Planner
298+
- Planner Notes
299+
- Planner Overrides
284300
- Polls (Thanks, [@Goff-Davis](https://github.com/Goff-Davis))
285-
- Poll
286-
- PollChoice
287-
- PollSession
288-
- PollSubmission
301+
- Poll
302+
- PollChoice
303+
- PollSession
304+
- PollSubmission
289305
- Quiz Submission Questions (Thanks, [@bradfordlynch](https://github.com/bradfordlynch))
290306

291307
### General
@@ -391,12 +407,12 @@
391407
### Deprecation Warnings
392408

393409
- :warning: **_Dropped support for Python 3.3_** :warning:
394-
- [Python 3.3 is end-of-life as of September 2017](https://www.python.org/dev/peps/pep-0398/#lifespan)
395-
- Should continue to function in 3.3, but compatibility cannot be guaranteed going forward.
410+
- [Python 3.3 is end-of-life as of September 2017](https://www.python.org/dev/peps/pep-0398/#lifespan)
411+
- Should continue to function in 3.3, but compatibility cannot be guaranteed going forward.
396412
- Several methods in the `Course` and `Section` classes relating to assignments and submissions have been deprecated.
397-
- Comparable methods have been implemented in the `Assignment` and `Submission` classes, as appropriate.
398-
- The deprecated methods now include a warning in the documentation with reference to the replacement. Additionally, the deprecated methods will raise a `DeprecationWarning`.
399-
- These methods will be removed in a future release.
413+
- Comparable methods have been implemented in the `Assignment` and `Submission` classes, as appropriate.
414+
- The deprecated methods now include a warning in the documentation with reference to the replacement. Additionally, the deprecated methods will raise a `DeprecationWarning`.
415+
- These methods will be removed in a future release.
400416
- `Course.list_sections()` has been deprecated. Use `Course.get_sections()` instead.
401417

402418
### Bugfixes
@@ -427,12 +443,12 @@
427443
### New Endpoint Coverage
428444

429445
- Account
430-
- Delete a sub account
446+
- Delete a sub account
431447
- Grading Standards (Thanks, [@JonGuilbe](https://github.com/JonGuilbe))
432448
- Notification Preferences (Thanks, [@a-goetz](https://github.com/a-goetz))
433-
- Update a preference
434-
- Update preferences by category
435-
- Update multiple preferences
449+
- Update a preference
450+
- Update preferences by category
451+
- Update multiple preferences
436452
- Outcomes (Thanks, [@a-goetz](https://github.com/a-goetz))
437453
- Quiz Question Groups (Thanks, [@JonGuilbe](https://github.com/JonGuilbe))
438454
- Rubric (Thanks, [@sigurdurb](https://github.com/sigurdurb))
@@ -443,8 +459,8 @@
443459
- For many endpoints that accept an "object id", either a CanvasAPI Object or integer ID can now be passed. (Thanks, [@a-goetz](https://github.com/a-goetz))
444460
- Added a requester cache that remembers the last 5 requests to Canvas. It can be accessed as the attribute `_cache` of the `requester object`. (e.g. `course._requester._cache`)
445461
- Files can now be downloaded directly from the `File` object in one of two ways: (Thanks, [@DanBrink91](https://github.com/DanBrink91))
446-
1. `get_contents` will directly return the contents of the file. (e.g. `file.get_contents()`)
447-
2. `download` will download the file and save it to the provided path. (e.g. `file.download('example.txt')`)
462+
1. `get_contents` will directly return the contents of the file. (e.g. `file.get_contents()`)
463+
2. `download` will download the file and save it to the provided path. (e.g. `file.download('example.txt')`)
448464
- Moved several methods exclusive to the API Key owner's user from the `User` class to a new class called `CurrentUser`. There is a new method in the `Canvas` class called `get_current_user` to access this object. (e.g. `canvas.get_current_user()`) (Thanks, [@DanBrink91](https://github.com/DanBrink91))
449465

450466
### Bugfixes
@@ -595,17 +611,18 @@ Huge thanks to [@liblit](https://github.com/liblit) for lots of issues, suggesti
595611
- Added contribution guide
596612
- Added Docker container for testing (e.g. with Jenkins)
597613
- Split requirements files into three:
598-
- dev_requirements.txt
599-
- tests_requirements.txt
600-
- requirements.txt
614+
- dev_requirements.txt
615+
- tests_requirements.txt
616+
- requirements.txt
601617

602618
### Bugfixes
603619

604620
- Added some missing parameters
605621
- Fixed some incorrectly defined parameters
606622
- Fixed an issue where tests would fail due to an improperly configured requires block
607623

608-
[Unreleased]: https://github.com/ucfopen/canvasapi/compare/v3.1.0...develop
624+
[Unreleased]: https://github.com/ucfopen/canvasapi/compare/v3.2.0...develop
625+
[3.2.0]: https://github.com/ucfopen/canvasapi/compare/v3.1.0...v3.2.0
609626
[3.1.0]: https://github.com/ucfopen/canvasapi/compare/v3.0.0...v3.1.0
610627
[3.0.0]: https://github.com/ucfopen/canvasapi/compare/v2.2.0...v3.0.0
611628
[2.2.0]: https://github.com/ucfopen/canvasapi/compare/v2.1.0...v2.2.0

README.md

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -13,19 +13,19 @@ CanvasAPI is a Python library for accessing Instructure’s [Canvas LMS API](htt
1313

1414
## Table of Contents
1515

16-
* [CanvasAPI](#canvasapi)
17-
* [Table of Contents](#table-of-contents)
18-
* [Installation](#installation)
19-
* [Documentation](#documentation)
20-
* [Contributing](#contributing)
21-
* [Quickstart](#quickstart)
22-
* [Working with Canvas Objects](#working-with-canvas-objects)
23-
* [Course objects](#course-objects)
24-
* [User objects](#user-objects)
25-
* [Paginated Lists](#paginated-lists)
26-
* [Keyword arguments](#keyword-arguments)
27-
* [CanvasAPI Projects](#canvasapi-projects)
28-
* [Contact Us](#contact-us)
16+
- [CanvasAPI](#canvasapi)
17+
- [Table of Contents](#table-of-contents)
18+
- [Installation](#installation)
19+
- [Documentation](#documentation)
20+
- [Contributing](#contributing)
21+
- [Quickstart](#quickstart)
22+
- [Working with Canvas Objects](#working-with-canvas-objects)
23+
- [Course objects](#course-objects)
24+
- [User objects](#user-objects)
25+
- [Paginated Lists](#paginated-lists)
26+
- [Keyword arguments](#keyword-arguments)
27+
- [CanvasAPI Projects](#canvasapi-projects)
28+
- [Contact Us](#contact-us)
2929

3030
## Installation
3131

@@ -156,12 +156,12 @@ For a more detailed description of how CanvasAPI handles more complex keyword ar
156156

157157
Since its initial release in June 2016, CanvasAPI has amassed over 100 [dependent repositories](https://github.com/ucfopen/canvasapi/network/dependents). Many of these include various tools used to enhance the Canvas experience for both instructors and students. Here are a few popular repositories that use CanvasAPI:
158158

159-
* [Canvas Grab](https://github.com/skyzh/canvas_grab)
160-
* Canvas Grab is the most popular project using CanvasAPI. This tool, with one click, copies all files from Canvas LMS to local directory. CanvasAPI is used in this project to connect to a course and grab its files.
161-
* [Clanvas](https://github.com/marklalor/clanvas)
162-
* Clanvas is a command-line client for Canvas. It uses the already available bash commands plus some additional ones to interact with various features of Canvas from the commmand line.
163-
* [CS221Bot](https://github.com/Person314159/cs221bot)
164-
* CS221Bot is a Discord bot for the CPCS 221 course at University of British Columbia. CanvasAPI is used in this project to connect to and synchronize with a course and get its data, such as announcements, new assignments, and more.
159+
- [Canvas Grab](https://github.com/skyzh/canvas_grab)
160+
- Canvas Grab is the most popular project using CanvasAPI. This tool, with one click, copies all files from Canvas LMS to local directory. CanvasAPI is used in this project to connect to a course and grab its files.
161+
- [Clanvas](https://github.com/marklalor/clanvas)
162+
- Clanvas is a command-line client for Canvas. It uses the already available bash commands plus some additional ones to interact with various features of Canvas from the commmand line.
163+
- [CS221Bot](https://github.com/Person314159/cs221bot)
164+
- CS221Bot is a Discord bot for the CPCS 221 course at University of British Columbia. CanvasAPI is used in this project to connect to and synchronize with a course and get its data, such as announcements, new assignments, and more.
165165

166166
If you have a project that uses CanvasAPI that you'd like to promote, please contact us!
167167

canvasapi/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@
44

55
__all__ = ["Canvas"]
66

7-
__version__ = "3.1.0"
7+
__version__ = "3.2.0"

0 commit comments

Comments
 (0)