Skip to content

Instantly share code, notes, and snippets.

View Surgo's full-sized avatar
🛰️
Generating...

Kosei Kitahara Surgo

🛰️
Generating...
View GitHub Profile
@azu
azu / Incremental DOM.md
Last active July 13, 2022 16:07
Incremental DOM ざっと見たやつ。追記: 初期バージョンのコードなので最新では異なる場合があります。

Incremental DOM

Introducing Incremental DOM — Google Developers — Medium

Reactやvirtual-dom、Glimmer(Ember)などVirtual DOMの実装は色々あるが、これらのVirtual DOM実装には2つの問題がある

  • 既存のテンプレート言語を利用していない(しにくい)
  • モバイルでのパフォーマンス、特にメモリに関しては大きすぎる

これらを解決するためにIncremental DOMと言うものを作っている(WIP)

@rokujyouhitoma
rokujyouhitoma / patched.py
Created March 10, 2015 07:41
locust and gevent patch for python2.7.9
#https://github.com/gevent/gevent/issues/477#issuecomment-56292848
# # Re-add sslwrap to Python 2.7.9
import inspect
__ssl__ = __import__('ssl')
try:
_ssl = __ssl__._ssl
except AttributeError:
_ssl = __ssl__._ssl2
@rokujyouhitoma
rokujyouhitoma / gist:173b75f030a1f1f22591
Created September 19, 2014 04:40
PythonでHTTP RequestとResponseの生文字列を確認したい時のモンキーパッチ
def http_connection_send():
import httplib
def patch_send():
old_send= httplib.HTTPConnection.send
def new_send(self, data, *args, **kwargs):
print(data)
body = old_send(self, data, *args, **kwargs)
return body
httplib.HTTPConnection.send = new_send
patch_send()
@reclosedev
reclosedev / celery_sentinel.py
Last active April 24, 2019 00:01
Temporary hack. Redis Sentinel support for Celery.
"""
This module adds Redis Sentinel transport support to Celery.
Current version of celery doesn't support Redis sentinel client, which is must have for automatic failover.
To use it::
import register_celery_alias
register_celery_alias("redis-sentinel")
celery = Celery(..., broker="redis-sentinel://...", backend="redis-sentinel://...")
@diyan
diyan / python_stack.md
Last active September 3, 2020 10:32
Tools and libraries which I prefer to use in Python stack

Tools and libraries which I prefer to use in Python stack

Development Environment

  • Ubuntu Linux for both development and production
  • Git version control system
  • Jenkins CI build server (but recently I'm moving to git server-side hooks with ssh from git server to dev/stage/prod servers)
  • Redmine bug tracking system
  • JetBrains PyCharm IDE

Production Environment

@tcnksm
tcnksm / docker_cheat.md
Last active January 14, 2025 15:09 — forked from wsargent/docker_cheat.md
Docker 虎の巻

Docker 虎の巻

何故Dockerを使うべきか

Why Should I Care (For Developers)

"Dockerが面白いのはシンプルな環境に隔離性と再現性をもたらしてくれることだ.ランタイムの環境を一度作れば、パッケージにして別のマシンでも再利用することできる.さらに,すべてはホスト内の隔離された環境で行われる(VMのように).最も素晴らしい点は,シンプルかつ高速であることだ."

@voluntas
voluntas / sentry_django.rst
Last active March 26, 2020 01:23
Sentry + Django コトハジメ
@voluntas
voluntas / haystack_es_kuromoji.rst
Last active March 12, 2024 07:08
Haystack + Elasticsearch + kuromoji コトハジメ

Haystack + Elasticsearch + kuromoji コトハジメ

更新:2013-09-28
バージョン:0.0.9
作者:@voluntas
URL:http://voluntas.github.io/

Django + Elasticsearch コトハジメの補足記事です