Django community: RSS
This page, updated regularly, aggregates Django Q&A from the Django community.
-
phyton JSONDecodeError Extra data
Why can such an error occur? Traceback At some point, users going to the site catch a 500 error, the backend accepts json from another application -
React and nginx: refused to connect to localhost
I have my React (frontend) and Django REST (backend) running on a remote Ubuntu server with nginx. I also have a simple reverse proxy defined in conf.d/bookmarks.conf to manage all of that: server { listen 80; listen [::]:80; location /api/ { # Backend proxy_pass http://127.0.0.1:1337/api/; } location / { # Frontend root /var/www/bookmarks/html/; index index.html; try_files $uri $uri/ /index.html; } } I run my Django app with runserver python manage.py runserver 127.0.0.1:1337, and React static files are stored in the folder described above I try to connect to API with React: const generateOpendIdLink = async () => { const generateOpendIdLinkEndpoint = 'http://127.0.0.1/api/opendid-link-generator/'; const requestOptions = { method: 'GET', headers: {'Content-Type': 'application/json'}, }; try { const response = await fetch(generateOpendIdLinkEndpoint, requestOptions); if (response.status == 200) { ... }; } catch (error) { console.log(error); }; }; And get an error GET http://127.0.0.1/api/opendid-link-generator/ net::ERR_CONNECTION_REFUSED This is quite odd, because I could connect to API from the web no problem: running the same GET on the server IP address http://XX.XXX.XX.XX/api/opendid-link-generator/ from Postman works as expected. This is also true when I change 127.0.0.1 for the server IP in the React code, it all starts to work. I also set ALLOWED_HOSTS = ['*'] for test … -
copy a model instance and update a filed in new copy
this is my model. I want to make a copy from my model with copy function. and update the created_time to this time and eventually return the post id from django.db import models from django.utils import timezone class Author(models.Model): name = models.CharField(max_length=50) class BlogPost(models.Model): title = models.CharField(max_length=250) body = models.TextField() author = models.ForeignKey(Author, on_delete=models.CASCADE) date_created = models.DateTimeField(auto_now_add=True) def copy(self): blog = BlogPost.objects.get(pk=self.pk) comments = blog.comment_set.all() blog.pk = None blog.save() for comment in comments: comment.pk = None comment.blog_post = blog comment.save() return blog.id class Comment(models.Model): blog_post = models.ForeignKey(BlogPost, on_delete=models.CASCADE) text = models.CharField(max_length=500) I also want copy function makes a copy from post and comments, would you help me to correct my code and update the time in my function. thank you. -
how do I configure my Django app to use Dreamhost email?
I created a django app that has a contact form where users can send an email to the company (The email configured in the APP) I am getting "SERVER ERROR 500" After reading this: django email settings on dreamhost I tried the following format in my settings.py: EMAIL_HOST = 'smtp.dreamhost.com' # I also tried pop.dreamhost.com / imap.dreamhost.com with their respective port numbers. EMAIL_USE_TLS = True # I also tried EMAIL_USE_SSL EMAIL_PORT = 587 # I also tried 25 and 465 EMAIL_HOST_PASSWORD = 'EMAIL_PASSWORD' # also tried SERVER_PASSWORD EMAIL_HOST_USER = 'my_dreamhost_email' # Also tried admin@mydomain.com EMAIL_SUBJECT_PREFIX = '' SERVER_EMAIL = 'my_dreamhost_email' # also tried 'localhost' / 'admin@mydomain.com' ADMINS = (('Jack Shedd', 'jack@example.com'),) # I used my details PS: The app is working perfectly if I use gmail What are the correct details to use? Thanx in advance -
Issue displaying question for answer in views.py
I ran into a problem I have questions that are related to items_buy_id , there are also choices that are related to question_id questions Questions items_buy_id It turns out to connect And with the choice you will not contact as it should My models.py from django.db import models from datetime import datetime from phonenumber_field.modelfields import PhoneNumberField from django_resized import ResizedImageField from email.policy import default from django.utils.translation import gettext_lazy class Items_buy(models.Model): class Meta: db_table = 'items_buy' verbose_name = 'Телефон который покупаем' verbose_name_plural = 'Телефоны которые покупаем' image_phone = ResizedImageField(size=[100,100], upload_to='for_sell/',verbose_name='Фотография модели телефона') model_produkt = models.TextField(max_length=80, verbose_name='Модель продукта ') text = models.TextField(max_length=500, verbose_name='Текст') max_prise_iphone = models.FloatField(verbose_name='Максимальная цена telefoha') image_phone_for_buy_bord = ResizedImageField(size=[100,100],upload_to='for_sell/',verbose_name='Фотография модели телефона ha prodazy') def __str__(self): return self.model_produkt class Question(models.Model): class Meta: db_table = 'question' verbose_name = 'Вопрос к телефону' verbose_name_plural = 'Вопросы к телефону' items_buy_id = models.ForeignKey(Items_buy, on_delete=models.RESTRICT) title = models.CharField(max_length=150,verbose_name='Заголовок вопросa') question_text =models.TextField(max_length=100, verbose_name='Заголовок вопросa text') max_prise_qustion = models.FloatField(verbose_name='Максимальная цена') def __str__(self): return self.title class Choice(models.Model): class Meta: db_table = 'choice' verbose_name = 'Выбор ответа' verbose_name_plural = 'Выбор ответов' #items_buy_id = models.ForeignKey(Items_buy, on_delete=models.RESTRICT) question_id = models.ForeignKey(Question, on_delete=models.RESTRICT) title = models.CharField(max_length=1000, verbose_name='Заголовок выбора') points = models.FloatField(verbose_name='Цена ответа') #lock_other = models.BooleanField(default=False, verbose_name='Смотреть другой вариант ответа') def __str__(self): return self.title My urls.py … -
Django advanced query on the same model
I have a Kit and KitInOut models: class Kit(models.Model): name = models.CharField(max_length=255, blank=True, null=True) class KitInOut(models.Model): kit = models.ForeignKey(Kit, on_delete=models.CASCADE) out = models.BoolField(default=True) creation_timestamp = models.DateTimeField() I want to find out which kits are out and dont have the the same kit again in the resulting query, which is something like : "select * from KitInOut where, for each kit k, keep it in the result if it went out** (kit_went_out=1) and there's no other KitInOut k2 where k2.kit=k and k2.creation_timestamp > k.creation_timestamp" Here's the code I have, which is so un-optimized that I can't use it with more than 500 KitInOut rows: k_in_out_s = KitInOut.objects.filter(out=True) result = [] for obj in k_in_out_s: if (KitInOut.objects.filter( kit=obj.kit, out=False, creation_timestamp__gt=obj.creation_timestamp, ).count() == 0): result.append(obj) return result How to optimize this? -
How to build a multi-module react-library where components can be imorted via import { MyComponent } from "shared-ui/my-component"
I built a react component library using Vite.js. Here's the vite-config: // vite.config.js export default defineConfig({ resolve: { alias: { "@": path.resolve(__dirname, "./src"), }, }, build: { lib: { entry: resolve(__dirname, "src/index.js"), name: "SharedUI", formats: ["es"], fileName: "shared-ui", }, rollupOptions: { plugins: [peerDepsExternal()], output: { globals: { react: "React", }, }, }, }, }); Here's my folder structure: shared-ui/ ├─ src/ | ├─ index.js │ ├─ components/ │ │ ├─ index.js │ │ ├─ select | | | ├─index.js | | | ├─select.component.jsx │ │ ├─ input | | | ├─index.js | | | ├─input.component.jsx ├─ vite.config.js ├─ dist The shared-ui/src/index.js-file contains the following: // shared-ui/src/index.js export * from "./input"; export * from "./select"; The vite build command created one file shared-ui.js, which lands in dist folder. If I install the package (in my case in an app using pnpm workspace) I can import the Select-component using: import { Select } from "shared-ui"; and it works. But I want to achieve imports like: import { Select } from "shared-ui/select"; How is that possible? I tried using rollup-plugin-includepaths like // vite.config.js import includePaths from "rollup-plugin-includepaths"; let includePathOptions = { include: {}, paths: ["src/components"], external: [], extensions: [".js", ".jsx"], }; //... vite … -
I am having problem with Nginx default 80 port when I upload media files
I upload a file to the server using the post method, but it appears on the default port 80. However, I run Nginx on port 8001. This is what I see when I check my endpoint with 8001 port. File look like port 80. http://xxx.xxx.x.xx/media/files/excel/macro/data.xlsx But I check with 8000 port http://xxx.xxx.x.xx:8000/media/files/excel/macro/data.xlsx My nginx/default.conf file : upstream django_asgi { server django_asgi:8000; } map $http_upgrade $connection_upgrade { default upgrade; '' close; } server { client_max_body_size 100M; location / { try_files $uri @proxy_to_app; } location @proxy_to_app { proxy_pass http://django_asgi; client_max_body_size 100M; proxy_http_version 1.1; proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection "upgrade"; proxy_read_timeout 3600; proxy_connect_timeout 3600; proxy_send_timeout 3600; keepalive_timeout 3600; proxy_redirect off; proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header X-Forwarded-Host $server_name; } location /static/ { alias /code/staticfiles/; } location /media/ { alias /code/media/; } } My Dockerfile : FROM python:3.8 ENV PYTHONUNBUFFERED 1 ENV REDIS_HOST "redis" RUN mkdir /code RUN mkdir code/staticfiles RUN mkdir code/mediafiles WORKDIR /code RUN pip install --upgrade pip RUN pip install psycopg2 COPY requirements.txt /code/ RUN pip install uwsgi RUN apt-get update && apt-get install -y tdsodbc unixodbc-dev RUN pip install -r requirements.txt ADD . /code/ RUN python manage.py collectstatic --no-input RUN python manage.py migrate --no-input My docker-compose.yml … -
can't send value to database postgresql with Django and javascript
i'm try use Ajax send correctAnswers to postgresql with Django but it error. I don't know where I missed it. function checkAnswers() { window.scrollTo(0, 0); var correctAnswers = 0; for (var i = 0; i < questions.length; i++) { var radios = document.getElementsByName("question" + (i + 1)); var questionCol = document.getElementsByClassName("col-12")[i]; var isCorrect = false; for (var j = 0; j < radios.length; j++) { if (radios[j].value == questions[i].correctAnswer && radios[j].checked) { correctAnswers++; isCorrect = true; break; } } document.getElementById("result").innerHTML = "คุณได้คะแนน " + correctAnswers + " / " + questions.length; var backButton = document.createElement("input"); backButton.setAttribute("type", "button"); backButton.setAttribute("value", "กลับไปหน้าหลัก"); backButton.setAttribute("class", "btn btn-primary center1"); backButton.setAttribute("onclick", "location.href='User-page.html'"); document.getElementById("quizForm").appendChild(backButton); $.ajax({ url: "/submit_quiz/", type: "POST", data: { correctAnswers: correctAnswers }, success: function (response) { console.log("ส่งค่าไป data base สำเร็จ"); }, }); } It has no ajax response. -
How to sort querysets from different models based on two fields?
I have querysets from different models which have only two fields in common: datetime and dt_created, and I would like to sort the objects first on datetime and then on dt_created, so that objects with the same datetime are sorted based on field dt_created. How can I do that ? Until now I was able to combine and sort the queryset with datetime like this: lst_qs = list(qs_trades) + list(qs_deposits) + list(qs_withdrawals) sorted_lst = sorted(lst_qs, key=lambda x: x.datetime) -
Django: How to query two models with relationship to each other while keeping the relationship to the parent model?
I have a parent model which is Profile and two other models which is Courses and Course_student. class Profile(models.Model): ... first_name = models.CharField(verbose_name=_('First Name'), max_length=255, null=True, blank=True, ) middle_name = models.CharField(verbose_name=_('Middle Name'), max_length=255, null=True, blank=True) last_name = models.CharField(verbose_name=_('Last Name'), max_length=255, null=True, blank=True) ... class Courses(models.Model): YESNO = ( ('Yes', 'Yes'), ('No', 'No'), ) profile = models.ManyToManyField('Profile', related_name='course_profile', verbose_name=_('Profile')) course_taken = models.CharField(verbose_name=_('Course'), max_length=255) name_of_school = models.CharField(verbose_name=_('Name of School'), max_length=255) school_location = models.CharField(verbose_name=_('School Location'), max_length=255) period_of_attendance_from = models.DateField(verbose_name=_('Period of Attendance (From)'), max_length=255) period_of_attendance_to = models.DateField(verbose_name=_('Period of Attendance (To)'), max_length=255) nr_students = models.IntegerField(verbose_name=_('Total Number of Students'), null=True, blank=True) created_on = models.DateTimeField(auto_now_add=True) modified_on = models.DateTimeField(auto_now=True) class Meta: verbose_name = _('Course') verbose_name_plural = _('Course') def __str__(self): return '%s' % (self.course_taken) class Course_student(models.Model): YESNO = ( ('Yes', 'Yes'), ('No', 'No'), ) course = models.ForeignKey('Courses', related_name='course_student_details', on_delete=models.DO_NOTHING, verbose_name=_('Course'), blank=True, null=True) profile = models.ForeignKey('Profile', related_name='course_student_profile', on_delete=models.DO_NOTHING, verbose_name=_('Profile'), blank=True, null=True) standing = models.IntegerField(verbose_name=_('Standing'), null=True, blank=True) grade = models.CharField(verbose_name=_('Grade'), max_length=255, null=True, blank=True) completed = models.CharField(verbose_name=_('Completed'), choices=YESNO, max_length=255) class Meta: verbose_name = _('Student Details') verbose_name_plural = _('Student Details') def __str__(self): return '%s' % (self.course) admin.py class CourseUploaderInline(admin.StackedInline): model = CourseUploader extra = 1 class CourseStudentInline(admin.StackedInline): model = Course_student extra = 1 @admin.register(Courses) class CoursesAdmin(admin.ModelAdmin): inlines = [Course_studentInline, CorseUploaderInline,] Course_student has Foreignkey … -
django-compressor serves old version of CSS file eventhough newer version is available
I am hosting my Django application on a DigitalOcean droplet (Ubuntu 22.10 with Gnuicorn and Nginx. When I run my app locally everything looks fine, but as soon as I deploy, it is trying to load the initial version of the compressed CSS file. The newer file lies correctly on the server. Key files: Settings.py BASE_DIR = Path(__file__).resolve().parent.parent STATIC_ROOT = os.path.join(BASE_DIR,"static") STATIC_URL = '/static/' MEDIA_ROOT = os.path.join(BASE_DIR, "media") MEDIA_URL = '/media/' DEBUG = False urls.py urlpatterns = [ ... ] + static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT) + static(settings.STATIC_URL, document_root=settings.STATIC_ROOT) _base.html <head> {% compress css %} <link rel="stylesheet" href="{% static 'src/output.css' %}"> {% endcompress %} ... </head> Other static files and media files work fine, but if you open the website, Django serves an old version of the compressed output.css file. see the live example here: https://gymtime.ch/ the template is trying to load https://gymtime.ch/static/CACHE/css/output.41dd2db47b39.css (404, does not exist anymore) but the correct file that is used locally is on the server too: https://gymtime.ch/static/CACHE/css/output.e8979ce60e01.css How can I ensure the template serves the current compressed CSS file? Thanks for your support! -
How to upgrade JQuery version that used in Django static folder?
Currently I am using JQuery 2.2.4 in django project.Now I want to upgrade its version to 3.5.0 or more.I have jQuery files in django static folder.I do not know how to upgrade its version which is already running. Can anyone suggest a solution to upgrade the version? -
Django form not populating with POST data
I'm relatively new to Django so hopefully this is quite a simple issue. I am finding the debugging difficult and perhaps that is part of my problem here. Problem: Django form seems to not be populating with post data. Summary: I have 2 models Entities and Breaks. Breaks has a FK relationship to the entity_id (not the PK) on the Entities model. I want to generate an empty form for all the fields of Breaks. Generating a basic form populates all the empty fields, but for the FK it generates a dropdown list of all PKs of the Entities table. This is not helpful so I have excluded this in the ModelForm below and tried to replace with a list of all the entity_ids of the Entities table. This form renders as expected. class BreakForm(ModelForm): class Meta: model = Breaks #fields = '__all__' exclude = ('entity',) def __init__(self, *args, **kwargs): super(BreakForm, self).__init__(*args, **kwargs) self.fields['entity_id'] = ModelChoiceField(queryset=Entities.objects.all().values_list('entity_id', flat=True)) The below FormView is the cbv called by the URL. As the below stands if I populate the form, and for the FK column entity_id choose one of the values, the form will not submit. By that field on the form template the … -
Nested Regroups with django with some attributes from none regroups
I have a django template that I have implemented regroups in it. I have a problem with how to display some of the attributes from my model into the template in a table. I have a couple of issues to address: How can I display the remaining 4 attributes from the ImplementationMatrix model i.e implementation_status, implementation_summary, challenges, and wayforward to be displayed at the respective columns in the table on the template (index.html) without distorting the layout for each instance of ImplementationMatrix. The last for loop in the templates displays only one item for subactivity while I have more than subactivity for the respective activity. Is there any better way of implementing all this? My Models: class Strategy(TrackingModel): """ Stores all the strategies related to HSSP. """ strategy_name = models.CharField( max_length=255, blank=True, null=True, default="") class Meta(TrackingModel.Meta): verbose_name_plural = "Strategies" def __str__(self): return self.strategy_name class Intervention(TrackingModel): intervention_name = models.CharField( max_length=255, blank=True, null=True, default="" ) strategy = models.ForeignKey(Strategy, on_delete=models.PROTECT) class Meta(TrackingModel.Meta): verbose_name_plural = "Interventions" def __str__(self): return self.intervention_name class Activity(TrackingModel): activity_name = models.CharField( max_length=255, blank=True, null=True, default="") intervention = models.ForeignKey(Intervention, on_delete=models.PROTECT) class Meta(TrackingModel.Meta): verbose_name_plural = "Activities" def __str__(self): return self.activity_name class SubActivity(TrackingModel): subactivity_name = models.CharField( max_length=255, blank=True, null=True, default="" ) activity = … -
How to implement redis on Django
I am trying to implement Redis (redis_data = redis.Redis(host='localhost', port=6379, db=0) in Django. Here I am sharing the code. Anyone, please help me to write this code using the Redis server? def redis(request): if request.method == "GET": c = request.GET.get('c', '') p = request.GET.get('p', 2) l = request.GET.get('l', 20) if c and int(c) > 0: data = h.list(c, int(p), int(l)) count = h.count(c) return sendResponse({'p': int(p), 'l': int(l), 'count': count, 'data': h.filter_fields(data)}) return sendResponse(formatErrorResponse(err, 'required')) -
Manage.py unknown command
I am a student and my profesor needs me to install Django on PyCharm. I made a big folder called PyCharmProjects and it includes like everything I have done in Python. The problem is that I made a new folder inside this PyCharmProjects called Elementar, and I need to have the Django folders in there but it's not downloading. I type in the PyCharm terminal django-admin manage.py startproject taskmanager1 (this is how my profesor needs me to name it) After I run the code it says: No Django settings specified. Unknown command: 'manage.py' Type 'django-admin help' for usage. I also tried to install it through the MacOS terminal but I don't even have acces the folder named Elementar (cd: no such file or directory: Elementar) although it is created and it is seen in the PyCharm. -
Replit Django No such file or directory: "common-passwords.txt.gz"
here I have an simple TO-DO app with Django which I created following this tutorial https://www.youtube.com/watch?v=llbtoQTt4qw , on my pc everything is working fine on the localhost, but when I upload and run it on Replit , then try to register a new username, I get this error shown on the image. >>>IMAGE<<< I am using Django register form, nothing additional. In Replit files menu I cant see that directory, so from the terminal I accessed to it with cd/filedirect and created the file there, then the registry form worked, but when I turned off and on the app, I guess it recreates the virtual environment which leads to the missing file again, I updated Django in the Replit terminal and it doesnt help, so what else could be the problem that this file is not genereted whenever the virtual env. is started ? Full info of error: https://drive.google.com/file/d/1CuoT3NZ18Nb0EhHa4sQrCK-CpOfhU9ar/view?usp=share_link I searched info about the problem, tried different solutions but non of them worked for me. -
Django, Redis and Image caching to improve scalability
So I'm working with EC2 and S3bucket and Redis cluster. The idea is that the image gets stored in the cache and gets retrieve from the cache before going to my S3bucket which is very demanding. I can cache and retrieve already, as I've tried just caching the S3 image url. All good till here, but that does not make the response any faster or at least not visibly faster. So the solution here is to store the image itself and this is how I'm doing it. def get_description(self, obj): image_key = f"category_img_ccc{obj.pk}" image_b64 = cache.get(image_key) if not image_b64: illustration_image = obj.description if illustration_image: image_url = illustration_image.url response = requests.get(image_url, stream=True) image = response.content image_b64 = base64.b64encode(image) cache.set(image_key, image_b64, None) if image_b64: return image_b64.decode("utf-8") else: return None And the frontend should then encode it and render this correct ? The response though looks very ugly as you can imagine the decoded image is a quite long char string. Is this the way to go? Can anyone shine some lights in this regard please. -
Changed the model to UNIQUE and form broke
I had a working form and page with following code: model.py class TrafficSources(models.Model): name = models.CharField('name', max_length=250) token = models.CharField('token', max_length=250) def __str__(self): return self.name def get_absolute_url(self): return reverse('ts_detail', kwargs={'slug': self.name.lower()}) Views.py @login_required(login_url='/') def settings(request): error = '' if request.method == 'POST': pk = request.POST.get('id') new_form = TrafficSourcesForm(request.POST) print('new_form here:/n', new_form) if new_form.is_valid(): if pk: TrafficSources.objects.filter(id=pk).update(**new_form.cleaned_data) error = f'{error} Saved.' else: new_form.save() error = '1 new object added.' return redirect(request.path, {'error': error}) else: error = 'Something went wrong!' new_form = TrafficSourcesForm() forms = [TrafficSourcesForm(instance=x) for x in TrafficSources.objects.all()] return render(request, 'mainpage/dashboard.html', {'new_form': new_form, 'forms': forms, 'error': error}) HTML.html {% for form in forms %} <form method="POST" class="table-row"> {% csrf_token %} <input type="hidden" name="id" value="{{ form.instance.pk }}"> <div class="table-cell">{{ form.name }}</div> <div class="table-cell">{{ form.token }}</div> <div class="table-cell"><button class="btn-success w-100 form-control">Save</button></div> </form> {{ form.non_field_errors }} {% endfor %} <div class="table-row"> <span colspan="3">Add new traffic source:</span> </div> <form method="POST" class="table-row"> {% csrf_token %} <span class="table-cell">{{ new_form.name }}</span> <span class="table-cell">{{ new_form.token }}</span> <span class="table-cell"><button class="btn btn-lg btn-success w-100">Add</button></span> </form> As I need the 'name' column in my table to create URL for django I made this change in my model class: class TrafficSources(models.Model): name = models.CharField('name', max_length=250, unique=True) token = models.CharField('token', max_length=250) I've med … -
MAC M1 pro - Encountered error while trying to install libsass package
× Encountered error while trying to install package.╰─> libsass ERROR: Couldn't install package: libsass -
Django, django-ckeditor-5. Delete media files after deleting the pages
everyone! I use django with django-ckeditor-5enter link description here. Users make his artickes, upload images in this editor. How delete images from article, when article is deleted. django-cleanup doesn't solve that problem, because in deletes only images stored in separate field, but in the case of django-ckeditor-5, images are stored in the field "article_text" -
django translation ngettext not working with gettext in the same file
this is my setup to generate translations for both singular and plurar text from django.utils.translations import ngettext as _ from django.utils.translations import gettext num = 3 my_plural_string = _("{num} apple", "{num} apples", num).format(num=num) my_single_string = gettext("this is a text") When using ngettext and gettext in the same file the generated .po file doesn't include the msgid_plural attribute for the first string #: .\test_app\test_translation.py:10 msgid "{num} apple" msgstr "" #: .\test_app\test_translation.py:11 msgid "this is a text" msgstr "" -
Why does the Python Secrets module keep generating the same passwords in this function in Django
Here is the function: def generate_password(): alphabet = string.ascii_letters + string.digits + "!@#$%^&*()+=/.," return ''.join(secrets.choice(alphabet) for i in range(12)) I added this to a Django model, so that it is automatically called when creating a user, and automatically generates its password. This is the code in the model: password = models.CharField(max_length=100, default=generate_password()) For some reason, creating 4 users is always going to create at least one duplicate password, if not two. this is an example of the passwords generated by creating 7 users: PpN(ky^tabgP iIS@4gfe@7sc 6#oNlIH0MbQg 6#oNlIH0MbQg iIS@4gfe@7sc PpN(ky^tabgP PpN(ky^tabgP This approach was suggested by different people and documentation, yet it seems like this function is always cycling between only a few passwords, and keeps repeating them. Can anyone help me understand why and how to avoid it? Django needs to be restarted some times so adding passwords to a set is not convenient. -
database application to use in Django
I'm confused to select which db should i use in Django and what db is mostly used for Django to develop small or medium or large applications? What is the best database application to use in Django projects and Why ? help me regarding this.