From 20f443453d1df82926700687b97646e2b4842a3a Mon Sep 17 00:00:00 2001 From: Jan Giacomelli Date: Fri, 20 Dec 2024 08:07:28 +0100 Subject: [PATCH] Chapter 19 review --- chapter_19_spiking_custom_auth.asciidoc | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/chapter_19_spiking_custom_auth.asciidoc b/chapter_19_spiking_custom_auth.asciidoc index 868fa281a..ecd1a4536 100644 --- a/chapter_19_spiking_custom_auth.asciidoc +++ b/chapter_19_spiking_custom_auth.asciidoc @@ -397,6 +397,7 @@ We've got enough things we need to learn as it is! Let's switch on our new accounts app in _settings.py_: +// JAN: I have "lists.apps.ListsConfig" inside INSTALLED_APPS "lists" [role="sourcecode"] .src/superlists/settings.py (ch18l008-1) @@ -495,6 +496,8 @@ class ListUser(AbstractBaseUser): ---- ==== +// JAN: Do we really need is_staff here? + That's what I call a minimal user model! One field, none of this firstname/lastname/username nonsense, and, pointedly, no password! @@ -883,6 +886,7 @@ selenium.common.exceptions.NoSuchElementException: Message: Unable to locate element: input[name=email]; [...] [...] ---- +// JAN: I see the following exception: ModuleNotFoundError: No module named 'accounts', not the selenium one. We should remove all changes from settings.py/urls.py as well The first thing it wants us to do is add an email input element. Bootstrap has some built-in classes for navigation bars, so we'll use them, and include a @@ -1376,7 +1380,7 @@ class Token(models.Model): uid = models.CharField(default=uuid.uuid4, max_length=40) ---- ==== - +// JAN: I think it would be worth mentioning why uuid.uuid4 isn't called. Can be confusing for people when first seeing this And, perhaps with a bit more wrangling of migrations, that should get us to passing tests: