[Answer]-Django import User independently

0👍

You need to perform a few tasks manually when writing a standalone Django script.

1👍

I suggest you create a custom management command if you plan on running this command more than once. It only requires a small amount of boilerplate code and a special directory within your app. It will solve your problem and help improve the long term maintainability of your project.

https://docs.djangoproject.com/en/dev/howto/custom-management-commands/

👤Alex

Leave a comment