Skip to content

Instantly share code, notes, and snippets.

View jasonleibowitz's full-sized avatar

Jason Leibowitz jasonleibowitz

View GitHub Profile
@jasonleibowitz
jasonleibowitz / javascript_resources.md
Last active August 29, 2015 14:18 — forked from jookyboi/javascript_resources.md
Here are a set of libraries, plugins and guides which may be useful to your Javascript coding.

Libraries

  • jQuery - The de-facto library for the modern age. It makes things like HTML document traversal and manipulation, event handling, animation, and Ajax much simpler with an easy-to-use API that works across a multitude of browsers.
  • Backbone - Backbone.js gives structure to web applications by providing models with key-value binding and custom events, collections with a rich API of enumerable functions, views with declarative event handling, and connects it all to your existing API over a RESTful JSON interface.
  • AngularJS - Conventions based MVC framework for HTML5 apps.
  • Underscore - Underscore is a utility-belt library for JavaScript that provides a lot of the functional programming support that you would expect in Prototype.js (or Ruby), but without extending any of the built-in JavaScript objects.
  • lawnchair - Key/value store adapter for indexdb, localStorage
@jasonleibowitz
jasonleibowitz / rails_resources.md
Last active August 29, 2015 14:18 — forked from jookyboi/rails_resources.md
Rails-related Gems and guides to accelerate your web project.

Gems

  • Bundler - Bundler maintains a consistent environment for ruby applications. It tracks an application's code and the rubygems it needs to run, so that an application will always have the exact gems (and versions) that it needs to run.
  • rabl - General ruby templating with json, bson, xml, plist and msgpack support
  • Thin - Very fast and lightweight Ruby web server
  • Unicorn - Unicorn is an HTTP server for Rack applications designed to only serve fast clients on low-latency, high-bandwidth connections and take advantage of features in Unix/Unix-like kernels.
  • SimpleCov - SimpleCov is a code coverage analysis tool for Ruby 1.9.
  • Zeus - Zeus preloads your Rails app so that your normal development tasks such as console, server, generate, and specs/tests take less than one second.
  • [factory_girl](h
@jasonleibowitz
jasonleibowitz / css_resources.md
Last active August 29, 2015 14:18 — forked from jookyboi/css_resources.md
CSS libraries and guides to bring some order to the chaos.

Libraries

  • 960 Grid System - An effort to streamline web development workflow by providing commonly used dimensions, based on a width of 960 pixels. There are two variants: 12 and 16 columns, which can be used separately or in tandem.
  • Compass - Open source CSS Authoring Framework.
  • Bootstrap - Sleek, intuitive, and powerful mobile first front-end framework for faster and easier web development.
  • Font Awesome - The iconic font designed for Bootstrap.
  • Zurb Foundation - Framework for writing responsive web sites.
  • SASS - CSS extension language which allows variables, mixins and rules nesting.
  • Skeleton - Boilerplate for responsive, mobile-friendly development.

Guides

Keybase proof

I hereby claim:

  • I am jasonleibowitz on github.
  • I am jasonleibowitz (https://keybase.io/jasonleibowitz) on keybase.
  • I have a public key ASC3DMPetqvFckA1VWdqMIJ_Ag5GyN3NMj10k9wK6q7tmAo

To claim this, I am signing this object:

@jasonleibowitz
jasonleibowitz / keymap.c
Created March 16, 2018 17:36
Custom Planck Keymap
/* Copyright 2015-2017 Jack Humbert
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
@jasonleibowitz
jasonleibowitz / manual_run_k1_task.py
Created March 9, 2023 17:14
manual_run_k1_task.py
import time
from fund_admin.tax.schedule_k1.scheduled_tasks import create_schedule_k1s_for_fund_partners
tic = time.perf_counter()
print('----------Starting K-1 Job----------')
create_schedule_k1s_for_fund_partners()
toc = time.perf_counter()
print(f'Job completed in {toc - tic:0.4f} second')
print('----------Completed K-1 Job----------')
@jasonleibowitz
jasonleibowitz / get_schedule_k1_recent_job_stats.py
Last active March 10, 2023 22:00
get_schedule_k1_recent_job_stats.py
from fund_admin.audited_celery.models import CeleryTask
tasks = CeleryTask.objects.filter(name__contains='create_schedule_k1s_for_fund_partners').order_by('-created_at')[:10]
for task in tasks:
created_at_str = task.created_at.strftime('%m/%d at %H:%M')
job_status = task.state
print(f'Started: {created_at_str}')
print(f'Status: {job_status}')
if job_status == 'SUCCESS':
@jasonleibowitz
jasonleibowitz / backfill_expressperiodicreportrows.py
Created March 16, 2023 15:04
Personal namespace deploys do not generate `express_expressperiodicreportrow` objects. This is a script to auto-generate them. However, in personal namespace deploys (eks-test or sandbox) we do not have sufficient resources to run the script like we do in prod. Therefore, this version of the script chunks the objects we need to iterate over.
from more_itertools import more
from fund_admin.express.overview.services import ExpressDashboardService
from fund_admin.express.overview.queries import firms_for_dashboard, funds_for_dashboard
from fund_admin.express.periodic_reporting.models import ReportingPeriod
from fund_admin.express.periodic_reporting.services import ExpressPeriodicReportService
BATCH_SIZE = 15
# Add the missing Express Entity rows
import io
import csv
import time
from dataclasses import dataclass
from fund_admin.identity.cache import get_user
from fund_admin.reporting.models.templates import FinancialPackageTemplateSettings
from fund_admin.reporting.models.package import FinancialPackageReport
from fund_admin.documents.services import DocumentService
"""
Soft deleting FundLimitedPartnerDocuments created between Nov 2, 2023 7:00 AM ET and 12:00 PM ET
https://carta1.atlassian.net/browse/ISD-7964
"""
from datetime import datetime
from eshares.investor_services.models import FundLimitedPartnerDocument