Comments (4)
Admin user can be created using manage.py createsuperuser
from django-mongoengine.
I tried creating but i am getting an error and can't login to admin panel:
Traceback (most recent call last): File "manage.py", line 10, in <module> execute_from_command_line(sys.argv) File "/usr/local/lib/python2.7/dist-packages/django/core/management/__init__.py", line 353, in execute_from_command_line utility.execute() File "/usr/local/lib/python2.7/dist-packages/django/core/management/__init__.py", line 345, in execute self.fetch_command(subcommand).run_from_argv(self.argv) File "/usr/local/lib/python2.7/dist-packages/django/core/management/base.py", line 348, in run_from_argv self.execute(*args, **cmd_options) File "/usr/local/lib/python2.7/dist-packages/django/contrib/auth/management/commands/createsuperuser.py", line 52, in execute return super(Command, self).execute(*args, **options) File "/usr/local/lib/python2.7/dist-packages/django/core/management/base.py", line 399, in execute output = self.handle(*args, **options) File "/usr/local/lib/python2.7/dist-packages/django/contrib/auth/management/commands/createsuperuser.py", line 173, in handle self.UserModel._default_manager.db_manager(database).create_superuser(**user_data) File "/usr/local/lib/python2.7/dist-packages/django/contrib/auth/models.py", line 165, in create_superuser return self._create_user(username, email, password, **extra_fields) File "/usr/local/lib/python2.7/dist-packages/django/contrib/auth/models.py", line 147, in _create_user user.set_password(password) File "/home/prasad/Desktop/django-mongoengine/django_mongoengine/mongo_auth/models.py", line 228, in set_password self.save() File "/usr/local/lib/python2.7/dist-packages/mongoengine-0.10.6-py2.7.egg/mongoengine/document.py", line 304, in save File "/usr/local/lib/python2.7/dist-packages/mongoengine-0.10.6-py2.7.egg/mongoengine/base/document.py", line 413, in validate mongoengine.errors.ValidationError: ValidationError (User:None) (Field is required: ['first_name', 'last_name'] Field is required and cannot be empty: ['user_permissions'])
from django-mongoengine.
Update to latest version from github, just fixed this
from django-mongoengine.
Hey thanks a lot. It is working now. 👍
from django-mongoengine.
Related Issues (20)
- How does the Permission are automatically made in auth module? HOT 1
- get_deleted_objects needs to be changed for admin view HOT 1
- Appconfig models is empty OrderedDict HOT 4
- Too slow with >1K documents! HOT 2
- unable to createsuperuser HOT 1
- Sub query using mongoengine
- fixes for django:3.1 import FieldDoesNotExist
- FieldDoesNotExist import Exception HOT 1
- there are many RemovedInDjango40Warning warnings HOT 2
- something wrong with django_mongoengine/forms/document_options.py HOT 4
- mongo-admin from django_mongoengine not supporting FieldList. Throwing ValidationError for list HOT 3
- Cannot import EMPTY_CHANGELIST_VALUE in django VERSION = (3, 0, 8, 'final', 0) HOT 2
- Is this package still maintained? HOT 1
- Admin pagination seems to be off by one. HOT 2
- Do not recommend djongo in the readme. HOT 1
- Is this project alive? HOT 4
- UI issue HOT 2
- Using list in a "not_contains" query HOT 1
- ModuleNotFoundError: No module named 'typing_extensions' HOT 3
- '_thread._local' object has no attribute 'no_dereferencing_class' for simple querryset HOT 7
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from django-mongoengine.