This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" Test script to debug atexit SIGTERM handling """ | |
import atexit | |
import os | |
import signal | |
import sys | |
import time | |
@atexit.register | |
def cleanup(): | |
print("atexit handler called") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
INPUTFILE="./sample.json" | |
SORTED_OUTPUT="./sorted-sample.json" | |
MISSING_FILE="./missing-records.txt" | |
TEMP_FILE=$(mktemp /tmp/clean.XXXXXX) | |
# Prepend the value from "id" the beginning of the line so we can use | |
# standard unix cli tools like sort. Save it to a temp file. | |
cat sample.json | jq -cr '"\(.id)\t\(.)"' > $TEMP_FILE |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"symbol":"AAPL", | |
"companyName":"Apple Inc", | |
"primaryExchange":"ENSLA R GA(MT)KATGBELSO SC/NDEAQL", | |
"calculationPrice":"iexlasttrade", | |
"open":"None", | |
"openTime":"None", | |
"openSource":"filiacfo", | |
"close":"None", | |
"closeTime":"None", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" Shareholder Yield Algo. | |
This is for learning the QuantConnect Algo Framework. I don't expect it to be useful outside of that. | |
The goal of this algo is: | |
- create a universe of liquid stocks with the best share holder yield (dividends + buybacks) relative to the market. | |
- buy an equal weighted portfolio of these stocks. | |
- rebalance monthly based on share holder yield. | |
Classes: | |
- ShareHolderYieldAlgo() is the main class that configures and instantiates the QuantConnect algo framework. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# HELP go_gc_duration_seconds A summary of the GC invocation durations. | |
# TYPE go_gc_duration_seconds summary | |
go_gc_duration_seconds{quantile="0"} 7.0906e-05 | |
go_gc_duration_seconds{quantile="0.25"} 8.5628e-05 | |
go_gc_duration_seconds{quantile="0.5"} 8.998e-05 | |
go_gc_duration_seconds{quantile="0.75"} 9.7221e-05 | |
go_gc_duration_seconds{quantile="1"} 0.000375568 | |
go_gc_duration_seconds_sum 0.104208159 | |
go_gc_duration_seconds_count 981 | |
# HELP go_goroutines Number of goroutines that currently exist. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Unit] | |
Description=Node Exporter | |
[Service] | |
# Provide a text file location for https://github.com/fahlke/raspberrypi_exporter data with the | |
# --collector.textfile.directory parameter. | |
ExecStart=/usr/local/bin/node_exporter --collector.textfile.directory /var/lib/node_exporter/textfile_collector | |
[Install] | |
WantedBy=multi-user.target |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
set -e | |
# git-pass | |
# ======== | |
# This script allows easy usage of http://www.passwordstore.org/ with | |
# multiple, Git-managed stores. It works both as self-standing shell | |
# script (that can be committed to the repository itself), or as a Git | |
# subcommand (in which case it should reside somewhere in $PATH or in |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# INCIDENT DATE - INCIDENT TYPE | |
## Meeting | |
#### Waiving meetings | |
In some cases the IC might determine that a PM meeting for the incident isn't needed. | |
If the IC decides to waive the meeting please replace the `Meeting` section with a | |
note indicating the meeting has been waived (example: `Meeting waived: Paul Mooring`) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ 0.000000] Initializing cgroup subsys cpuset | |
[ 0.000000] Initializing cgroup subsys cpu | |
[ 0.000000] Linux version 3.2.0-60-generic (buildd@toyol) (gcc version 4.6.3 (Ubuntu/Linaro 4.6.3-1ubuntu5) ) #91-Ubuntu SMP Wed Feb 19 03:54:44 UTC 2014 (Ubuntu 3.2.0-60.91-generic 3.2.55) | |
[ 0.000000] Command line: reimage=192.168.100.5:25155/factory hosttype=CONTROLLER console=ttyS0,38400n8 console=tty0 elevator=deadline image_name=controller.img.gz root=/dev/sda1 syslog=192.168.100.5 | |
[ 0.000000] KERNEL supported cpus: | |
[ 0.000000] Intel GenuineIntel | |
[ 0.000000] AMD AuthenticAMD | |
[ 0.000000] Centaur CentaurHauls | |
[ 0.000000] BIOS-provided physical RAM map: | |
[ 0.000000] BIOS-e820: 0000000000000000 - 0000000000099800 (usable) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
BUG: soft lockup - CPU#1 stuck for 30s! [wget:2220] | |
[39108.799286] Modules linked in: nls_iso8859_1 nls_cp437 vfat fat isofs ip_tables x_tables pcnet32 8139cp ne2k_pci 8390 e1000 acpiphp | |
[39108.799286] CPU 1 | |
[39108.799286] Modules linked in: nls_iso8859_1 nls_cp437 vfat fat isofs ip_tables x_tables pcnet32 8139cp ne2k_pci 8390 e1000 acpiphp | |
[39108.799286] | |
[39108.799286] Pid: 2220, comm: wget Not tainted 3.2.0-37-virtual #58-Ubuntu OpenStack Foundation OpenStack Nova | |
[39108.799286] RIP: 0010:[<ffffffff816562d9>] [<ffffffff816562d9>] _raw_spin_unlock_irqrestore+0x19/0x30 | |
[39108.799286] RSP: 0018:ffff88000a803cf0 EFLAGS: 00000286 | |
[39108.799286] RAX: 0000000000000286 RBX: 0000000000000001 RCX: 0000000000000000 | |
[39108.799286] RDX: 0000000000000004 RSI: 0000000000000286 RDI: 0000000000000286 |
NewerOlder