danihodovic / django-allauth-ui

Nice looking templates for django-allauth
https://django-allauth-ui.hodovi.ch
MIT License
202 stars 24 forks source link

error in template socialaccount/base.html #37

Closed raayu83 closed 5 months ago

raayu83 commented 7 months ago

I'm trying to set up django-allauth-ui, but I get an error: TemplateDoesNotExist at /accounts/ui/login/

In the template socialaccount/base.html on the first line: {% extends "socialaccount/base.html" %}

What could be the cause of this?

If i changed the order of installed apps to load allauth itself beforehand it barely works (without styling), but this breaks other stuff.

My current allauth version is 0.58.2.

danihodovic commented 7 months ago

Perhaps it's this:

https://github.com/danihodovic/django-allauth-ui#installation

Add django-allauth-ui before django-allauth in your INSTALLED_APPS. See ./tests/settings.py for an example.

raayu83 commented 7 months ago

Thats one of the things I tried. Since I've decided to redirect directly to the SSO and not integrate any UI the topic is not important for me anymore, but might be of interest for others.

raayu83 commented 7 months ago

And thanks for the response :-)

GuilhermeUchoa commented 7 months ago

Esta faltando o "BASE.HTML" Copie o "base.html" de "account" para "socialaccount" que resolve o problema. Sobrescreva este template para salvar

image

localfolkhero commented 6 months ago

Just happened to me to.

Did some investigation and it's an upstream issue with the django-allauth project -- there's no longer a base.html file after version 0.57

Exists: https://github.com/pennersr/django-allauth/blob/0.57.0/allauth/templates/socialaccount/base.html 404: https://github.com/pennersr/django-allauth/blob/0.58.0/allauth/templates/socialaccount/base.html

There is a base_entrance and base_manage html now -- so we can pin to an older version of allauth as a short term workaround :)

localfolkhero commented 6 months ago

Also you could create a custom base.html that did what the old one used to do (which was a passthru to the parent project base.html)

/templates/socialaccount/ {% extends "account/base.html" %}

danihodovic commented 6 months ago

Also you could create a custom base.html that did what the old one used to do (which was a passthru to the parent project base.html)

This sounds like a better future-proof solution.

atopheim commented 5 months ago

I got the same error and implemented a hotfix for this @danihodovic ^

danihodovic commented 5 months ago

According to @atopheim this is fixed in https://github.com/danihodovic/django-allauth-ui/pull/40.

Can you confirm?

fzzylogic commented 5 months ago

Sharing FWIW: Using django-allauth 0.59.0 and django-allauth-ui 0.1.0, noticed that in my local package folder 'env\Lib\site-packages\allauth_ui\templates\socialaccount' (Win cmd env), base.html is missing, whereas it is present when checking out this repo. Created a 'socialaccount' folder in my templates folder and added base.html, which resolved this issue for me. So for me the issue was because of that file being missing from the package downloaded from pypi.