Skip to content

Instantly share code, notes, and snippets.

View coryvirok's full-sized avatar

Cory Virok coryvirok

  • Rollbar
  • San Francisco
View GitHub Profile
1c1
< _Effective: May 20, 2020_
---
> _Effective: August 11, 2020_
53c53
< * *Others Working with Rollbar.* We may share information about you within the United States and abroad, with third party vendors who need to know information about you in order to provide their services to us, or to provide their services to you. This group includes vendors that help us provide our Services to you, such as payment providers that process your credit and debit card information, fraud prevention services that allow us to analyze fraudulent payment transactions, postal and email delivery services that help us stay in touch with you, customer chat and email support services that help us communicate with you, those that assist us with our marketing efforts (e.g. by providing tools for identifying a specific marketing target group or improving our marketing campaigns), those that help us understand and enhance our Services (like analytics providers), and those that help us deliver our Services (like hosting and content deliv
@coryvirok
coryvirok / TOS.diff
Created June 29, 2020 18:26
diff of Rollbar ToS for 7/1/20
1c1
< _Effective: Dec 27, 2019_
---
> *Effective: July 1, 2020*
3c3
< Welcome to Rollbar.com, the website and online service of Rollbar, Inc. (“Rollbar,” “we,” or “us”). This page explains the terms by which you may use our online and/or mobile services, web sites, APIs, SDKs, email notifications, and Software (as defined in 1(c) below) provided on or in connection with the service (collectively, the “Services”). Your access to and use of the Services are conditioned on your acceptance of and compliance with this Terms of of Service Agreement (the “Agreement”). By accessing or using the Services you signify that you have read, understood, and agree to be bound by this Agreement and to the collection and use of your information as set forth in the Rollbar [Privacy Policy](doc:privacy-policy), whether or not you are a registered user of our Services. Rollbar reserves the right to make unilateral modifications to this Agreement and will provide notice of these changes as described below. This Agreement applies t
@coryvirok
coryvirok / Liberal Regex Pattern for Web URLs
Created September 23, 2015 01:00 — forked from gruber/Liberal Regex Pattern for Web URLs
Liberal, Accurate Regex Pattern for Matching Web URLs
The regex patterns in this gist are intended only to match web URLs -- http,
https, and naked domains like "example.com". For a pattern that attempts to
match all URLs, regardless of protocol, see: https://gist.github.com/gruber/249502
# Single-line version:
(?i)\b((?:https?:(?:/{1,3}|[a-z0-9%])|[a-z0-9.\-]+[.](?:com|net|org|edu|gov|mil|aero|asia|biz|cat|coop|info|int|jobs|mobi|museum|name|post|pro|tel|travel|xxx|ac|ad|ae|af|ag|ai|al|am|an|ao|aq|ar|as|at|au|aw|ax|az|ba|bb|bd|be|bf|bg|bh|bi|bj|bm|bn|bo|br|bs|bt|bv|bw|by|bz|ca|cc|cd|cf|cg|ch|ci|ck|cl|cm|cn|co|cr|cs|cu|cv|cx|cy|cz|dd|de|dj|dk|dm|do|dz|ec|ee|eg|eh|er|es|et|eu|fi|fj|fk|fm|fo|fr|ga|gb|gd|ge|gf|gg|gh|gi|gl|gm|gn|gp|gq|gr|gs|gt|gu|gw|gy|hk|hm|hn|hr|ht|hu|id|ie|il|im|in|io|iq|ir|is|it|je|jm|jo|jp|ke|kg|kh|ki|km|kn|kp|kr|kw|ky|kz|la|lb|lc|li|lk|lr|ls|lt|lu|lv|ly|ma|mc|md|me|mg|mh|mk|ml|mm|mn|mo|mp|mq|mr|ms|mt|mu|mv|mw|mx|my|mz|na|nc|ne|nf|ng|ni|nl|no|np|nr|nu|nz|om|pa|pe|pf|pg|ph|pk|pl|pm|pn|pr|ps|pt|pw|py|qa|re|ro|rs|ru|rw|sa|sb|sc|sd|se|sg|sh|si|s
"""
Instead of causing a 404 for cat IDs that are not found, return the parent resource.
"""
class Root(object):
def __getitem__(self, key):
if key == 'cats':
res = CatList()
res.__name__ = key
res.__parent__ = self
@coryvirok
coryvirok / gist:9478263
Last active September 6, 2016 12:07
Rollbar javascript notifier. Ignore uncaught errors that are *not* from www.mycompany.com.
function ignoreRemoteUncaught(isUncaught, args, payload) {
try {
var filename = payload.data.body.trace.frames[0].filename;
if (isUncaught && !filename.match(/^https?:\/\/www\.mycompany\.com/)) {
// Ignore uncaught errors that are not from www.mycompany.com.
return true;
}
} catch (e) {
// Most likely there was no filename or the frame doesn't exist.
}
function f(addr) {
$.getJSON(addr, function(d) {
if (d.follow) {
f(d.follow);
} else {
console.log(d);
}
})
}
f('http://letsrevolutionizetesting.com/challenge')
import json
import requests
import time
ACCESS_TOKEN = 'token'
payload = {
'access_token': ACCESS_TOKEN,
'timestamp': int(time.time()),
'environment': 'development',
'revision': '12345678',
var eventstream = require('event-stream');
var fs = require('fs');
// creates a new write stream on first write() call
exports.createLazyWriteStream = function(wsFactory) {
var Stream = require('stream');
var s = new Stream;
var ws;
s.writable = true;
@coryvirok
coryvirok / hrmmm.js
Created October 16, 2012 02:53
nodejs plaintext -> zlib compressed data -> base64 and back... why doesn't it work?
var zlib = require('zlib');
var plaintext = 'Hello World';
var compressedData = [];
var compressor = zlib.createGzip();
compressor.write(plaintext);
compressor.end();
compressor.on('data', function(d) { compressedData.push(d);});