GithubHelp home page GithubHelp logo

Comments (5)

janno42 avatar janno42 commented on August 26, 2024 1

Will look into that. Please use the "evap" user as described in step 3 of the installation section in the readme for now: https://github.com/e-valuation/EvaP?tab=readme-ov-file#installation-for-development

from evap.

Kakadus avatar Kakadus commented on August 26, 2024 1

I also noticed the problem after loading custom data which did not have a superuser.

@richardebeling pointed out that REQUIRED_FIELDS should fix it 👍

from evap.

richardebeling avatar richardebeling commented on August 26, 2024

@Keridos do you want to open a pull request that adds the first_name and last_name fields to the REQUIRED_FIELDS class attribute? I would appreciate it! :)

The relevant lines should be

def create_superuser(self, *, email, password=None, first_name=None, last_name=None):

and
REQUIRED_FIELDS = []

from evap.

Keridos avatar Keridos commented on August 26, 2024

As I got no experience with django projects I have a question there: I can add the fields first_name_given and last_name to the required fields. But does django know that when calling create_superuser that first_name is actually passed from first_name_given?. The variable names in there are a bit confusing.

from evap.

richardebeling avatar richardebeling commented on August 26, 2024

Ah, good point, I think we didn't handle that the way django intends in #1903 (see the change here).

My understanding of the django docs on custom user profile managers is that the argument for create_user and create_superuser probably should also be renamed from first_name to first_name_given. Then, I'd expect that having first_name_given in the REQUIRED_FIELDS works.

(background information regarding the variable naming: Since #1903, we distinguish between first_name_given, the first name that the person legally has and may not have control over, and first_name_chosen, the preferred first name that the person would like to be addressed by)

from evap.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.