1
0
Fork 0
Commit graph

799 commits

Author SHA1 Message Date
0b87aacfce pylint: enable useless-suppression lint and perform cleanup 2024-07-27 03:47:35 -03:00
03ac846b5d Migrate from pytz to zoneinfo 2024-04-25 10:14:07 +02:00
624115bf11 Use headers dict instead of HTTP_* kwargs or request.META 2024-04-25 10:13:21 +02:00
e1fd57a1d6 Fix constructor arguments to SessionMiddleware in tests 2024-04-25 10:13:21 +02:00
92a94d2fdc django.utils.timezone.utc alias is deprecated 2024-04-25 10:12:30 +02:00
4f58b11330 Include the correct protocol and port in remote IDs 2024-04-24 15:35:19 +02:00
c42db40a63 Construct absolute URLs with the correct protocol and port 2024-04-24 15:30:47 +02:00
f24fdf73b5 Update to match newer code style 2024-04-24 15:08:48 +02:00
839ab2fafd
Merge branch 'main' into move-fix 2024-04-24 14:56:32 +02:00
6684d60526
refactor Move for more redundancy
As outlined in #3354, a use `Move` fails if the user is moving from a BookWyrm server to another BookWrym server.
This is because:

1. the original code did not announce changes to alsoKnownAs;
2. the original code always checked the locally saved profile rather than refetching the remote data;

This commit fixes both these problems by forcing `MoveUser` to always perform a "refresh" of the local data from the remote, and by saving the user with broadcast=True when updating alsoKnownAs ids.
2024-04-22 13:35:08 +10:00
d48d312c0a
Merge branch 'main' into user-export 2024-04-13 12:26:13 +10:00
ffee29d8e2 Fix resource leaks
Rewrite places where files (or other resources) are opened but not closed to "with" blocks, which
automatically call close() at the end of the scope.

Also simplify some tests where images need to be saved to a model field: an opened file can be
passed directly to FileField.save().
2024-03-29 20:14:10 +01:00
0ac9d12d1c Merge branch 'main' into user-export 2024-03-29 14:23:10 +01:00
518da3b9cf Merge from main into 'user-export'
Conflicts:
	bookwyrm/models/bookwyrm_export_job.py
	requirements.txt
2024-03-18 14:47:34 -03:00
90bd893568 Fix remaining instances of bad-classmethod-argument 2024-03-17 21:28:55 -03:00
e2c9ea3cd2 Fix instances of bad-classmethod-argument in recently edited files 2024-03-17 21:28:55 -03:00
4b9fe0af0c Remove nesting in several with..patch calls 2024-03-17 20:57:39 -03:00
1b9e0546e6 Bracket-wrap calls to patch() for better readability 2024-03-17 20:34:12 -03:00
e6b6bd648d
Merge branch 'main' into move-ratings-and-reviews-when-switching-editions 2024-02-21 18:42:18 -03:00
dd1999eb8e
Adds view tests for shelf filters (#3162)
* Adds test file

* Adds success assertion

* Updates tests

* Updates shelf books creation

* Updates assertion to use isbn for Edition model

* Updates query

* trigger workflow test

* Updates validate_html

* Updates comment and test

* Fixes none test

* Adds management command to clear all deleted user data

* Adds success message

---------

Co-authored-by: Mouse Reeve <mousereeve@riseup.net>
Co-authored-by: Mouse Reeve <mouse.reeve@gmail.com>
2024-02-20 16:25:01 -08:00
37aa7ad2f6 Merge branch 'freeform-page-number' of github.com:WesleyAC/bookwyrm into WesleyAC-freeform-page-number 2024-02-03 07:38:02 -08:00
765fc1e43d
fix tests 2024-01-29 12:28:37 +11:00
2c231acebe
linting and tests 2024-01-28 20:35:47 +11:00
ddbda3ab9c Fix test_export 2024-01-16 08:12:59 +00:00
854eb36618 Export bookshelves and review date 2024-01-13 16:47:51 +00:00
93cab480d6 Code format 2024-01-06 09:50:14 +01:00
6cd2c91135 Allow page numbers to be text, instead of integers.
Fixes: #2640
2024-01-04 19:09:39 -05:00
ebcc81dd73 Revert changes to default book
These changes were introduced by mistake in my previous commit.
2024-01-04 11:33:26 +01:00
30c9ec9611 Prevent lint error
See @hughrun 's explanation https://github.com/bookwyrm-social/bookwyrm/pull/3189#issuecomment-1876145423
2024-01-04 11:28:17 +01:00
ae5950f187 Add readthrough fields to text_export.py 2024-01-04 11:10:38 +01:00
ca79cb1ca7
Merge pull request #3054 from bookwyrm-social/user-migration
User migration via export file
2024-01-01 19:04:43 -08:00
4bfa1ca5b8
Merge pull request #3124 from hughrun/softblock
Allow removing followers and fix follow rejections
2023-12-11 19:49:45 -08:00
9d502f5ee2
Use setUpTestData() to speed up tests
Pylint's `bad-classmethod-argument` is disabled for each definition
to avoid rewriting the method bodies just to rename `self` → `cls`.
This can be done gradually, as the setUpTestData methods are modified
along the way.
2023-12-11 19:40:30 -03:00
7f55495287 Merge branch 'move-ratings-and-reviews-when-switching-editions' of github.com:mattlehrer/bookwyrm into move-ratings-and-reviews-when-switching-editions 2023-11-30 11:15:33 +01:00
31a78a5c9e linted 2023-11-30 11:13:11 +01:00
0276c15948
Merge branch 'main' into user-migration 2023-11-22 21:00:04 +11:00
c6dea2523c
Merge branch 'main' into softblock 2023-11-22 20:06:02 +11:00
6ba7418121
improve tests and minor cleanup 2023-11-22 20:04:17 +11:00
2c9ebba5d7
fix reject PR
- rationalise activitypub.Reject and fix model being undefined
- fix not being able to follow users from followers page: 'delete' option now in user_options dropdown
- revert bookwyrm.js
- fix delete_follow_request deleting instead of rejecting
- add user id to 'remove-follow' path
2023-11-21 20:13:56 +11:00
b6325da9ab
Update bookwyrm/tests/views/admin/test_themes.py
Co-authored-by: Adeodato Simó <73768+dato@users.noreply.github.com>
2023-11-20 10:37:12 -08:00
179dbd75aa Adds tests 2023-11-20 10:23:59 -08:00
6933f70af3
Merge branch 'bookwyrm-social:main' into move-ratings-and-reviews-when-switching-editions 2023-11-20 09:31:45 +01:00
d94b27b723
Merge branch 'main' into user-migration 2023-11-19 19:18:22 -08:00
bd920a4630 move reviews to new edition 2023-11-16 10:38:45 +01:00
7684101f15 move ratings to new edition 2023-11-16 10:38:41 +01:00
d5762f1d52
Merge branch 'main' into user-migration 2023-11-13 21:17:07 +11:00
e928027e16
Merge from main for up-to-date migrations 2023-11-09 14:00:14 -03:00
e7a1572450
Merge pull request #3086 from bookwyrm-social/user-deletion
Erase user data and statuses on account deletion
2023-11-06 09:49:06 -08:00
27d99a0094 Removes failsafe that was overzealous 2023-11-05 19:47:32 -08:00
a93519ec3e
Merge pull request #3027 from dato/find_links_wrapped_punct
Fix parsing of punctuation in format_links()

fixes #2993  
fixes #3049
2023-11-06 09:42:57 +11:00