Skip to content

Instantly share code, notes, and snippets.

View bukzor's full-sized avatar
🌥️
learning google cloud

Buck Evan bukzor

🌥️
learning google cloud
  • google.com
  • Appleton, WI
  • 10:57 (UTC -05:00)
View GitHub Profile
@bukzor
bukzor / crash.log
Created March 31, 2019 21:03
terraform crash while updating google_compute_url_map
$ tf plan -out tfplan && tf apply tfplan ; alert "Terraformed! (0)"
GoSM: Setting up security policy for terraform binary.GoSM: Setting up security policy for terraform binary.
Warning: module.global.module.restricted-area--unrestricted.module.continent--asia.module.gke.data.google_container_engine_versions._: "region": [DEPRECATED] Use location instead
Warning: module.global.module.restricted-area--unrestricted.module.continent--asia.module.gke.module.nodepool--batch--f1-micro.google_container_node_pool._: "region": [DEPRECATED] use location instead
@bukzor
bukzor / colortest16777216
Created August 22, 2018 20:58
A simple way to tell if your terminal supports truecolor.
$ cat ~/bin/colortest16777216
#!/usr/bin/env python3
# pylint: disable=g-import-not-at-top,missing-docstring,g-wrong-blank-lines
from collections import namedtuple
class Color(namedtuple('Color', 'r g b')):
"""values are 0 to 1"""
@classmethod
$ brew config
HOMEBREW_VERSION: 1.6.3-dirty
ORIGIN: git@github.com:Linuxbrew/brew.git
HEAD: b67917c837f1fb9c5bf2494cfd89b4eee6802802
Last commit: 6 hours ago
Core tap ORIGIN: https://github.com/Linuxbrew/homebrew-core
Core tap HEAD: 968e12cee4398a031dc80eef3f2cde5bb656ad81
Core tap last commit: 3 hours ago
HOMEBREW_PREFIX: /home/buck/prefix/brew
HOMEBREW_REPOSITORY: /home/buck/prefix/brew
@bukzor
bukzor / hypothesis-bukzor-logging.patch
Last active April 20, 2018 21:15
hypothesis impossible error
diff --git a/hypothesis/core.py b/hypothesis/core.py
--- a/hypothesis/core.py
+++ b/hypothesis/core.py
@@ -222,8 +222,6 @@ def execute_explicit_examples(
)
try:
with BuildContext(None) as b:
- if settings.verbosity >= Verbosity.verbose:
- report('Trying example: ' + example_string)
test_runner(
@bukzor
bukzor / make.log
Created March 22, 2018 18:01
homebrew libbsd compile fail on Android
libtool: compile: clang -DHAVE_CONFIG_H -I.. -isystem ../include/bsd/ -include ../config.h -DLIBBSD_OVERLAY -DLIBBSD_DISABLE_DEPRECATED -D__REENTRANT -g -O2 -Wall -Wextra -Wno-unused-variable -Wno-unused-parameter -c fpurge.c -o fpurge.o >/dev/null 2>&1
/bin/sh ../libtool --tag=CC --mode=compile clang -DHAVE_CONFIG_H -I.. -isystem ../include/bsd/ -include ../config.h -DLIBBSD_OVERLAY -DLIBBSD_DISABLE_DEPRECATED -D__REENTRANT -g -O2 -Wall -Wextra -Wno-unused-variable -Wno-unused-parameter -c -o funopen.lo funopen.c
libtool: compile: clang -DHAVE_CONFIG_H -I.. -isystem ../include/bsd/ -include ../config.h -DLIBBSD_OVERLAY -DLIBBSD_DISABLE_DEPRECATED -D__REENTRANT -g -O2 -Wall -Wextra -Wno-unused-variable -Wno-unused-parameter -c funopen.c -fPIC -DPIC -o .libs/funopen.o
funopen.c:141:2: error: "Function funopen() needs to be ported."
#error "Function funopen() needs to be ported."
^
1 error generated.
make[1]: *** [Makefile:632: funopen.lo] Error 1
make[1]: Leaving directory '/usr/tmp/libbsd-20180322-
@bukzor
bukzor / build.log
Created February 11, 2018 22:40
Build Elm from source, with GHC 8.2
$ runhaskell installers/BuildFromSource.hs 0.18
Using GHC 8.2
Using Cabal 2.0.0.1
fatal: destination path 'elm-compiler' already exists and is not an empty directory.
fatal: destination path 'elm-package' already exists and is not an empty directory.
fatal: destination path 'elm-make' already exists and is not an empty directory.
fatal: destination path 'elm-reactor' already exists and is not an empty directory.
fatal: destination path 'elm-repl' already exists and is not an empty directory.
Downloading the latest package list from hackage.haskell.org
@bukzor
bukzor / README.md
Last active December 19, 2017 22:05
Profiling for hypothesis#914

These SVG's represent profiling runs of the example shown in hypothesis#914 with hypothesis' new use_coverage feature turned off and on, respectively. The "nocov" case ran in 0.058s while "yescov" ran in 0.262 seconds, a more than 5x slowdown. In my own work, I have a non-trivial test that slows down from 13s to >50s, a ~4x slowdown, and it follows the same profile seen below, but with many more calls to lstat().

You can see (you'll want to right-click and "open image in new tab") that the largest contributor to the difference between the scenarios is the lstat() call. This is called by coverage.Collector.save_data() where it normalizes the paths of all files involved in the coverage trace. save_data() is called by hypothesis between each example in order to pull the coverage data out of the collector object.

@bukzor
bukzor / -
Created April 18, 2017 01:19 — forked from anonymous/-
# -*- coding: utf-8 -*-
from __future__ import absolute_import
from __future__ import unicode_literals
from datetime import datetime
from datetime import timedelta
import pytz
import tzlocal
@bukzor
bukzor / gist:aebcfcd0a46c20c85d4f62de5994d5d5
Created April 9, 2017 23:32
hypothesis-py: make check-format
(master) buck@tortle-2016:~/trees/learn/hypothesis-python
[Sun 04-09 04:30:39PM]$ make check-format
find src tests -name '*.py' -not \( -path '*/vendor/*' -or -name test_lambda_formatting.py \) | /home/buck/.cache/hypothesis-build-runtimes/virtualenvs/tools/bin/python scripts/enforce_header.py
# isort will sort packages differently depending on whether they're installed
/home/buck/.cache/hypothesis-build-runtimes/virtualenvs/isort/bin/python -m pip install django pytz pytest fake-factory numpy flaky
Requirement already satisfied: django in /home/buck/.cache/hypothesis-build-runtimes/virtualenvs/isort/lib/python3.4/site-packages
Requirement already satisfied: pytz in /home/buck/.cache/hypothesis-build-runtimes/virtualenvs/isort/lib/python3.4/site-packages
Requirement already satisfied: pytest in /home/buck/.cache/hypothesis-build-runtimes/virtualenvs/isort/lib/python3.4/site-packages
Requirement already satisfied: fake-factory in /home/buck/.cache/hypothesis-build-runtimes/virtualenvs/isort/lib/python3.4/site
buck@tortle-2016:~/trees/learn/gun
[Sun 04-09 03:47:59PM]$ yarn run e2e
yarn run v0.22.0
$ mocha e2e/distributed.js
(node:1306) DeprecationWarning: child_process: options.customFds option is deprecated. Use options.stdio instead.
Hello wonderful person! :) Thanks for using GUN, feel free to ask for help on https://gitter.im/amark/gun and ask StackOverflow questions tagged with 'gun'!
WARNING! This `file.js` module for gun is intended for local development testing only!
/home/buck/trees/learn/gun/node_modules/ws/lib/WebSocketServer.js:63
throw new TypeError('missing or invalid options');
^