0003-py3-use-b64encode-46576.patch
passerelle_minint/minint_maarch/views.py | ||
---|---|---|
14 | 14 |
# You should have received a copy of the GNU Affero General Public License |
15 | 15 |
# along with this program. If not, see <http://www.gnu.org/licenses/>. |
16 | 16 | |
17 |
import requests
|
|
17 |
import base64
|
|
18 | 18 |
from datetime import datetime |
19 | 19 |
import logging |
20 | 20 |
import re |
21 |
import requests |
|
21 | 22 | |
22 | 23 |
from django.views.generic import DetailView as GenericDetailView |
23 | 24 |
from django.utils.decorators import method_decorator |
... | ... | |
165 | 166 |
if page and not empty_page: # add last page, if it contains values |
166 | 167 |
document += page |
167 | 168 |
document += '</body></html>' |
168 |
encodedFile = document.encode('utf-8').encode('base64')
|
|
169 |
encodedFile = base64.b64encode(document.encode('utf-8'))
|
|
169 | 170 |
fileFormat = 'html' |
170 | 171 | |
171 | 172 |
if debug: |
... | ... | |
569 | 570 |
document += page |
570 | 571 |
document += '</body></html>' |
571 | 572 |
logger.debug('DOCUMENT HTML %r ', document) |
572 |
encodedFile = document.encode('utf-8').encode('base64')
|
|
573 |
encodedFile = base64.b64encode(document.encode('utf-8'))
|
|
573 | 574 |
fileFormat = 'html' |
574 | 575 | |
575 | 576 |
if debug: |
576 |
- |