Skip to content

Instantly share code, notes, and snippets.

View tsabat's full-sized avatar

Tim Sabat tsabat

View GitHub Profile
@tsabat
tsabat / lets_breakup.py
Last active July 1, 2022 16:18
Breaks a large csv file up into smaller chunks.
#!/usr/bin/env python
import sys
import csv
import argparse
from pathlib import Path
import chardet
from urllib3 import encode_multipart_formdata
csv.field_size_limit(sys.maxsize)
@tsabat
tsabat / settings.py
Created February 7, 2021 22:32 — forked from defulmere/settings.py
How to override an old sqlite3 module with pysqlite3 in django settings.py
# first: pip install pysqlite3-binary
# then in settings.py:
# these three lines swap the stdlib sqlite3 lib with the pysqlite3 package
__import__('pysqlite3')
import sys
sys.modules['sqlite3'] = sys.modules.pop('pysqlite3')
DATABASES = {
'default': {
1) "schedules_changed"
2) "stat:processed:2018-08-06"
3) "stat:failed:2018-09-06"
4) "stat:failed:2020-03-01"
5) "stat:failed:2020-01-12"
6) "stat:failed:2018-10-12"
7) "stat:processed:2018-09-01"
8) "stat:processed:2019-09-27"
9) "stat:failed:2020-02-23"
10) "stat:processed:2018-12-08"
@tsabat
tsabat / index.haml
Created September 26, 2018 17:38
qMevwg
%h1 hi
{
"product_id": "HL-104",
"product_name": "32-oz. Pail with Handle",
"description": "HumphreyLine 32-ounce pail is made with premium materials. Optional (non-decorated) White Lid available at US $0.25/CDN $0.50 (G) each. Optional Shovels also available at US $0.25/CDN $0.50 (G) each. Pail includes handle. Must specify handle color. Handles and Optional Shovels are available in: White, Red, Blue or Black. All optional accessories packed separately. Made in USA. FOB ZIP: KY, 41042",
"product_marketing_point_array": {
"product_marketing_point": {
"point_type": "downloads-Art Template",
"point_copy": "Click on the PDF link below to download: <br /><a href=\"/Lists/ReferenceMaterialLibrary/Bullet/Art_Templates/HL-104 32 oz Sand Pail.ai\" >HL-104 32 oz Sand Pail</a>"
}
},
{
"product_id": "HL-104",
"product_name": "32-oz. Pail with Handle",
"description": "HumphreyLine 32-ounce pail is made with premium materials. Optional (non-decorated) White Lid available at US $0.25/CDN $0.50 (G) each. Optional Shovels also available at US $0.25/CDN $0.50 (G) each. Pail includes handle. Must specify handle color. Handles and Optional Shovels are available in: White, Red, Blue or Black. All optional accessories packed separately. Made in USA. FOB ZIP: KY, 41042",
"product_marketing_point_array": {
"product_marketing_point": {
"point_type": "downloads-Art Template",
"point_copy": "Click on the PDF link below to download: <br /><a href=\"/Lists/ReferenceMaterialLibrary/Bullet/Art_Templates/HL-104 32 oz Sand Pail.ai\" >HL-104 32 oz Sand Pail</a>"
}
},
{
"get_configuration_and_pricing_response": {
"configuration": {
"part_array": {
"part": {
"part_id": "HL-104BK",
"part_description": "32-oz. Pail with Handle",
"part_price_array": {
"part_price": [
{
@tsabat
tsabat / install.sh
Created February 5, 2018 17:52
install docker
#!/bin/bash -x
#
# add's docker official ppa package source for Docker engine and install it
# does not include docker-compose or docker-machine
# run as root
#
# ensure we have tools to install
apt-get -y install \
apt-transport-https \

Keybase proof

I hereby claim:

  • I am tsabat on github.
  • I am tsabat (https://keybase.io/tsabat) on keybase.
  • I have a public key ASBNwh6tG_TF5UtdZENvrFyZA3TphNY0s18ICio-cmPAAAo

To claim this, I am signing this object:

["https://s3-us-west-2.amazonaws.com/s.cdpn.io/28359/BD0000.WAV", "https://s3-us-west-2.amazonaws.com/s.cdpn.io/28359/BD0010.WAV", "https://s3-us-west-2.amazonaws.com/s.cdpn.io/28359/BD0025.WAV", "https://s3-us-west-2.amazonaws.com/s.cdpn.io/28359/BD0050.WAV", "https://s3-us-west-2.amazonaws.com/s.cdpn.io/28359/BD0075.WAV", "https://s3-us-west-2.amazonaws.com/s.cdpn.io/28359/BD1000.WAV", "https://s3-us-west-2.amazonaws.com/s.cdpn.io/28359/BD1010.WAV", "https://s3-us-west-2.amazonaws.com/s.cdpn.io/28359/BD1025.WAV", "https://s3-us-west-2.amazonaws.com/s.cdpn.io/28359/BD1050.WAV", "https://s3-us-west-2.amazonaws.com/s.cdpn.io/28359/BD1075.WAV", "https://s3-us-west-2.amazonaws.com/s.cdpn.io/28359/BD2500.WAV", "https://s3-us-west-2.amazonaws.com/s.cdpn.io/28359/BD2510.WAV", "https://s3-us-west-2.amazonaws.com/s.cdpn.io/28359/BD2525.WAV", "https://s3-us-west-2.amazonaws.com/s.cdpn.io/28359/BD2550.WAV", "https://s3-us-west-2.amazonaws.com/s.cdpn.io/28359/BD2575.WAV", "https://s3-us-west-2.amazonaws.com/s.cdpn.io/28