Invalid filter: 'file_exists'
Request Method: | GET |
---|---|
Request URL: | https://vs1.sid.ir/corona/ |
Django Version: | 3.2.3 |
Exception Type: | TemplateSyntaxError |
Exception Value: | Invalid filter: 'file_exists' |
Exception Location: | c:\python39\lib\site-packages\django\template\base.py, line 569, in find_filter |
Python Executable: | c:\python39\python.exe |
Python Version: | 3.9.5 |
Python Path: | ['.', 'C:\\inetpub\\wwwroot\\da', 'c:\\python39\\python39.zip', 'c:\\python39\\DLLs', 'c:\\python39\\lib', 'c:\\python39', 'c:\\python39\\lib\\site-packages', 'c:\\python39\\lib\\site-packages\\win32', 'c:\\python39\\lib\\site-packages\\win32\\lib', 'c:\\python39\\lib\\site-packages\\Pythonwin'] |
Server time: | Thu, 28 Mar 2024 19:07:35 +0000 |
In template C:\inetpub\wwwroot\da\polls\templates\index.html
, error at line 534
524 | <div class="page-section text-center"> |
---|---|
525 | <h2 class="page-section__title page-section__title--white">Top Reaserchers</h2> |
526 | |
527 | <p class="page-section__paragraph page-section__paragraph--white">Who Publish the most number of papers?</p> |
528 | |
529 | <div class="row"> |
530 | <div class="col-xs-12 col-lg-10 col-lg-offset-1"> |
531 | <div class="carousel slide" data-interval="false" data-ride="carousel" id="teamCarousel"><!-- Wrapper for slides --> |
532 | <div class="carousel-inner">{% for au in authors %} {% if forloop.counter == 1 %} |
533 | <div class="item active"><img alt="" class="img-responsive" src="{% static 'corona.sid.ir/assets/images/team-slider-bg.png' %}" /> |
534 | <div class="carousel-caption">{% load app_filters %} {% if au.1|file_exists == 1 %} <img alt="" class="img-responsive" src="{% static 'corona.sid.ir/assets/images/unk.png' %}" /> {% else %} <img alt="" class="img-responsive" src="{% static 'corona.sid.ir/assets/images/{{ au.1|lower }}.png' %}" /> {% endif %} |
535 | <h3 class="carousel-caption__name">{{ au.0 }} {{ au.1 }}</h3> |
536 | |
537 | <p class="carousel-caption__title">{{ au.2 }}</p> |
538 | |
539 | <p class="carousel-caption__paragraph">Number of Papers: {{ au.4 }}</p> |
540 | </div> |
541 | </div> |
542 | {% else %} |
543 | |
544 | <div class="item"><img alt="" class="img-responsive" src="{% static 'corona.sid.ir/assets/images/team-slider-bg.png' %}" /> |
c:\python39\lib\site-packages\django\template\smartif.py
, line 175, in translate_token
self.tokens = mapped_tokens
self.pos = 0
self.current_token = self.next_token()
def translate_token(self, token):
try:
op = OPERATORS[token]…
except (KeyError, TypeError):
return self.create_var(token)
else:
return op()
def next_token(self):
Variable | Value |
---|---|
self | <django.template.defaulttags.TemplateIfParser object at 0x00000203C3480340> |
token | 'au.1|file_exists' |
c:\python39\lib\site-packages\django\core\handlers\exception.py
, line 47, in inner
response = await sync_to_async(response_for_exception, thread_sensitive=False)(request, exc)
return response
return inner
else:
@wraps(get_response)
def inner(request):
try:
response = get_response(request)…
except Exception as exc:
response = response_for_exception(request, exc)
return response
return inner
Variable | Value |
---|---|
exc | TemplateSyntaxError("Invalid filter: 'file_exists'") |
get_response | <bound method BaseHandler._get_response of <django.core.handlers.wsgi.WSGIHandler object at 0x000002039C4F4130>> |
request | <WSGIRequest: GET '/corona/'> |
c:\python39\lib\site-packages\django\core\handlers\base.py
, line 181, in _get_response
if response is None:
wrapped_callback = self.make_view_atomic(callback)
# If it is an asynchronous view, run it in a subthread.
if asyncio.iscoroutinefunction(wrapped_callback):
wrapped_callback = async_to_sync(wrapped_callback)
try:
response = wrapped_callback(request, *callback_args, **callback_kwargs)…
except Exception as e:
response = self.process_exception_by_middleware(e, request)
if response is None:
raise
# Complain if the view returned None (a common error).
Variable | Value |
---|---|
callback | <function main at 0x00000203A542DB80> |
callback_args | () |
callback_kwargs | {} |
middleware_method | <bound method CsrfViewMiddleware.process_view of <django.middleware.csrf.CsrfViewMiddleware object at 0x000002039D069F70>> |
request | <WSGIRequest: GET '/corona/'> |
response | None |
self | <django.core.handlers.wsgi.WSGIHandler object at 0x000002039C4F4130> |
wrapped_callback | <function main at 0x00000203A542DB80> |
C:\inetpub\wwwroot\da\.\corona\views.py
, line 178, in main
conn = sqlite3.connect('C:/inetpub/wwwroot/da/polls/static/corona.sid.ir/data.db')
c = conn.cursor()
c.execute("select COUNT(*) from main")
num = c.fetchall()[0][0]
context['num'] = num
context['authors'] = authors
return render(request, 'index.html', context)…
Variable | Value |
---|---|
authors | [['Elisabeth', 'Mahase', 'the bmj.', nan, 218], ['Gareth', 'Iacobucci', 'the bmj.', nan, 153], ['Abi', 'Rimmer', 'the bmj.', nan, 82], ['Jacqui', 'Wise', 'london.', nan, 50], ['Giuseppe', 'Lippi', 'section of clinical biochemistry, university of verona, verona, italy.', 'Italy', 43], ['Giuseppe', 'Lippi', 'section of clinical biochemistry, department of neuroscience, biomedicine ' 'and movement, university of verona', 'Italy', 40], ['Owen', 'Dyer', 'montreal.', nan, 36], ['Clare', 'Dyer', 'the bmj.', nan, 35], ['Ali A', 'Rabaan', 'molecular diagnostic laboratory, johns hopkins aramco healthcare, ' 'dhahran, saudi arabia.', 'Saudi Arabia', 29], ['Shaun', 'Griffin', 'london.', nan, 28]] |
c | <sqlite3.Cursor object at 0x00000203B2D04EA0> |
conn | <sqlite3.Connection object at 0x00000203C49C5B70> |
context | {'authors': [['Elisabeth', 'Mahase', 'the bmj.', nan, 218], ['Gareth', 'Iacobucci', 'the bmj.', nan, 153], ['Abi', 'Rimmer', 'the bmj.', nan, 82], ['Jacqui', 'Wise', 'london.', nan, 50], ['Giuseppe', 'Lippi', 'section of clinical biochemistry, university of verona, ' 'verona, italy.', 'Italy', 43], ['Giuseppe', 'Lippi', 'section of clinical biochemistry, department of neuroscience, ' 'biomedicine and movement, university of verona', 'Italy', 40], ['Owen', 'Dyer', 'montreal.', nan, 36], ['Clare', 'Dyer', 'the bmj.', nan, 35], ['Ali A', 'Rabaan', 'molecular diagnostic laboratory, johns hopkins aramco ' 'healthcare, dhahran, saudi arabia.', 'Saudi Arabia', 29], ['Shaun', 'Griffin', 'london.', nan, 28]], 'num': 158633, 'titles_pids': [['The Impact of COVID-19 on the Optimal Management of ' 'Osteoporosis.', '34130363'], ['Is Lupus Anticoagulant a Significant Feature of COVID-19? A ' 'Critical Appraisal of the Literature.', '34130341'], ['COVID-19 and Antiphospholipid Antibodies: Time for a ' 'Reality Check?', '34130340'], ['[Impact of the COVID-19 pandemic on consultations and ' 'diagnosis in ENT practices in Germany].', '34130328'], ['ECMO induces early alterations in coagulation and ' 'fibrinolysis profiles in COVID-19 patients with acute ' 'respiratory distress syndrome.', '34130315'], ['Incidence and Outcomes of Acute Kidney Injury in COVID-19: ' 'A Systematic Review.', '34130296'], ['Impact of Confinement in Patients under Long-Term ' 'Noninvasive Ventilation during the First Wave of the ' 'SARS-CoV-2 Pandemic: A Remarkable Resilience.', '34130277'], ['Early lung ultrasound assessment for the prognosis of ' 'patients hospitalized for COVID-19 pneumonia. A pilot ' 'study.', '34130209\n' '32227492\n' '33015645\n' '27324241\n' '32331781\n' '31573350\n' '18442425\n' '30581826\n' '26138420\n' '32443899\n' '32166346\n' '30048331\n' '25991460\n' '32101510\n' '20851923\n' '32294504\n' '32305490\n' '22584759\n' '32361220\n' '30606165\n' '32327383\n' '32191587\n' '32007143\n' '32073353\n' '17316468\n' '14695718'], ['COVID-19 in Argentine teriflunomide-treated multiple ' 'sclerosis patients: First national case series.', '34130197'], ['COVID-19 versus SARS: A comparative review.', '34130121\n' '15231072\n' '15650185\n' '32213332\n' '14725258\n' '32678530\n' '32315626\n' '15520422\n' '32007145\n' '21994708\n' '32238084\n' '32223769\n' '15314040\n' '32239184\n' '16461478\n' '32120913\n' '31995857\n' '32085846\n' … <trimmed 11813 bytes string> |
data | title ... tiab 0 The Impact of COVID-19 on the Optimal Manageme... ... The Impact of COVID-19 on the Optimal Manageme... 1 Is Lupus Anticoagulant a Significant Feature o... ... Is Lupus Anticoagulant a Significant Feature o... 2 COVID-19 and Antiphospholipid Antibodies: Time... ... COVID-19 and Antiphospholipid Antibodies: Time... 3 [Impact of the COVID-19 pandemic on consultati... ... [Impact of the COVID-19 pandemic on consultati... 4 ECMO induces early alterations in coagulation ... ... ECMO induces early alterations in coagulation ... ... ... ... ... 158628 Newcastle disease and infectious bronchitis ne... ... NaN 158629 Infectious bronchitis and Newcastle disease. ... NaN 158630 Studies on the diagnosis of Newcastle disease ... ... NaN 158631 Pathology of the chicken embryo infected with ... ... NaN 158632 Demonstration of an interference phenomenon as... ... NaN [158633 rows x 9 columns] |
num | 158633 |
request | <WSGIRequest: GET '/corona/'> |
temp | ['title', 'abstract', 'pubmed_id', 'day', 'month', 'year', 'journal', 'type', 'tiab'] |
titles | [['The Impact of COVID-19 on the Optimal Management of Osteoporosis.', '34130363'], ['Is Lupus Anticoagulant a Significant Feature of COVID-19? A Critical ' 'Appraisal of the Literature.', '34130341'], ['COVID-19 and Antiphospholipid Antibodies: Time for a Reality Check?', '34130340'], ['[Impact of the COVID-19 pandemic on consultations and diagnosis in ENT ' 'practices in Germany].', '34130328'], ['ECMO induces early alterations in coagulation and fibrinolysis profiles in ' 'COVID-19 patients with acute respiratory distress syndrome.', '34130315'], ['Incidence and Outcomes of Acute Kidney Injury in COVID-19: A Systematic ' 'Review.', '34130296'], ['Impact of Confinement in Patients under Long-Term Noninvasive Ventilation ' 'during the First Wave of the SARS-CoV-2 Pandemic: A Remarkable Resilience.', '34130277'], ['Early lung ultrasound assessment for the prognosis of patients hospitalized ' 'for COVID-19 pneumonia. A pilot study.', '34130209\n' '32227492\n' '33015645\n' '27324241\n' '32331781\n' '31573350\n' '18442425\n' '30581826\n' '26138420\n' '32443899\n' '32166346\n' '30048331\n' '25991460\n' '32101510\n' '20851923\n' '32294504\n' '32305490\n' '22584759\n' '32361220\n' '30606165\n' '32327383\n' '32191587\n' '32007143\n' '32073353\n' '17316468\n' '14695718'], ['COVID-19 in Argentine teriflunomide-treated multiple sclerosis patients: ' 'First national case series.', '34130197'], ['COVID-19 versus SARS: A comparative review.', '34130121\n' '15231072\n' '15650185\n' '32213332\n' '14725258\n' '32678530\n' '32315626\n' '15520422\n' '32007145\n' '21994708\n' '32238084\n' '32223769\n' '15314040\n' '32239184\n' '16461478\n' '32120913\n' '31995857\n' '32085846\n' '32223774\n' '32184205\n' '32727719\n' '32149036\n' '15503102\n' '12958366\n' '26468744\n' '32031570\n' '32335169\n' '32216717\n' '32273156\n' '32361747\n' '17934078\n' '15018131\n' '15161967\n' '32890939\n' '32530389\n' '15200815\n' '16968120\n' '32171076\n' '12781535\n' '32142938\n' '32413914\n' '32594572\n' '33169119\n' '32482249\n' '32086938\n' '32352517\n' '32145768\n' '32787909\n' '20675682\n' '14991510\n' '15388253\n' '15319862\n' '32386565\n' '33175877\n' '33560401\n' '32179124\n' '32342927\n' '32125452\n' '23185609\n' '15531251\n' '32247631\n' '32327904\n' '17374415\n' '15534177\n' '32574139\n' '32105609\n' '15742856\n' '32171074\n' '32035997\n' '32348472\n' '15141377\n' '29511076\n' '32740766\n' '15364765\n' '16503362\n' '14963300\n' '32305046\n' '21403780\n' '32335340\n' '32446721\n' '32183920\n' '32407364\n' '32203189\n' '32293807\n' '4158999\n' '32113704\n' '32346146\n' '32238024\n' '33546463\n' '32817204\n' '32074444\n' '33500407\n' '23668493\n' '32198291\n' '15030698\n' '32022370\n' '32108351\n' '32195705\n' '32052846\n' '30531947\n' '31986264\n' '32143990\n' '15018128\n' '12885985\n' '32222988\n' '17392154\n' '32043983\n' '32291094\n' '32469387\n' '26552008\n' '32393823\n' '32293716\n' '32219363\n' '32546589\n' '32167524\n' '14642187\n' '16244207\n' '32192578\n' '32174129\n' '32445440\n' '32007143\n' '32234468\n' '32278800\n' '32430840\n' '16237152\n' '15530413\n' '32245396\n' '32382657\n' '15673319\n' '16640347\n' '15109430\n' '19393959'], ['The immunological response among COVID-19 patients with acute respiratory ' 'distress syndrome.', '34130119\n' '32425003\n' '32645311\n' '32519944\n' '12088676\n' '33676589\n' '32365221\n' '30323811\n' '32167524\n' '32849654\n' '22876772\n' '32202240\n' '8637514\n' '32217835\n' '32609307\n' '29980618\n' '32358580\n' '32961074\n' '33657286\n' '32612617\n' '32297671\n' '32754163\n' '26252407\n' '20936936\n' '32344321\n' '12890366\n' '33085857\n' '33676590\n' '32448345\n' '31986264\n' '32572965\n' '18… <trimmed 5965 bytes string> |
trad_data | title ... tiab 182 Potential Natural Candidates in the Treatment ... ... Potential Natural Candidates in the Treatment ... 185 A Pilot Clinical study of an add on Ayurvedic ... ... A Pilot Clinical study of an add on Ayurvedic ... 319 Interferon therapy in patients with SARS, MERS... ... Interferon therapy in patients with SARS, MERS... 630 Traditional Herbal Medicines, Bioactive Metabo... ... Traditional Herbal Medicines, Bioactive Metabo... 2725 Potent phytochemicals against COVID-19 infecti... ... Potent phytochemicals against COVID-19 infecti... ... ... ... ... 133861 Natural product-derived phytochemicals as pote... ... Natural product-derived phytochemicals as pote... 137456 Moroccan Medicinal plants as inhibitors agains... ... Moroccan Medicinal plants as inhibitors agains... 138743 Herbal medicine and pattern identification for... ... Herbal medicine and pattern identification for... 143601 Drug treatment options for the 2019-new corona... ... Drug treatment options for the 2019-new corona... 143989 A retrospective analysis of the effect of the ... ... A retrospective analysis of the effect of the ... [85 rows x 9 columns] |
c:\python39\lib\site-packages\django\shortcuts.py
, line 19, in render
def render(request, template_name, context=None, content_type=None, status=None, using=None):
"""
Return a HttpResponse whose content is filled with the result of calling
django.template.loader.render_to_string() with the passed arguments.
"""
content = loader.render_to_string(template_name, context, request, using=using)…
return HttpResponse(content, content_type, status)
def redirect(to, *args, permanent=False, **kwargs):
"""
Return an HttpResponseRedirect to the appropriate URL for the arguments
Variable | Value |
---|---|
content_type | None |
context | {'authors': [['Elisabeth', 'Mahase', 'the bmj.', nan, 218], ['Gareth', 'Iacobucci', 'the bmj.', nan, 153], ['Abi', 'Rimmer', 'the bmj.', nan, 82], ['Jacqui', 'Wise', 'london.', nan, 50], ['Giuseppe', 'Lippi', 'section of clinical biochemistry, university of verona, ' 'verona, italy.', 'Italy', 43], ['Giuseppe', 'Lippi', 'section of clinical biochemistry, department of neuroscience, ' 'biomedicine and movement, university of verona', 'Italy', 40], ['Owen', 'Dyer', 'montreal.', nan, 36], ['Clare', 'Dyer', 'the bmj.', nan, 35], ['Ali A', 'Rabaan', 'molecular diagnostic laboratory, johns hopkins aramco ' 'healthcare, dhahran, saudi arabia.', 'Saudi Arabia', 29], ['Shaun', 'Griffin', 'london.', nan, 28]], 'num': 158633, 'titles_pids': [['The Impact of COVID-19 on the Optimal Management of ' 'Osteoporosis.', '34130363'], ['Is Lupus Anticoagulant a Significant Feature of COVID-19? A ' 'Critical Appraisal of the Literature.', '34130341'], ['COVID-19 and Antiphospholipid Antibodies: Time for a ' 'Reality Check?', '34130340'], ['[Impact of the COVID-19 pandemic on consultations and ' 'diagnosis in ENT practices in Germany].', '34130328'], ['ECMO induces early alterations in coagulation and ' 'fibrinolysis profiles in COVID-19 patients with acute ' 'respiratory distress syndrome.', '34130315'], ['Incidence and Outcomes of Acute Kidney Injury in COVID-19: ' 'A Systematic Review.', '34130296'], ['Impact of Confinement in Patients under Long-Term ' 'Noninvasive Ventilation during the First Wave of the ' 'SARS-CoV-2 Pandemic: A Remarkable Resilience.', '34130277'], ['Early lung ultrasound assessment for the prognosis of ' 'patients hospitalized for COVID-19 pneumonia. A pilot ' 'study.', '34130209\n' '32227492\n' '33015645\n' '27324241\n' '32331781\n' '31573350\n' '18442425\n' '30581826\n' '26138420\n' '32443899\n' '32166346\n' '30048331\n' '25991460\n' '32101510\n' '20851923\n' '32294504\n' '32305490\n' '22584759\n' '32361220\n' '30606165\n' '32327383\n' '32191587\n' '32007143\n' '32073353\n' '17316468\n' '14695718'], ['COVID-19 in Argentine teriflunomide-treated multiple ' 'sclerosis patients: First national case series.', '34130197'], ['COVID-19 versus SARS: A comparative review.', '34130121\n' '15231072\n' '15650185\n' '32213332\n' '14725258\n' '32678530\n' '32315626\n' '15520422\n' '32007145\n' '21994708\n' '32238084\n' '32223769\n' '15314040\n' '32239184\n' '16461478\n' '32120913\n' '31995857\n' '32085846\n' … <trimmed 11813 bytes string> |
request | <WSGIRequest: GET '/corona/'> |
status | None |
template_name | 'index.html' |
using | None |
c:\python39\lib\site-packages\django\template\loader.py
, line 61, in render_to_string
Load a template and render it with a context. Return a string.
template_name may be a string or a list of strings.
"""
if isinstance(template_name, (list, tuple)):
template = select_template(template_name, using=using)
else:
template = get_template(template_name, using=using)…
return template.render(context, request)
def _engine_list(using=None):
return engines.all() if using is None else [engines[using]]
Variable | Value |
---|---|
context | {'authors': [['Elisabeth', 'Mahase', 'the bmj.', nan, 218], ['Gareth', 'Iacobucci', 'the bmj.', nan, 153], ['Abi', 'Rimmer', 'the bmj.', nan, 82], ['Jacqui', 'Wise', 'london.', nan, 50], ['Giuseppe', 'Lippi', 'section of clinical biochemistry, university of verona, ' 'verona, italy.', 'Italy', 43], ['Giuseppe', 'Lippi', 'section of clinical biochemistry, department of neuroscience, ' 'biomedicine and movement, university of verona', 'Italy', 40], ['Owen', 'Dyer', 'montreal.', nan, 36], ['Clare', 'Dyer', 'the bmj.', nan, 35], ['Ali A', 'Rabaan', 'molecular diagnostic laboratory, johns hopkins aramco ' 'healthcare, dhahran, saudi arabia.', 'Saudi Arabia', 29], ['Shaun', 'Griffin', 'london.', nan, 28]], 'num': 158633, 'titles_pids': [['The Impact of COVID-19 on the Optimal Management of ' 'Osteoporosis.', '34130363'], ['Is Lupus Anticoagulant a Significant Feature of COVID-19? A ' 'Critical Appraisal of the Literature.', '34130341'], ['COVID-19 and Antiphospholipid Antibodies: Time for a ' 'Reality Check?', '34130340'], ['[Impact of the COVID-19 pandemic on consultations and ' 'diagnosis in ENT practices in Germany].', '34130328'], ['ECMO induces early alterations in coagulation and ' 'fibrinolysis profiles in COVID-19 patients with acute ' 'respiratory distress syndrome.', '34130315'], ['Incidence and Outcomes of Acute Kidney Injury in COVID-19: ' 'A Systematic Review.', '34130296'], ['Impact of Confinement in Patients under Long-Term ' 'Noninvasive Ventilation during the First Wave of the ' 'SARS-CoV-2 Pandemic: A Remarkable Resilience.', '34130277'], ['Early lung ultrasound assessment for the prognosis of ' 'patients hospitalized for COVID-19 pneumonia. A pilot ' 'study.', '34130209\n' '32227492\n' '33015645\n' '27324241\n' '32331781\n' '31573350\n' '18442425\n' '30581826\n' '26138420\n' '32443899\n' '32166346\n' '30048331\n' '25991460\n' '32101510\n' '20851923\n' '32294504\n' '32305490\n' '22584759\n' '32361220\n' '30606165\n' '32327383\n' '32191587\n' '32007143\n' '32073353\n' '17316468\n' '14695718'], ['COVID-19 in Argentine teriflunomide-treated multiple ' 'sclerosis patients: First national case series.', '34130197'], ['COVID-19 versus SARS: A comparative review.', '34130121\n' '15231072\n' '15650185\n' '32213332\n' '14725258\n' '32678530\n' '32315626\n' '15520422\n' '32007145\n' '21994708\n' '32238084\n' '32223769\n' '15314040\n' '32239184\n' '16461478\n' '32120913\n' '31995857\n' '32085846\n' … <trimmed 11813 bytes string> |
request | <WSGIRequest: GET '/corona/'> |
template_name | 'index.html' |
using | None |
c:\python39\lib\site-packages\django\template\loader.py
, line 15, in get_template
Raise TemplateDoesNotExist if no such template exists.
"""
chain = []
engines = _engine_list(using)
for engine in engines:
try:
return engine.get_template(template_name)…
except TemplateDoesNotExist as e:
chain.append(e)
raise TemplateDoesNotExist(template_name, chain=chain)
Variable | Value |
---|---|
chain | [] |
engine | <django.template.backends.django.DjangoTemplates object at 0x00000203B0881790> |
engines | [<django.template.backends.django.DjangoTemplates object at 0x00000203B0881790>] |
template_name | 'index.html' |
using | None |
c:\python39\lib\site-packages\django\template\backends\django.py
, line 34, in get_template
self.engine = Engine(self.dirs, self.app_dirs, **options)
def from_string(self, template_code):
return Template(self.engine.from_string(template_code), self)
def get_template(self, template_name):
try:
return Template(self.engine.get_template(template_name), self)…
except TemplateDoesNotExist as exc:
reraise(exc, self)
def get_templatetag_libraries(self, custom_libraries):
"""
Return a collation of template tag libraries from installed
Variable | Value |
---|---|
self | <django.template.backends.django.DjangoTemplates object at 0x00000203B0881790> |
template_name | 'index.html' |
c:\python39\lib\site-packages\django\template\engine.py
, line 143, in get_template
return Template(template_code, engine=self)
def get_template(self, template_name):
"""
Return a compiled Template object for the given template name,
handling template inheritance recursively.
"""
template, origin = self.find_template(template_name)…
if not hasattr(template, 'render'):
# template needs to be compiled
template = Template(template, origin, template_name, engine=self)
return template
def render_to_string(self, template_name, context=None):
Variable | Value |
---|---|
self | <django.template.engine.Engine object at 0x00000203B12F7190> |
template_name | 'index.html' |
c:\python39\lib\site-packages\django\template\engine.py
, line 125, in find_template
raise ImproperlyConfigured(
"Invalid value in template loaders configuration: %r" % loader)
def find_template(self, name, dirs=None, skip=None):
tried = []
for loader in self.template_loaders:
try:
template = loader.get_template(name, skip=skip)…
return template, template.origin
except TemplateDoesNotExist as e:
tried.extend(e.tried)
raise TemplateDoesNotExist(name, tried=tried)
def from_string(self, template_code):
Variable | Value |
---|---|
dirs | None |
loader | <django.template.loaders.app_directories.Loader object at 0x00000203C358A670> |
name | 'index.html' |
self | <django.template.engine.Engine object at 0x00000203B12F7190> |
skip | None |
tried | [] |
c:\python39\lib\site-packages\django\template\loaders\base.py
, line 29, in get_template
try:
contents = self.get_contents(origin)
except TemplateDoesNotExist:
tried.append((origin, 'Source does not exist'))
continue
else:
return Template(…
contents, origin, origin.template_name, self.engine,
)
raise TemplateDoesNotExist(template_name, tried=tried)
def get_template_sources(self, template_name):
Variable | Value |
---|---|
contents | ('{% load static %}\n' '<!doctype html>\n' '<html lang="en">\n' '<meta charset="utf-8"><meta name="viewport" content="width=device-width, ' 'initial-scale=1" />\n' '<title>Scientific Research on CORONA</title>\n' '<meta name="keywords" content=""><meta name="description" content="">\n' '<link ' 'href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css" ' 'rel="stylesheet" />\n' '<style>\n' '@font-face {\n' " font-family: 'Roboto';\n" ' font-style: normal;\n' ' font-weight: 400;\n' " src: url({% static 'corona.sid.ir/assets/fonts/Roboto-Regular.ttf' %});\n" '}\n' '\n' '@font-face {\n' " font-family: 'Roboto';\n" ' font-style: normal;\n' ' font-weight: 700;\n' ' src: url(../../assets/fonts/Roboto-Bold.ttf);\n' '}\n' '\n' '@font-face {\n' " font-family: 'Roboto-Light';\n" ' font-style: normal;\n' ' font-weight: 300;\n' ' src: url(../../assets/fonts/Roboto-Light.ttf);\n' '}\n' '\n' 'body{\n' ' font-family: "Roboto", sans-serif;\n' ' line-height: 1.8;\n' '}\n' '\n' 'a:hover{\n' ' text-decoration: none;\n' '}\n' '\n' '@media screen and (min-width: 1200px) {\n' ' .container{\n' ' width: 1366px;\n' ' }\n' '}\n' '\n' 'html,body {\n' ' width: 100%;\n' ' height: 100%;\n' ' margin: 0px;\n' ' padding: 0px;\n' ' overflow-x: hidden; \n' '}\n' '\n' '.header--bg{\n' ' background: url("{% static ' '\'corona.sid.ir/assets/images/header-background.png\' %}") top center ' 'no-repeat;\n' ' background-size: cover;\n' ' }\n' '\n' '.header--wrapper{\n' ' padding-top: 190px;\n' ' padding-bottom: 200px;\n' ' }\n' '\n' '.header__title{\n' ' font-size: 80px;\n' ' color: #fff;\n' ' font-weight: 800;\n' ' }\n' '\n' '.header__title--light{\n' ' font-family: Roboto-Light;\n' ' font-weight: 100;\n' ' }\n' '\n' '.header__paragraph{\n' ' font-size: 20px;\n' ' color: #fff;\n' ' max-width: 850px;\n' ' font-family: Roboto-Light;\n' ' margin-bottom: 45px;\n' ' }\n' '\n' '@media screen and (max-width: 480px){\n' ' .header .header__title{\n' ' font-size: 52px;\n' ' }\n' '}\n' '\n' '.button{\n' ' padding: 8px 50px;\n' ' border-radius: 30px;\n' ' font-size: 18px;\n' ' color: #fff;\n' ' border: 1px solid #fff;\n' ' margin-right: 20px;\n' ' margin-top: 20px;\n' ' display: inline-block;\n' ' background-color: transparent;\n' ' position: relative;\n' ' font-family: Roboto-Light;\n' '}\n' '\n' '.button:after{\n' ' content: "";\n' ' position: absolute;\n' ' left: 0;\n' ' right: 0;\n' ' top: 0;\n' ' bottom: 0;\n' ' border-radius: inherit;\n' ' border: inherit;\n' ' -webkit-filter: drop-shadow(4px 5px 1px rgba(44, 189, 186, .6));\n' ' filter: drop-shadow(4px 5px 1px rgba(44, 189, 186, .6));\n' ' }\n' '\n' '.button:hover{\n' ' background-color: #00B8D4;\n' ' border-color: #00B8D4;\n' ' color: #fff;\n' ' -webkit-box-shadow: 3px 4px 7px #2BBBB8;\n' ' box-shadow: 3px 4px 7px #2BBBB8;\n' ' }\n' '\n' '.button:focus{\n' ' text-decoration: none;\n' ' color: #fff;\n' ' }\n' '\n' '.button__subscribe{\n' ' font-size: 15px;\n' ' background-color: #00B8D4;\n' ' padding: 9px 50px;\n' ' border-radius: 30px;\n' ' border: none;\n' ' color: #fff;\n' ' font-family: Roboto-Light;\n' ' -webkit-box-shadow: 2px 3px 6px rgba(181, 185, 185, 0.63);\n' ' box-shadow: 2px 3px 6px rgba(181, 185, 185, 0.63);\n' ' position: relative;\n' ' right: 60px;\n' ' }\n' '\n' '@media screen and (max-width: 480px){\n' ' .header .button{\n' ' margin-bottom: 20px;\n' ' }\n' '}\n' '\n' '@media screen and (max-width: 1000px){\n' ' .button__subscribe{\n' ' right: 0;\n' ' }\n' '}\n' '\n' '.process__section-container{\n' ' max-width: 630px;\n' ' height: 500px;\n' ' margin-right: auto;\n' ' margin-left: auto;\n' ' margin-top: 50px;\n' ' overflow: hidden;\n' ' background: url("{% static ' '\'corona.sid.ir/ass… <trimmed 24089 bytes string> |
origin | <django.template.base.Origin object at 0x00000203C352F850> |
self | <django.template.loaders.app_directories.Loader object at 0x00000203C358A670> |
skip | None |
template_name | 'index.html' |
tried | [(<django.template.base.Origin object at 0x00000203C352F730>, 'Source does not exist'), (<django.template.base.Origin object at 0x00000203C352F790>, 'Source does not exist')] |
c:\python39\lib\site-packages\django\template\base.py
, line 155, in __init__
engine = Engine.get_default()
if origin is None:
origin = Origin(UNKNOWN_SOURCE)
self.name = name
self.origin = origin
self.engine = engine
self.source = str(template_string) # May be lazy.
self.nodelist = self.compile_nodelist()…
def __iter__(self):
for node in self.nodelist:
yield from node
def _render(self, context):
Variable | Value |
---|---|
engine | <django.template.engine.Engine object at 0x00000203B12F7190> |
name | 'index.html' |
origin | <django.template.base.Origin object at 0x00000203C352F850> |
self | <django.template.base.Template object at 0x00000203C352F8E0> |
template_string | ('{% load static %}\n' '<!doctype html>\n' '<html lang="en">\n' '<meta charset="utf-8"><meta name="viewport" content="width=device-width, ' 'initial-scale=1" />\n' '<title>Scientific Research on CORONA</title>\n' '<meta name="keywords" content=""><meta name="description" content="">\n' '<link ' 'href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css" ' 'rel="stylesheet" />\n' '<style>\n' '@font-face {\n' " font-family: 'Roboto';\n" ' font-style: normal;\n' ' font-weight: 400;\n' " src: url({% static 'corona.sid.ir/assets/fonts/Roboto-Regular.ttf' %});\n" '}\n' '\n' '@font-face {\n' " font-family: 'Roboto';\n" ' font-style: normal;\n' ' font-weight: 700;\n' ' src: url(../../assets/fonts/Roboto-Bold.ttf);\n' '}\n' '\n' '@font-face {\n' " font-family: 'Roboto-Light';\n" ' font-style: normal;\n' ' font-weight: 300;\n' ' src: url(../../assets/fonts/Roboto-Light.ttf);\n' '}\n' '\n' 'body{\n' ' font-family: "Roboto", sans-serif;\n' ' line-height: 1.8;\n' '}\n' '\n' 'a:hover{\n' ' text-decoration: none;\n' '}\n' '\n' '@media screen and (min-width: 1200px) {\n' ' .container{\n' ' width: 1366px;\n' ' }\n' '}\n' '\n' 'html,body {\n' ' width: 100%;\n' ' height: 100%;\n' ' margin: 0px;\n' ' padding: 0px;\n' ' overflow-x: hidden; \n' '}\n' '\n' '.header--bg{\n' ' background: url("{% static ' '\'corona.sid.ir/assets/images/header-background.png\' %}") top center ' 'no-repeat;\n' ' background-size: cover;\n' ' }\n' '\n' '.header--wrapper{\n' ' padding-top: 190px;\n' ' padding-bottom: 200px;\n' ' }\n' '\n' '.header__title{\n' ' font-size: 80px;\n' ' color: #fff;\n' ' font-weight: 800;\n' ' }\n' '\n' '.header__title--light{\n' ' font-family: Roboto-Light;\n' ' font-weight: 100;\n' ' }\n' '\n' '.header__paragraph{\n' ' font-size: 20px;\n' ' color: #fff;\n' ' max-width: 850px;\n' ' font-family: Roboto-Light;\n' ' margin-bottom: 45px;\n' ' }\n' '\n' '@media screen and (max-width: 480px){\n' ' .header .header__title{\n' ' font-size: 52px;\n' ' }\n' '}\n' '\n' '.button{\n' ' padding: 8px 50px;\n' ' border-radius: 30px;\n' ' font-size: 18px;\n' ' color: #fff;\n' ' border: 1px solid #fff;\n' ' margin-right: 20px;\n' ' margin-top: 20px;\n' ' display: inline-block;\n' ' background-color: transparent;\n' ' position: relative;\n' ' font-family: Roboto-Light;\n' '}\n' '\n' '.button:after{\n' ' content: "";\n' ' position: absolute;\n' ' left: 0;\n' ' right: 0;\n' ' top: 0;\n' ' bottom: 0;\n' ' border-radius: inherit;\n' ' border: inherit;\n' ' -webkit-filter: drop-shadow(4px 5px 1px rgba(44, 189, 186, .6));\n' ' filter: drop-shadow(4px 5px 1px rgba(44, 189, 186, .6));\n' ' }\n' '\n' '.button:hover{\n' ' background-color: #00B8D4;\n' ' border-color: #00B8D4;\n' ' color: #fff;\n' ' -webkit-box-shadow: 3px 4px 7px #2BBBB8;\n' ' box-shadow: 3px 4px 7px #2BBBB8;\n' ' }\n' '\n' '.button:focus{\n' ' text-decoration: none;\n' ' color: #fff;\n' ' }\n' '\n' '.button__subscribe{\n' ' font-size: 15px;\n' ' background-color: #00B8D4;\n' ' padding: 9px 50px;\n' ' border-radius: 30px;\n' ' border: none;\n' ' color: #fff;\n' ' font-family: Roboto-Light;\n' ' -webkit-box-shadow: 2px 3px 6px rgba(181, 185, 185, 0.63);\n' ' box-shadow: 2px 3px 6px rgba(181, 185, 185, 0.63);\n' ' position: relative;\n' ' right: 60px;\n' ' }\n' '\n' '@media screen and (max-width: 480px){\n' ' .header .button{\n' ' margin-bottom: 20px;\n' ' }\n' '}\n' '\n' '@media screen and (max-width: 1000px){\n' ' .button__subscribe{\n' ' right: 0;\n' ' }\n' '}\n' '\n' '.process__section-container{\n' ' max-width: 630px;\n' ' height: 500px;\n' ' margin-right: auto;\n' ' margin-left: auto;\n' ' margin-top: 50px;\n' ' overflow: hidden;\n' ' background: url("{% static ' '\'corona.sid.ir/ass… <trimmed 24089 bytes string> |
c:\python39\lib\site-packages\django\template\base.py
, line 193, in compile_nodelist
tokens = lexer.tokenize()
parser = Parser(
tokens, self.engine.template_libraries, self.engine.template_builtins,
self.origin,
)
try:
return parser.parse()…
except Exception as e:
if self.engine.debug:
e.template_debug = self.get_exception_info(e, e.token)
raise
def get_exception_info(self, exception, token):
Variable | Value |
---|---|
lexer | <django.template.base.DebugLexer object at 0x00000203C352F8B0> |
parser | <django.template.base.Parser object at 0x00000203C3468460> |
self | <django.template.base.Template object at 0x00000203C352F8E0> |
tokens | [<django.template.base.Token object at 0x00000203C352F970>, <django.template.base.Token object at 0x00000203C352F9D0>, <django.template.base.Token object at 0x00000203C352FCD0>, <django.template.base.Token object at 0x00000203C352FD30>, <django.template.base.Token object at 0x00000203C352FD90>, <django.template.base.Token object at 0x00000203C352FDF0>, <django.template.base.Token object at 0x00000203C352FE50>, <django.template.base.Token object at 0x00000203C352FEB0>, <django.template.base.Token object at 0x00000203C352FF10>, <django.template.base.Token object at 0x00000203C352FF70>, <django.template.base.Token object at 0x00000203C352FFD0>, <django.template.base.Token object at 0x00000203C3474070>, <django.template.base.Token object at 0x00000203C34740D0>, <django.template.base.Token object at 0x00000203C3474130>, <django.template.base.Token object at 0x00000203C3474190>, <django.template.base.Token object at 0x00000203C34741F0>, <django.template.base.Token object at 0x00000203C3474250>, <django.template.base.Token object at 0x00000203C34742B0>, <django.template.base.Token object at 0x00000203C3474310>, <django.template.base.Token object at 0x00000203C3474370>, <django.template.base.Token object at 0x00000203C34743D0>, <django.template.base.Token object at 0x00000203C3474430>, <django.template.base.Token object at 0x00000203C3474490>, <django.template.base.Token object at 0x00000203C34744F0>, <django.template.base.Token object at 0x00000203C3474550>, <django.template.base.Token object at 0x00000203C34745B0>, <django.template.base.Token object at 0x00000203C3474610>, <django.template.base.Token object at 0x00000203C3474670>, <django.template.base.Token object at 0x00000203C34746D0>, <django.template.base.Token object at 0x00000203C3474730>, <django.template.base.Token object at 0x00000203C3474790>, <django.template.base.Token object at 0x00000203C34747F0>, <django.template.base.Token object at 0x00000203C3474850>, <django.template.base.Token object at 0x00000203C34748B0>, <django.template.base.Token object at 0x00000203C3474910>, <django.template.base.Token object at 0x00000203C3474970>, <django.template.base.Token object at 0x00000203C34749D0>, <django.template.base.Token object at 0x00000203C3474A30>, <django.template.base.Token object at 0x00000203C3474A90>, <django.template.base.Token object at 0x00000203C3474AF0>, <django.template.base.Token object at 0x00000203C3474B50>, <django.template.base.Token object at 0x00000203C3474BB0>, <django.template.base.Token object at 0x00000203C3474C10>, <django.template.base.Token object at 0x00000203C3474C70>, <django.template.base.Token object at 0x00000203C3474CD0>, <django.template.base.Token object at 0x00000203C3474D30>, <django.template.base.Token object at 0x00000203C3474D90>, <django.template.base.Token object at 0x00000203C3474DF0>, <django.template.base.Token object at 0x00000203C3474E50>, <django.template.base.Token object at 0x00000203C3474EB0>, <django.template.base.Token object at 0x00000203C3474F10>, <django.template.base.Token object at 0x00000203C3474F70>, <django.template.base.Token object at 0x00000203C3474FD0>, <django.template.base.Token object at 0x00000203C3486070>, <django.template.base.Token object at 0x00000203C34860D0>, <django.template.base.Token object at 0x00000203C3486130>, <django.template.base.Token object at 0x00000203C3486190>, <django.template.base.Token object at 0x00000203C34861F0>, <django.template.base.Token object at 0x00000203C3486250>, <django.template.base.Token object at 0x00000203C34862B0>, <django.template.base.Token object at 0x00000203C3486310>, <django.template.base.Token object at 0x00000203C3486370>, <django.template.base.Token object at 0x00000203C34863D0>, <django.template.base.Token object at 0x00000203C3486430>, <django.template.base.Token object at 0x00000203C3486490>, <django.template.base.Token object at 0x00000203C34864F0>, <django.template.base.Token object at 0x00000203C3486550>, <django.template.base.Token object at 0x00000203C34865B0>, <django.templat… <trimmed 6359 bytes string> |
c:\python39\lib\site-packages\django\template\base.py
, line 478, in parse
except KeyError:
self.invalid_block_tag(token, command, parse_until)
# Compile the callback into a node object and add it to
# the node list.
try:
compiled_result = compile_func(self, token)
except Exception as e:
raise self.error(token, e)…
self.extend_nodelist(nodelist, compiled_result, token)
# Compile success. Remove the token from the command stack.
self.command_stack.pop()
if parse_until:
self.unclosed_block_tag(parse_until)
return nodelist
Variable | Value |
---|---|
command | 'for' |
compile_func | <function do_for at 0x000002039C3A0F70> |
compiled_result | <django.templatetags.static.StaticNode object at 0x00000203C34689A0> |
filter_expression | <django.template.base.FilterExpression object at 0x00000203C3468A60> |
nodelist | [<django.template.defaulttags.LoadNode object at 0x00000203C3468490>, <TextNode: '\n<!doctype html>\n<html la'>, <django.templatetags.static.StaticNode object at 0x00000203C34685E0>, <TextNode: ');\n}\n\n@font-face {\n font'>, <django.templatetags.static.StaticNode object at 0x00000203C3468730>, <TextNode: '") top center no-repeat;\n'>, <django.templatetags.static.StaticNode object at 0x00000203C3468850>, <TextNode: '") no-repeat;\n backgro'>, <django.templatetags.static.StaticNode object at 0x00000203C34689A0>, <TextNode: '") top center no-repeat;\n'>, <Variable Node: num>, <TextNode: '</i> published papers stu'>] |
parse_until | [] |
self | <django.template.base.Parser object at 0x00000203C3468460> |
token | <django.template.base.Token object at 0x00000203C34740D0> |
var_node | <Variable Node: num> |
c:\python39\lib\site-packages\django\template\base.py
, line 476, in parse
try:
compile_func = self.tags[command]
except KeyError:
self.invalid_block_tag(token, command, parse_until)
# Compile the callback into a node object and add it to
# the node list.
try:
compiled_result = compile_func(self, token)…
except Exception as e:
raise self.error(token, e)
self.extend_nodelist(nodelist, compiled_result, token)
# Compile success. Remove the token from the command stack.
self.command_stack.pop()
if parse_until:
Variable | Value |
---|---|
command | 'for' |
compile_func | <function do_for at 0x000002039C3A0F70> |
compiled_result | <django.templatetags.static.StaticNode object at 0x00000203C34689A0> |
filter_expression | <django.template.base.FilterExpression object at 0x00000203C3468A60> |
nodelist | [<django.template.defaulttags.LoadNode object at 0x00000203C3468490>, <TextNode: '\n<!doctype html>\n<html la'>, <django.templatetags.static.StaticNode object at 0x00000203C34685E0>, <TextNode: ');\n}\n\n@font-face {\n font'>, <django.templatetags.static.StaticNode object at 0x00000203C3468730>, <TextNode: '") top center no-repeat;\n'>, <django.templatetags.static.StaticNode object at 0x00000203C3468850>, <TextNode: '") no-repeat;\n backgro'>, <django.templatetags.static.StaticNode object at 0x00000203C34689A0>, <TextNode: '") top center no-repeat;\n'>, <Variable Node: num>, <TextNode: '</i> published papers stu'>] |
parse_until | [] |
self | <django.template.base.Parser object at 0x00000203C3468460> |
token | <django.template.base.Token object at 0x00000203C34740D0> |
var_node | <Variable Node: num> |
c:\python39\lib\site-packages\django\template\defaulttags.py
, line 814, in do_for
loopvars = re.split(r' *, *', ' '.join(bits[1:in_index]))
for var in loopvars:
if not var or not invalid_chars.isdisjoint(var):
raise TemplateSyntaxError("'for' tag received an invalid argument:"
" %s" % token.contents)
sequence = parser.compile_filter(bits[in_index + 1])
nodelist_loop = parser.parse(('empty', 'endfor',))…
token = parser.next_token()
if token.contents == 'empty':
nodelist_empty = parser.parse(('endfor',))
parser.delete_first_token()
else:
nodelist_empty = None
Variable | Value |
---|---|
bits | ['for', 'au', 'in', 'authors'] |
in_index | -2 |
invalid_chars | frozenset({'|', ' ', "'", '"'}) |
is_reversed | False |
loopvars | ['au'] |
parser | <django.template.base.Parser object at 0x00000203C3468460> |
sequence | <django.template.base.FilterExpression object at 0x00000203C3468BE0> |
token | <django.template.base.Token object at 0x00000203C34740D0> |
var | 'au' |
c:\python39\lib\site-packages\django\template\base.py
, line 478, in parse
except KeyError:
self.invalid_block_tag(token, command, parse_until)
# Compile the callback into a node object and add it to
# the node list.
try:
compiled_result = compile_func(self, token)
except Exception as e:
raise self.error(token, e)…
self.extend_nodelist(nodelist, compiled_result, token)
# Compile success. Remove the token from the command stack.
self.command_stack.pop()
if parse_until:
self.unclosed_block_tag(parse_until)
return nodelist
Variable | Value |
---|---|
command | 'if' |
compile_func | <function do_if at 0x000002039C3A34C0> |
nodelist | [<TextNode: ' '>] |
parse_until | ('empty', 'endfor') |
self | <django.template.base.Parser object at 0x00000203C3468460> |
token | <django.template.base.Token object at 0x00000203C3474190> |
c:\python39\lib\site-packages\django\template\base.py
, line 476, in parse
try:
compile_func = self.tags[command]
except KeyError:
self.invalid_block_tag(token, command, parse_until)
# Compile the callback into a node object and add it to
# the node list.
try:
compiled_result = compile_func(self, token)…
except Exception as e:
raise self.error(token, e)
self.extend_nodelist(nodelist, compiled_result, token)
# Compile success. Remove the token from the command stack.
self.command_stack.pop()
if parse_until:
Variable | Value |
---|---|
command | 'if' |
compile_func | <function do_if at 0x000002039C3A34C0> |
nodelist | [<TextNode: ' '>] |
parse_until | ('empty', 'endfor') |
self | <django.template.base.Parser object at 0x00000203C3468460> |
token | <django.template.base.Token object at 0x00000203C3474190> |
c:\python39\lib\site-packages\django\template\defaulttags.py
, line 965, in do_if
``==``, ``!=``, ``>``, ``>=``, ``<`` and ``<=``.
Operator precedence follows Python.
"""
# {% if ... %}
bits = token.split_contents()[1:]
condition = TemplateIfParser(parser, bits).parse()
nodelist = parser.parse(('elif', 'else', 'endif'))…
conditions_nodelists = [(condition, nodelist)]
token = parser.next_token()
# {% elif ... %} (repeatable)
while token.contents.startswith('elif'):
bits = token.split_contents()[1:]
Variable | Value |
---|---|
bits | ['forloop.counter', '==', '1'] |
condition | (== (literal <django.template.base.FilterExpression object at 0x00000203C3468D90>) (literal <django.template.base.FilterExpression object at 0x00000203C3468F70>)) |
parser | <django.template.base.Parser object at 0x00000203C3468460> |
token | <django.template.base.Token object at 0x00000203C3474190> |
c:\python39\lib\site-packages\django\template\base.py
, line 478, in parse
except KeyError:
self.invalid_block_tag(token, command, parse_until)
# Compile the callback into a node object and add it to
# the node list.
try:
compiled_result = compile_func(self, token)
except Exception as e:
raise self.error(token, e)…
self.extend_nodelist(nodelist, compiled_result, token)
# Compile success. Remove the token from the command stack.
self.command_stack.pop()
if parse_until:
self.unclosed_block_tag(parse_until)
return nodelist
Variable | Value |
---|---|
command | 'if' |
compile_func | <function do_if at 0x000002039C3A34C0> |
compiled_result | <django.template.defaulttags.LoadNode object at 0x00000203C3480280> |
nodelist | [<TextNode: '\n<div class="item active"'>, <django.templatetags.static.StaticNode object at 0x00000203C3480160>, <TextNode: '" />\n<div class="carousel'>, <django.template.defaulttags.LoadNode object at 0x00000203C3480280>, <TextNode: ' '>] |
parse_until | ('elif', 'else', 'endif') |
self | <django.template.base.Parser object at 0x00000203C3468460> |
token | <django.template.base.Token object at 0x00000203C34743D0> |
c:\python39\lib\site-packages\django\template\base.py
, line 476, in parse
try:
compile_func = self.tags[command]
except KeyError:
self.invalid_block_tag(token, command, parse_until)
# Compile the callback into a node object and add it to
# the node list.
try:
compiled_result = compile_func(self, token)…
except Exception as e:
raise self.error(token, e)
self.extend_nodelist(nodelist, compiled_result, token)
# Compile success. Remove the token from the command stack.
self.command_stack.pop()
if parse_until:
Variable | Value |
---|---|
command | 'if' |
compile_func | <function do_if at 0x000002039C3A34C0> |
compiled_result | <django.template.defaulttags.LoadNode object at 0x00000203C3480280> |
nodelist | [<TextNode: '\n<div class="item active"'>, <django.templatetags.static.StaticNode object at 0x00000203C3480160>, <TextNode: '" />\n<div class="carousel'>, <django.template.defaulttags.LoadNode object at 0x00000203C3480280>, <TextNode: ' '>] |
parse_until | ('elif', 'else', 'endif') |
self | <django.template.base.Parser object at 0x00000203C3468460> |
token | <django.template.base.Token object at 0x00000203C34743D0> |
c:\python39\lib\site-packages\django\template\defaulttags.py
, line 964, in do_if
All supported operators are: ``or``, ``and``, ``in``, ``not in``
``==``, ``!=``, ``>``, ``>=``, ``<`` and ``<=``.
Operator precedence follows Python.
"""
# {% if ... %}
bits = token.split_contents()[1:]
condition = TemplateIfParser(parser, bits).parse()…
nodelist = parser.parse(('elif', 'else', 'endif'))
conditions_nodelists = [(condition, nodelist)]
token = parser.next_token()
# {% elif ... %} (repeatable)
while token.contents.startswith('elif'):
Variable | Value |
---|---|
bits | ['au.1|file_exists', '==', '1'] |
parser | <django.template.base.Parser object at 0x00000203C3468460> |
token | <django.template.base.Token object at 0x00000203C34743D0> |
c:\python39\lib\site-packages\django\template\defaulttags.py
, line 897, in __init__
class TemplateIfParser(IfParser):
error_class = TemplateSyntaxError
def __init__(self, parser, *args, **kwargs):
self.template_parser = parser
super().__init__(*args, **kwargs)…
def create_var(self, value):
return TemplateLiteral(self.template_parser.compile_filter(value), value)
@register.tag('if')
Variable | Value |
---|---|
__class__ | <class 'django.template.defaulttags.TemplateIfParser'> |
args | (['au.1|file_exists', '==', '1'],) |
kwargs | {} |
parser | <django.template.base.Parser object at 0x00000203C3468460> |
self | <django.template.defaulttags.TemplateIfParser object at 0x00000203C3480340> |
c:\python39\lib\site-packages\django\template\smartif.py
, line 166, in __init__
token = tokens[i]
if token == "is" and i + 1 < num_tokens and tokens[i + 1] == "not":
token = "is not"
i += 1 # skip 'not'
elif token == "not" and i + 1 < num_tokens and tokens[i + 1] == "in":
token = "not in"
i += 1 # skip 'in'
mapped_tokens.append(self.translate_token(token))…
i += 1
self.tokens = mapped_tokens
self.pos = 0
self.current_token = self.next_token()
Variable | Value |
---|---|
i | 0 |
mapped_tokens | [] |
num_tokens | 3 |
self | <django.template.defaulttags.TemplateIfParser object at 0x00000203C3480340> |
token | 'au.1|file_exists' |
tokens | ['au.1|file_exists', '==', '1'] |
c:\python39\lib\site-packages\django\template\smartif.py
, line 177, in translate_token
self.pos = 0
self.current_token = self.next_token()
def translate_token(self, token):
try:
op = OPERATORS[token]
except (KeyError, TypeError):
return self.create_var(token)…
else:
return op()
def next_token(self):
if self.pos >= len(self.tokens):
return EndToken
Variable | Value |
---|---|
self | <django.template.defaulttags.TemplateIfParser object at 0x00000203C3480340> |
token | 'au.1|file_exists' |
c:\python39\lib\site-packages\django\template\defaulttags.py
, line 900, in create_var
error_class = TemplateSyntaxError
def __init__(self, parser, *args, **kwargs):
self.template_parser = parser
super().__init__(*args, **kwargs)
def create_var(self, value):
return TemplateLiteral(self.template_parser.compile_filter(value), value)…
@register.tag('if')
def do_if(parser, token):
"""
Evaluate a variable, and if that variable is "true" (i.e., exists, is not
Variable | Value |
---|---|
self | <django.template.defaulttags.TemplateIfParser object at 0x00000203C3480340> |
value | 'au.1|file_exists' |
c:\python39\lib\site-packages\django\template\base.py
, line 563, in compile_filter
self.tags.update(lib.tags)
self.filters.update(lib.filters)
def compile_filter(self, token):
"""
Convenient wrapper for FilterExpression
"""
return FilterExpression(token, self)…
def find_filter(self, filter_name):
if filter_name in self.filters:
return self.filters[filter_name]
else:
raise TemplateSyntaxError("Invalid filter: '%s'" % filter_name)
Variable | Value |
---|---|
self | <django.template.base.Parser object at 0x00000203C3468460> |
token | 'au.1|file_exists' |
c:\python39\lib\site-packages\django\template\base.py
, line 657, in __init__
filter_name = match['filter_name']
args = []
constant_arg, var_arg = match['constant_arg'], match['var_arg']
if constant_arg:
args.append((False, Variable(constant_arg).resolve({})))
elif var_arg:
args.append((True, Variable(var_arg)))
filter_func = parser.find_filter(filter_name)…
self.args_check(filter_name, filter_func, args)
filters.append((filter_func, args))
upto = match.end()
if upto != len(token):
raise TemplateSyntaxError("Could not parse the remainder: '%s' "
"from '%s'" % (token[upto:], token))
Variable | Value |
---|---|
args | [] |
constant | None |
constant_arg | None |
filter_name | 'file_exists' |
filters | [] |
match | <re.Match object; span=(4, 16), match='|file_exists'> |
matches | <callable_iterator object at 0x00000203C3480400> |
parser | <django.template.base.Parser object at 0x00000203C3468460> |
self | <django.template.base.FilterExpression object at 0x00000203C34803A0> |
start | 4 |
token | 'au.1|file_exists' |
upto | 4 |
var | 'au.1' |
var_arg | None |
var_obj | <Variable: 'au.1'> |
c:\python39\lib\site-packages\django\template\base.py
, line 569, in find_filter
"""
return FilterExpression(token, self)
def find_filter(self, filter_name):
if filter_name in self.filters:
return self.filters[filter_name]
else:
raise TemplateSyntaxError("Invalid filter: '%s'" % filter_name)…
# This only matches constant *strings* (things in quotes or marked for
# translation). Numbers are treated as variables for implementation reasons
# (so that they retain their type when passed to filters).
constant_string = r"""
Variable | Value |
---|---|
filter_name | 'file_exists' |
self | <django.template.base.Parser object at 0x00000203C3468460> |
AnonymousUser
No GET data
No POST data
No FILES data
No cookie data
Variable | Value |
---|---|
APPL_MD_PATH | '/LM/W3SVC/3/ROOT' |
APPL_PHYSICAL_PATH | 'C:\\inetpub\\wwwroot\\da\\' |
APP_POOL_CONFIG | 'C:\\inetpub\\temp\\apppools\\da\\da.config' |
APP_POOL_ID | 'da' |
AUTH_PASSWORD | '********************' |
AUTH_TYPE | '' |
AUTH_USER | '' |
CERT_COOKIE | '' |
CERT_FLAGS | '' |
CERT_ISSUER | '' |
CERT_SERIALNUMBER | '' |
CERT_SUBJECT | '' |
CONTENT_LENGTH | '0' |
CONTENT_TYPE | '' |
DOCUMENT_ROOT | 'C:\\inetpub\\wwwroot\\da' |
GATEWAY_INTERFACE | 'CGI/1.1' |
HTTPS | 'on' |
HTTPS_KEYSIZE | '********************' |
HTTPS_SECRETKEYSIZE | '********************' |
HTTPS_SERVER_ISSUER | ('C=PL, O=Unizeto Technologies S.A., OU=Certum Certification Authority, ' 'CN=Certum Domain Validation CA SHA2') |
HTTPS_SERVER_SUBJECT | 'CN=*.sid.ir' |
HTTP_ACCEPT | '*/*' |
HTTP_CONNECTION | 'close' |
HTTP_HOST | 'vs1.sid.ir' |
HTTP_USER_AGENT | 'claudebot' |
INSTANCE_ID | '3' |
INSTANCE_META_PATH | '/LM/W3SVC/3' |
INSTANCE_NAME | 'DA' |
LOCAL_ADDR | '45.159.115.20' |
LOGON_USER | '' |
PATH_INFO | '/corona/' |
PATH_TRANSLATED | 'C:\\inetpub\\wwwroot\\da\\corona\\' |
QUERY_STRING | '' |
REMOTE_ADDR | '44.192.75.131' |
REMOTE_HOST | '44.192.75.131' |
REMOTE_PORT | '42014' |
REMOTE_USER | '' |
REQUEST_METHOD | 'GET' |
REQUEST_URI | '/corona/' |
SCRIPT_FILENAME | 'C:\\inetpub\\wwwroot\\da\\corona\\' |
SCRIPT_NAME | '' |
SERVER_NAME | 'vs1.sid.ir' |
SERVER_PORT | '443' |
SERVER_PORT_SECURE | '1' |
SERVER_PROTOCOL | 'HTTP/1.1' |
SERVER_SOFTWARE | 'Microsoft-IIS/10.0' |
URL | '/corona/' |
wsgi.errors | <_io.StringIO object at 0x00000203B13514C0> |
wsgi.input | <_io.BytesIO object at 0x00000203B13529A0> |
wsgi.multiprocess | True |
wsgi.multithread | False |
wsgi.path_info | b'/corona/' |
wsgi.query_string | b'' |
wsgi.run_once | False |
wsgi.script_name | b'' |
wsgi.url_scheme | 'https' |
wsgi.version | (1, 0) |
da.settings
Setting | Value |
---|---|
ABSOLUTE_URL_OVERRIDES | {} |
ADMINS | [] |
ALLOWED_HOSTS | ['45.159.115.20', '127.0.0.1', 'vs1.sid.ir', 'depth.sid.ir', 'localhost', 'corona.alzahra.ac.ir'] |
ALLOW_UNICODE_SLUGS | True |
APPEND_SLASH | True |
AUTHENTICATION_BACKENDS | ['django.contrib.auth.backends.ModelBackend'] |
AUTH_PASSWORD_VALIDATORS | '********************' |
AUTH_USER_MODEL | 'auth.User' |
BASE_DIR | WindowsPath('C:/inetpub/wwwroot/da') |
CACHES | {'default': {'BACKEND': 'django.core.cache.backends.locmem.LocMemCache'}} |
CACHE_MIDDLEWARE_ALIAS | 'default' |
CACHE_MIDDLEWARE_KEY_PREFIX | '********************' |
CACHE_MIDDLEWARE_SECONDS | 600 |
CSRF_COOKIE_AGE | 31449600 |
CSRF_COOKIE_DOMAIN | None |
CSRF_COOKIE_HTTPONLY | False |
CSRF_COOKIE_NAME | 'csrftoken' |
CSRF_COOKIE_PATH | '/' |
CSRF_COOKIE_SAMESITE | 'Lax' |
CSRF_COOKIE_SECURE | False |
CSRF_FAILURE_VIEW | 'django.views.csrf.csrf_failure' |
CSRF_HEADER_NAME | 'HTTP_X_CSRFTOKEN' |
CSRF_TRUSTED_ORIGINS | [] |
CSRF_USE_SESSIONS | False |
DATABASES | {'default': {'ATOMIC_REQUESTS': False, 'AUTOCOMMIT': True, 'CONN_MAX_AGE': 0, 'ENGINE': 'django.db.backends.sqlite3', 'HOST': '', 'NAME': WindowsPath('C:/inetpub/wwwroot/da/db.sqlite3'), 'OPTIONS': {}, 'PASSWORD': '********************', 'PORT': '', 'TEST': {'CHARSET': None, 'COLLATION': None, 'MIGRATE': True, 'MIRROR': None, 'NAME': None}, 'TIME_ZONE': None, 'USER': ''}} |
DATABASE_ROUTERS | [] |
DATA_UPLOAD_MAX_MEMORY_SIZE | 2621440 |
DATA_UPLOAD_MAX_NUMBER_FIELDS | 1000 |
DATETIME_FORMAT | 'N j, Y, P' |
DATETIME_INPUT_FORMATS | ['%Y-%m-%d %H:%M:%S', '%Y-%m-%d %H:%M:%S.%f', '%Y-%m-%d %H:%M', '%m/%d/%Y %H:%M:%S', '%m/%d/%Y %H:%M:%S.%f', '%m/%d/%Y %H:%M', '%m/%d/%y %H:%M:%S', '%m/%d/%y %H:%M:%S.%f', '%m/%d/%y %H:%M'] |
DATE_FORMAT | 'N j, Y' |
DATE_INPUT_FORMATS | ['%Y-%m-%d', '%m/%d/%Y', '%m/%d/%y', '%b %d %Y', '%b %d, %Y', '%d %b %Y', '%d %b, %Y', '%B %d %Y', '%B %d, %Y', '%d %B %Y', '%d %B, %Y'] |
DEBUG | True |
DEBUG_PROPAGATE_EXCEPTIONS | False |
DECIMAL_SEPARATOR | '.' |
DEFAULT_AUTO_FIELD | 'django.db.models.BigAutoField' |
DEFAULT_CHARSET | 'utf-8' |
DEFAULT_EXCEPTION_REPORTER | 'django.views.debug.ExceptionReporter' |
DEFAULT_EXCEPTION_REPORTER_FILTER | 'django.views.debug.SafeExceptionReporterFilter' |
DEFAULT_FILE_STORAGE | 'django.core.files.storage.FileSystemStorage' |
DEFAULT_FROM_EMAIL | 'webmaster@localhost' |
DEFAULT_HASHING_ALGORITHM | 'sha256' |
DEFAULT_INDEX_TABLESPACE | '' |
DEFAULT_TABLESPACE | '' |
DISALLOWED_USER_AGENTS | [] |
EMAIL_BACKEND | 'django.core.mail.backends.smtp.EmailBackend' |
EMAIL_HOST | 'localhost' |
EMAIL_HOST_PASSWORD | '********************' |
EMAIL_HOST_USER | '' |
EMAIL_PORT | 25 |
EMAIL_SSL_CERTFILE | None |
EMAIL_SSL_KEYFILE | '********************' |
EMAIL_SUBJECT_PREFIX | '[Django] ' |
EMAIL_TIMEOUT | None |
EMAIL_USE_LOCALTIME | False |
EMAIL_USE_SSL | False |
EMAIL_USE_TLS | False |
FILE_UPLOAD_DIRECTORY_PERMISSIONS | None |
FILE_UPLOAD_HANDLERS | ['django.core.files.uploadhandler.MemoryFileUploadHandler', 'django.core.files.uploadhandler.TemporaryFileUploadHandler'] |
FILE_UPLOAD_MAX_MEMORY_SIZE | 2621440 |
FILE_UPLOAD_PERMISSIONS | 420 |
FILE_UPLOAD_TEMP_DIR | None |
FIRST_DAY_OF_WEEK | 0 |
FIXTURE_DIRS | [] |
FORCE_SCRIPT_NAME | None |
FORMAT_MODULE_PATH | None |
FORM_RENDERER | 'django.forms.renderers.DjangoTemplates' |
IGNORABLE_404_URLS | [] |
INSTALLED_APPS | ['django.contrib.admin', 'django.contrib.auth', 'django.contrib.contenttypes', 'django.contrib.sessions', 'django.contrib.messages', 'django.contrib.staticfiles', 'polls', 'depth', 'corona'] |
INTERNAL_IPS | [] |
LANGUAGES | [('af', 'Afrikaans'), ('ar', 'Arabic'), ('ar-dz', 'Algerian Arabic'), ('ast', 'Asturian'), ('az', 'Azerbaijani'), ('bg', 'Bulgarian'), ('be', 'Belarusian'), ('bn', 'Bengali'), ('br', 'Breton'), ('bs', 'Bosnian'), ('ca', 'Catalan'), ('cs', 'Czech'), ('cy', 'Welsh'), ('da', 'Danish'), ('de', 'German'), ('dsb', 'Lower Sorbian'), ('el', 'Greek'), ('en', 'English'), ('en-au', 'Australian English'), ('en-gb', 'British English'), ('eo', 'Esperanto'), ('es', 'Spanish'), ('es-ar', 'Argentinian Spanish'), ('es-co', 'Colombian Spanish'), ('es-mx', 'Mexican Spanish'), ('es-ni', 'Nicaraguan Spanish'), ('es-ve', 'Venezuelan Spanish'), ('et', 'Estonian'), ('eu', 'Basque'), ('fa', 'Persian'), ('fi', 'Finnish'), ('fr', 'French'), ('fy', 'Frisian'), ('ga', 'Irish'), ('gd', 'Scottish Gaelic'), ('gl', 'Galician'), ('he', 'Hebrew'), ('hi', 'Hindi'), ('hr', 'Croatian'), ('hsb', 'Upper Sorbian'), ('hu', 'Hungarian'), ('hy', 'Armenian'), ('ia', 'Interlingua'), ('id', 'Indonesian'), ('ig', 'Igbo'), ('io', 'Ido'), ('is', 'Icelandic'), ('it', 'Italian'), ('ja', 'Japanese'), ('ka', 'Georgian'), ('kab', 'Kabyle'), ('kk', 'Kazakh'), ('km', 'Khmer'), ('kn', 'Kannada'), ('ko', 'Korean'), ('ky', 'Kyrgyz'), ('lb', 'Luxembourgish'), ('lt', 'Lithuanian'), ('lv', 'Latvian'), ('mk', 'Macedonian'), ('ml', 'Malayalam'), ('mn', 'Mongolian'), ('mr', 'Marathi'), ('my', 'Burmese'), ('nb', 'Norwegian Bokmål'), ('ne', 'Nepali'), ('nl', 'Dutch'), ('nn', 'Norwegian Nynorsk'), ('os', 'Ossetic'), ('pa', 'Punjabi'), ('pl', 'Polish'), ('pt', 'Portuguese'), ('pt-br', 'Brazilian Portuguese'), ('ro', 'Romanian'), ('ru', 'Russian'), ('sk', 'Slovak'), ('sl', 'Slovenian'), ('sq', 'Albanian'), ('sr', 'Serbian'), ('sr-latn', 'Serbian Latin'), ('sv', 'Swedish'), ('sw', 'Swahili'), ('ta', 'Tamil'), ('te', 'Telugu'), ('tg', 'Tajik'), ('th', 'Thai'), ('tk', 'Turkmen'), ('tr', 'Turkish'), ('tt', 'Tatar'), ('udm', 'Udmurt'), ('uk', 'Ukrainian'), ('ur', 'Urdu'), ('uz', 'Uzbek'), ('vi', 'Vietnamese'), ('zh-hans', 'Simplified Chinese'), ('zh-hant', 'Traditional Chinese')] |
LANGUAGES_BIDI | ['he', 'ar', 'ar-dz', 'fa', 'ur'] |
LANGUAGE_CODE | 'en-us' |
LANGUAGE_COOKIE_AGE | None |
LANGUAGE_COOKIE_DOMAIN | None |
LANGUAGE_COOKIE_HTTPONLY | False |
LANGUAGE_COOKIE_NAME | 'django_language' |
LANGUAGE_COOKIE_PATH | '/' |
LANGUAGE_COOKIE_SAMESITE | None |
LANGUAGE_COOKIE_SECURE | False |
LOCALE_PATHS | [] |
LOGGING | {} |
LOGGING_CONFIG | 'logging.config.dictConfig' |
LOGIN_REDIRECT_URL | '/accounts/profile/' |
LOGIN_URL | '/accounts/login/' |
LOGOUT_REDIRECT_URL | None |
MANAGERS | [] |
MEDIA_ROOT | 'C:\\inetpub\\wwwroot\\da\\media' |
MEDIA_URL | '/' |
MESSAGE_STORAGE | 'django.contrib.messages.storage.fallback.FallbackStorage' |
MIDDLEWARE | ['django.middleware.security.SecurityMiddleware', 'django.contrib.sessions.middleware.SessionMiddleware', 'django.middleware.common.CommonMiddleware', 'django.middleware.csrf.CsrfViewMiddleware', 'django.contrib.auth.middleware.AuthenticationMiddleware', 'django.contrib.messages.middleware.MessageMiddleware', 'django.middleware.clickjacking.XFrameOptionsMiddleware'] |
MIGRATION_MODULES | {} |
MONTH_DAY_FORMAT | 'F j' |
NUMBER_GROUPING | 0 |
PASSWORD_HASHERS | '********************' |
PASSWORD_RESET_TIMEOUT | '********************' |
PASSWORD_RESET_TIMEOUT_DAYS | '********************' |
PREPEND_WWW | False |
ROOT_URLCONF | 'da.urls' |
SECRET_KEY | '********************' |
SECURE_BROWSER_XSS_FILTER | False |
SECURE_CONTENT_TYPE_NOSNIFF | True |
SECURE_HSTS_INCLUDE_SUBDOMAINS | False |
SECURE_HSTS_PRELOAD | False |
SECURE_HSTS_SECONDS | 0 |
SECURE_PROXY_SSL_HEADER | None |
SECURE_REDIRECT_EXEMPT | [] |
SECURE_REFERRER_POLICY | 'same-origin' |
SECURE_SSL_HOST | None |
SECURE_SSL_REDIRECT | False |
SERVER_EMAIL | 'root@localhost' |
SESSION_CACHE_ALIAS | 'default' |
SESSION_COOKIE_AGE | 1209600 |
SESSION_COOKIE_DOMAIN | None |
SESSION_COOKIE_HTTPONLY | True |
SESSION_COOKIE_NAME | 'sessionid' |
SESSION_COOKIE_PATH | '/' |
SESSION_COOKIE_SAMESITE | 'Lax' |
SESSION_COOKIE_SECURE | False |
SESSION_ENGINE | 'django.contrib.sessions.backends.db' |
SESSION_EXPIRE_AT_BROWSER_CLOSE | False |
SESSION_FILE_PATH | None |
SESSION_SAVE_EVERY_REQUEST | False |
SESSION_SERIALIZER | 'django.contrib.sessions.serializers.JSONSerializer' |
SETTINGS_MODULE | 'da.settings' |
SHORT_DATETIME_FORMAT | 'm/d/Y P' |
SHORT_DATE_FORMAT | 'm/d/Y' |
SIGNING_BACKEND | 'django.core.signing.TimestampSigner' |
SILENCED_SYSTEM_CHECKS | [] |
STATICFILES_DIRS | [] |
STATICFILES_FINDERS | ['django.contrib.staticfiles.finders.FileSystemFinder', 'django.contrib.staticfiles.finders.AppDirectoriesFinder'] |
STATICFILES_STORAGE | 'django.contrib.staticfiles.storage.StaticFilesStorage' |
STATIC_ROOT | 'C:\\inetpub\\wwwroot\\da\\polls\\static' |
STATIC_URL | '/static/' |
TEMPLATES | [{'APP_DIRS': True, 'BACKEND': 'django.template.backends.django.DjangoTemplates', 'DIRS': [], 'OPTIONS': {'context_processors': ['django.template.context_processors.debug', 'django.template.context_processors.request', 'django.contrib.auth.context_processors.auth', 'django.contrib.messages.context_processors.messages']}}] |
TEST_NON_SERIALIZED_APPS | [] |
TEST_RUNNER | 'django.test.runner.DiscoverRunner' |
THOUSAND_SEPARATOR | ',' |
TIME_FORMAT | 'P' |
TIME_INPUT_FORMATS | ['%H:%M:%S', '%H:%M:%S.%f', '%H:%M'] |
TIME_ZONE | 'UTC' |
USE_I18N | True |
USE_L10N | True |
USE_THOUSAND_SEPARATOR | False |
USE_TZ | True |
USE_X_FORWARDED_HOST | False |
USE_X_FORWARDED_PORT | False |
WSGI_APPLICATION | 'da.wsgi.application' |
X_FRAME_OPTIONS | 'DENY' |
YEAR_MONTH_FORMAT | 'F Y' |
You’re seeing this error because you have DEBUG = True
in your
Django settings file. Change that to False
, and Django will
display a standard page generated by the handler for this status code.