Skip to content

Instantly share code, notes, and snippets.

View z4y4ts's full-sized avatar
🎯
Focusing

Alexander Zayats z4y4ts

🎯
Focusing
View GitHub Profile

Keybase proof

I hereby claim:

  • I am z4y4ts on github.
  • I am z4y4ts (https://keybase.io/z4y4ts) on keybase.
  • I have a public key whose fingerprint is 9C79 3402 522B EA66 8980 12E4 96D4 51CA 7511 C6B5

To claim this, I am signing this object:

@z4y4ts
z4y4ts / iterm2-solarized.md
Created March 4, 2017 22:15 — forked from kevin-smets/iterm2-solarized.md
iTerm2 + Oh My Zsh + Solarized color scheme + Meslo powerline font + [Powerlevel9k] - (macOS)

Default

Default

Powerlevel9k

Powerlevel9k

@z4y4ts
z4y4ts / test-results.txt
Created October 10, 2016 16:37
load test results
SQLite 5000 users
Name # reqs # fails Avg Min Max | Median req/s
--------------------------------------------------------------------------------------------------------------------------------------------
GET /api/v1/course/CMUSTAT101/user/[name] 30754 0(0.00%) 942 7 63913 | 690 84.00
OPTIONS /api/v1/course/CMUSTAT101/user/[name]/interaction 13095 0(0.00%) 725 2 32337 | 500 35.20
POST /api/v1/course/CMUSTAT101/user/[name]/interaction 12736 0(0.00%) 10890 87 44885 | 11000 68.10
OPTIONS /api/v1/course/CMUSTAT101/user/[name]/pageload 3928 0(0.00%) 690 3 31869 | 470 10.20
POST /api/v1/course/CMUSTAT101/user/[name]/pageload 3949 0(0.00%) 927 30 32909 | 800 9.60
-------------------------------------------------------------------------------------------------------------
@z4y4ts
z4y4ts / alex1_log.json
Last active October 13, 2016 15:29
interaction.json
[
{
"problem": {
"posttest": false,
"pretest": true,
"problem_name": "Pre_assessment_0",
"skills": [
"center"
],
"tutor_url": "http://52.50.241.19/courses/course-v1:CMU+STAT101+2014_T1/courseware/statistics/Pre_assessment_0"
@z4y4ts
z4y4ts / app.py
Last active August 29, 2015 14:21 — forked from theskumar/app.py
# -*- coding: utf-8 -*-
''' Generates database schema graph from a relational database.
Usages:
Add database configuation in this file and then
python app.py
Note: You must have your latest database schema in the database
engine you are running against.
'''
from __future__ import unicode_literals, absolute_import
@z4y4ts
z4y4ts / base.py
Last active August 29, 2015 14:17 — forked from mrjoes/base.py
Flask-Admin CSV export model view
class BaseModelView(ModelView):
list_template = 'admin/model_list.html'
export_columns = None
# Exporting
def _get_data_for_export(self):
view_args = self._get_list_extra_args()
# Map column index to column name
@z4y4ts
z4y4ts / exception
Last active August 29, 2015 14:07
mongoshmongo
Traceback (most recent call last):
File "metrics.py", line 32, in <module>
test()
File "metrics.py", line 27, in test
distance_type='jaccard')
File "/Users/ai/.virtualenvs/unshred/lib/python2.7/site-packages/mongoengine/queryset/base.py", line 201, in create
return self._document(**kwargs).save()
File "/Users/ai/.virtualenvs/unshred/lib/python2.7/site-packages/mongoengine/document.py", line 229, in save
doc = self.to_mongo()
File "/Users/ai/.virtualenvs/unshred/lib/python2.7/site-packages/mongoengine/base/document.py", line 255, in to_mongo
@z4y4ts
z4y4ts / cars.json
Created October 26, 2013 15:49
cars.json
[{"car_model": "Fiat Doblo",
"driver_name": "Vova Igorevich",
"location": "50.438263,30.526319",
"plate_id": "HT 8345 CT",
"status": "free",
"url": "/car/937"},
{"car_model": "Ford Mondeo",
"driver_name": "Vova Alexovich",
"location": "50.447320,30.457700",
"plate_id": "IP 0157 IK",
diff --git a/gluon/languages.py b/gluon/languages.py
--- a/gluon/languages.py
+++ b/gluon/languages.py
@@ -283,6 +283,7 @@
def write_plural_dict(filename, contents):
+ return
if '__corrupted__' in contents:
return