Skip to content

Instantly share code, notes, and snippets.

Yuri Mashukov Jazzis18

  • Russia, Yekaterinburg
Block or report user

Report or block Jazzis18

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@Jazzis18
Jazzis18 / solution.md
Last active Oct 6, 2017
OSError: Cannot load native module 'Cryptodome.Cipher._raw_ecb'
View solution.md
  1. Make sure you have C:\Python34\Lib\site-packages\PyInstaller\hooks\hook-Cryptodome.py
  2. Go to C:\Python34\Lib\site-packages, and copy (sic!) Crypto module, and name it Cryptodome.
  3. Go to C:\Python34\Lib\site-packages\Crypto\Util\_raw_api.py, and rename imports from Crypto to Cryptodome. It should look like this:
from Cryptodome.Util.py3compat import byte_string
from Cryptodome.Util._file_system import pycryptodome_filename
@Jazzis18
Jazzis18 / python django create and download zip.py
Last active Jan 12, 2017 — forked from viveksoundrapandi/python django create and download zip
A simple snippet to zip files in a directory and send it the browser in downloadable format in django
View python django create and download zip.py
from shutil import make_archive
from wsgiref.util import FileWrapper
def download(request, file_name=""):
"""
A django view to zip files in directory and send it as downloadable response to the browser.
Args:
@request: Django request object
@file_name: Name of the directory to be zipped
Returns:
A downloadable Http response
View open_xls_as_xlsx.py
import xlrd
from openpyxl.workbook import Workbook
from openpyxl.reader.excel import load_workbook, InvalidFileException
def open_xls_as_xlsx(filename):
# first open using xlrd
book = xlrd.open_workbook(filename)
index = 0
nrows, ncols = 0, 0
while nrows * ncols == 0:
@Jazzis18
Jazzis18 / README.md
Last active Jun 12, 2016
Habitica Scripts
View README.md

Общее ридми для скриптов, которые запускаются из консоли.

Перед использованием:
  1. Нажать ПКМ по странице, на которой будете запускать скрипт.
  2. Выбрать "Просмотреть код" (Inspect Element) в самом низу.
  3. Открыть вкладку Console.
Использование:
  1. Скопировать скрипт и вставить в консоль.
  2. Нажать Enter.
You can’t perform that action at this time.