This problem occurs when I create an order in my project. I hosted it on GoDaddy, and the problem occurred only after hosting. If I run this locally, it will create the order. Understand this error Error saving data: dl …
Есть ли у вас на сайте функция под заказ прописать скрипт для сетапа? Сама не умею . Пытаюсь найти специалиста, который в этом разбирается. На самом деле сетап не сложный. Насколько трудоёмкий, тоже не знаю. Надеюсь на понимание.
I have 2 model tables. In the first table I have a form in the set in which there is one interesting field. This field can have the same values. If we consider the second table model - then in …
This morning, my production website went down with a "Bad Request" error. It was working the day before, and I made no changes that might have caused the error. Below is the traceback I got in the asgi.log file. I …
I have a form with OneToOneField where data is loaded from another table model. But I often have large data sizes there and the displayed text does not fit into the window size. Is it possible to somehow configure the …
I'm building an application using Django for backend and React for frontend and there's need to deploy do different environments, UAT and PROD. How do I set up the Nginx and Django environments? Please share your views or resources that …
I'm getting a page not found error for a url I know is defined in urls.py - exact same code works on the qa server, but for some reason on the live server it gives a 404 error. <a href="https://i.sstatic.net/xVAnJmli.png" …
I am facing an issue while creating my superuser using the following command: ./manage.py createsuperuser, it seems that there is no error but the line where í can set my email and password doesnt appear enter image …
I have a django app and i am using django-allauth to authenticate users.I dont have anything complex setup right now, all i am trying to do is let the user signup through email and password and verify their email before …
I'm encountering a ValueError in my Django application when trying to save a User object with a related UserRoleAssociation in the admin interface. The error occurs in a multi-database setup where both the UserRoleAssociation and Role models are intended to …
I'm running a Django site on my computer and I want to access it from another device on the same Wi-Fi network (for example, from a phone or another laptop). I tried running python manage.py runserver, but I can only …
I have a Django project configured with PyCharm. I am using a conda env for packages installations. I have installed gdal. But when I run server, I see: django.core.exceptions.ImproperlyConfigured: Could not find the GDAL library (tried "gdal310", "gdal309", "gdal308", "gdal307", …
При вводе команды 'python manage.py collectstatic' в командную строку в Visual Studio 2022 выводится ошибка: 'You're using the staticfiles app without having set the STATIC_ROOT setting to a filesystem path.' Вроде как путь указан криво. А он указан вроде нормально, …
I have a selenium web scrapper, that runs well in my local development environment even in headless mode. However when i deploy it in production in a Linode Ubuntu VPS, somehow it fails with a Timeout exceeded message.Any help would …
Simple question here about django_stubs_ext. Shouldn't the monkey patching occur only during TYPE_CHECKING ? Something like this: # settings.py if TYPE_CHECKING: import django_stubs_ext django_stubs_ext.monkeypatch()
Something went wrong :-( Something went wrong while trying to load this site; please try again later. Debugging tips If this is your site, and you just reloaded it, then the problem might simply be that it hasn't loaded up …
I'm building a Visitor Management System (VMS), and I've been given a complete frontend to work with. My task is to build the API-based backend using Django and Django REST Framework, which I'm familiar with from smaller projects. However, I'm …
I'm running into an issue and would appreciate some pointers. I have a production Django app where I included Google Analytics using a context processor and conditionally render it in my base.html template like this: <!-- Google Analytics --> …
Can anyone tell me how I can deploy my Django React-based webapp in my shared hosting
I'm working on a Django project using GeoDjango for spatial models. I'm on Windows 10, using a Conda environment (moodspend). When I try to run the server with: python manage.py runserver I get this error: (moodspend) PS C:\Users\ngari\Desktop\Ngari's Projects\moodspend\backend> …
Доброго времени суток! Я в Джанго новичок. Возможно ли такое организовать? Необходимо вывести три поля на форму, сделать по ним отбор, затем выбрать какое-то значение и записать его в тот набор, который получился в результате отбора? По одному полю нужно …
Good day! I have a model table. And a form. I filter the query from the queryset model by certain criteria and send it to the code in views. From the filtered queryset I would like to take only one …
If I have, for example: from django.contrib.postgres.fields import JSONField class MyModel(models.Model): data = JSONField() GIVEN a model instance obj1, where data == ['apple', 'banana', 'orange'] GIVEN a model instance obj2, where data == ['banana', 'orange'] GIVEN a model instance …
I have a page where user creates an instance. An instance has a bunch of characteristics and foreign key to product (which has category and name itself) and all the fields are static - just stylized selects and inputs, but …
Good day! I have a table model. I plan to take one row from it - one set of elements. To place it in an object - a dictionary. How can I place the last or first or a specific …
I'm running a Django server which has API's I consume through a React Native and React applications. I want it to work for Google, Facebook, Instagram and Twitter. For this question I want to focus on the React Application and …
I created sitemap using django default sitemap from django.contrib.sitemaps.views import sitemap Here is the complete process #urls.py sitemaps = { 'static': StaticViewSitemap, 'blogpost_detail': BlogSitemap, 'portfolio-details': PortfolioSitemap, # Add others like 'posts': PostSitemap if needed } path( "sitemap.xml", sitemap, …
My project's admin site was working earlier with everything kept at default. But I'm building the site and after lots of coding I get an error where it is asking for a template that has the name of the project. …
If I'm not wrong, currently there are two ways to have connection pooling in Django: Native Connection Pooling (Django 5.x) Using PGBouncer I want to know that how connection pooling works behind the scene in Django. In FastAPI, …
I have two table models. I write data to one of them using a form. I also want to write data to the other model table using a form. But I'm trying to link these tables. Use the first one …
Anyone using Django + Gunicorn + Gevent + Opentelemetry in production? Would love to know how you got it to work. Seems like I can't seem to use BatchSpanProcessor or BatchLogRecordProcessor. I'm getting errors which seem to have many open …
I am implementing permission-roles in Django using DRF but not sure where i got stuck here Here are models: class User(): class Staff() user = models.ForeignKey( User, on_delete=models.CASCADE, related_name="staffs") business = models.ForeignKey( "Business", on_delete=models.CASCADE, related_name="staffs" ) role = models.PositiveSmallIntegerField (superadmin, …
I've been trying to make the final test pass. I seem to be getting a 403 error, nothing that I'm not authorized to make a post. Even though I gave the test user authorization to post tests. I don't understand …
I'm trying to prevent users from creating more than one Mining object within a 24-hour period in my Django project. I chose to use Django signals, specifically the pre_save signal, to enforce this rule globally—regardless of whether the object is …
I've been trying a basic string to Django backend from frontend using axios.post call. Connection is ensured and backend side detects the request but the data is empty. Frontend side: const axios = Axios.create({ baseURL: API_URL, headers: { 'Content-Type': 'application/json', …
I am using allauth in my Django project and I have set up a custom account adapter which I have specified in settings.py - ACCOUNT_ADAPTER. My issue is once the user logs in in at a URL like /accounts/login/?next=/checkout/, my …
Не работают ссылки, хотя вроде всё прописано верно. В файле urls.py: from django.urls import path from . import views urlpatterns = [ path ('', views.reg, name = 'Reg_page'), path ('about/', views.about, name = 'About') ] В файле views.py: def …
Here is my forms.py code: from .models import User class userRegistrationForm(forms.ModelForm): password = forms.CharField(widget = forms.PasswordInput()) confirm_password = forms.CharField(widget = forms.PasswordInput()) class Meta: model = User fields = ['first_name', 'last_name', 'username', 'email','password'] ``` Here is my views.py code: …
Никак не могу понять - с какой стороны подойти к такой задаче: В базу надо записывать данные с определенной периодичностью. Как в Джанго реализованы фоновые задачи, выполняемые по расписанию? В идеале было бы хорошо создать внутри скрипт и заполнять данными …
To give some context, i made a async function which works fine when testing manually but when I use Django's testcases, the query is not returning anything back inside the async block, if I try the same query outside, it …