Skip to content

Instantly share code, notes, and snippets.

View betodealmeida's full-sized avatar
💭
Code code code

Beto Dealmeida betodealmeida

💭
Code code code
View GitHub Profile
We can't make this file beautiful and searchable because it's too large.
show_id,type,title,director,country,date_added,release_year,rating,duration,listed_in,description,iso_date_added,iso_release_year
s1,Movie,Dick Johnson Is Dead,Kirsten Johnson,United States,"September 25, 2021",2020,PG-13,90 min,Documentaries,"As her father nears the end of his life, filmmaker Kirsten Johnson stages his death in inventive and comical ways to help them both face the inevitable.",2021-07-25T00:00:00Z,2020-01-01T00:00:00Z
s2,TV Show,Blood & Water,,South Africa,"September 24, 2021",2021,TV-MA,2 Seasons,"International TV Shows, TV Dramas, TV Mysteries","After crossing paths at a party, a Cape Town teen sets out to prove whether a private-school swimming star is her sister who was abducted at birth.",2021-07-24T00:00:00Z,2021-01-01T00:00:00Z
s3,TV Show,Ganglands,Julien Leclercq,,"September 24, 2021",2021,TV-MA,1 Season,"Crime TV Shows, International TV Shows, TV Action & Adventure","To protect his family from a powerful drug lord, skilled thief Mehdi and his expert team of robbers are pulled into a
import random
fawmers = [
"beto",
"mahtowin",
"carleybaer",
"wylddandelyon",
"florian",
"donna",
"newukenewyork",
<script>
<![CDATA[
/*
* Firefox doesn't support `disable-output-escaping="yes"`,
* so we need to unescape the HTML content manually.
*
* See this bug ticket from 2001 (!): https://bugzilla.mozilla.org/show_bug.cgi?id=98168
*/
function isFirefox() {
return navigator.userAgent.toLowerCase().indexOf('firefox') > -1;
@betodealmeida
betodealmeida / recover_source_code.md
Created May 17, 2024 15:47 — forked from simonw/recover_source_code.md
How to recover lost Python source code if it's still resident in-memory

How to recover lost Python source code if it's still resident in-memory

I screwed up using git ("git checkout --" on the wrong file) and managed to delete the code I had just written... but it was still running in a process in a docker container. Here's how I got it back, using https://pypi.python.org/pypi/pyrasite/ and https://pypi.python.org/pypi/uncompyle6

Attach a shell to the docker container

Install GDB (needed by pyrasite)

apt-get update && apt-get install gdb
sql> SELECT assignees, labels, reactions, author_association FROM "https://api.github.com/repos/apache/superset/issues" WHERE assignees != '[]' AND labels != '[]' LIMIT 2;
assignees labels reactions author_association
---------------------------- ---------------------- ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ --------------------
["betodealmeida"] ["data:connect:drill"] [{"url": "https://api.github.com/repos/apache/superset/issues/27028/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0}] NONE
["mistercrunch", "rusackas"] ["P1"] [{"url":
import logging
from typing import Any, Dict, Generic, List
from flask_appbuilder import Model
from marshmallow import Schema, fields
from superset import security_manager
from superset.connectors.sqla.models import SqlaTable
from superset.datasets.dao import DatasetDAO
from superset.datasets.commands.exceptions import (
Loaded your LOCAL configuration at [/Users/beto/Projects/github/superset/superset_config.py]
Endpoint Methods Rule
------------------------------------------------ --------- -------------------------------------------------------------------------------------
AccessRequestsModelView.action_post POST /accessrequestsmodelview/action_post
AccessRequestsModelView.add GET, POST /accessrequestsmodelview/add
AccessRequestsModelView.delete GET, POST /accessrequestsmodelview/delete/<pk>
AccessRequestsModelView.edit GET, POST /accessrequestsmodelview/edit/<pk>
AccessRequestsModelView.list GET /accessrequestsmodelview/list/
AccessRequestsModelView.show GET /accessrequestsmodelview/show/<pk>
AlertView.list GET /alert/list/
@betodealmeida
betodealmeida / docker-superset_superset_config.py
Created June 6, 2022 20:54 — forked from PedroMartinSteenstrup/docker-superset_superset_config.py
Basic implementation of Snowflake pass-through authentication in Superset
# --------------------------------------
# Snowflake OAuth
# --------------------------------------
SNOWFLAKE_ACCOUNT = os.getenv('SNOWFLAKE_ACCOUNT') or None
if SNOWFLAKE_ACCOUNT:
SNOWFLAKE_SECURITY_INTEGRATION_CLIENT_ID = os.getenv('SNOWFLAKE_SECURITY_INTEGRATION_CLIENT_ID')
SNOWFLAKE_SECURITY_INTEGRATION_CLIENT_SECRET = os.getenv('SNOWFLAKE_SECURITY_INTEGRATION_CLIENT_SECRET')
SNOWFLAKE_OAUTH_AUTHORIZATION_ENDPOINT = f'https://{SNOWFLAKE_ACCOUNT}.snowflakecomputing.com/oauth/authorize'
// (*) All in the spirit of open-source and open-hardware
// Janost 2016 Sweden
 
// The Tiny-TS Touch Synthesizer
// https://janostman.wordpress.com/the-tiny-ts-diy-touch-synthesizer/
 
// Copyright 2016 DSP Synthesizers Sweden.
//
// Author: Jan Ostman
//
/* A MIDI pedal for the Critter & Guitari Organelle.
*
* An expression pedal sends CC numbers 21-24, depending on
* the switch pressed. A sustain pedal sends CC 25 to control
* the Aux button.
*/
#include <Bounce.h>
const int midiChannel = 15;