python – Errors in project build after git clean -xdf

Question:

There were errors installing the scipy library today, and pip suggested that I run git clean -xdf .

I made a backup of the entire project and executed the command. The installation still failed, and I restored the deleted folders from the backup, but now, when loading the project, errors appear in the modules that I have nothing to do with.

For example, there is a missing menu.html in the project folder \templates\gis\index.html line 77, while the entire \templates\gis folder is tracked in the gita:

Exception Type: TemplateDoesNotExist
Exception Value: menu.html

index.html cтроки 75-77:

{% csrf_token %}
<div id="map"></div>
{% include "menu.html" %}

There is a menu.html file in the \templates\gis menu.html . I am not working on the project alone, but my colleagues are not yet responding. There are thoughts that the problem is in the csrf-token request, because the python logs display

UserWarning: A {% csrf_token%} was used in a template, but the context did not provide the value. This is usually caused by not using RequestContext. "A {% csrf_token%} was used in a template, but the context"

Help me figure out what led to the error and how to solve it.

Answer:

With git clean -xdf, the settings for gulp, bower, package.json were dropped. The solution was to completely rebuild the project, starting with reinstalling the virtual environment and ending with the frontend. The project is working.

Scroll to Top
AllEscort