PT

.wsgi script Python

Texto e código-fonte

Tipo MIMEtext/x-python
Descriçãoscript Python
CategoriaTexto e código-fonte
Assinatura (magic bytes)23 21 20 2F 62 69 6E 2F 70 79 74 68 6F 6E (#! /bin/python)
23 21 2F 62 69 6E 2F 70 79 74 68 6F 6E (#!/bin/python)
Baseado emapplication/x-executable, text/plain
Outras extensões.py, .pyx

Perguntas frequentes

O que é um arquivo .wsgi?

Um arquivo .wsgi é um formato do tipo “script Python” (tipo MIME text/x-python).

Como abro um arquivo .wsgi?

Com qualquer editor de texto – Notepad++, Visual Studio Code, ou gedit e vim no Linux. O arquivo contém texto legível, possivelmente código-fonte ou configuração.

Como reconhecer um arquivo .wsgi verdadeiro?

Pelos bytes do início do arquivo, a assinatura (magic bytes): 23 21 20 2F 62 69 6E 2F 70 79 74 68 6F 6E (#! /bin/python) e 23 21 2F 62 69 6E 2F 70 79 74 68 6F 6E (#!/bin/python). No Linux e no macOS, file --mime-type example.wsgi verifica o tipo real independentemente da extensão.

Em qual formato .wsgi se baseia?

Tecnicamente, um arquivo .wsgi é um subtipo de “Executable” (application/x-executable); por isso, programas para esse formato base muitas vezes também conseguem lê-lo.

Qual tipo MIME corresponde a .wsgi?

O tipo MIME é text/x-python. No servidor web Apache: AddType text/x-python .wsgi; no nginx: types { text/x-python wsgi; }.

Entradas próximas