Skip to content

Instantly share code, notes, and snippets.

View bfouts-osaro's full-sized avatar

Brian Fouts bfouts-osaro

View GitHub Profile
"""
This system contains a "producer" that populates a queue and a "consumer" that asynchronously
reads from a queue and inserts integer records into a database. The average of these records
is reported on a regular interval"""
import logging
import os
import pickle
import sqlite3
import sys
import time
import jsonlines
import re
from odin_to_gqfcn import Robotv2ToGQFCNv2
from dateutil import parser
class DebugParser:
def __init__(self):
self.start_marker = 'Acquired FSM lock in state S4(PNP - Picking)'
self.end_marker = 'Released FSM lock [<function FSM.place_result'
from google.protobuf.any_pb2 import Any
from google.protobuf.timestamp_pb2 import Timestamp
import datetime
import grpc
import os
import psycopg2
import psycopg2.extras
import pytest
import time
import uuid
@bfouts-osaro
bfouts-osaro / client test example
Last active April 4, 2020 02:50
ModelBlueprint.get_all tests
import requests
import pytest
import pprint
from geri.client.types import ModelBlueprint
from geri.client import transport
@pytest.fixture(autouse=True)
def disable_server_calls(monkeypatch):
#this will ensure that we never actually try to hit the server
import pytest
from odin.hardware.devices.plc import gpapi_plc
class MockRamdisk:
RESULT = None
def __init__(self, *args, **kwargs):
pass
def write(self, value):

Keybase proof

I hereby claim:

  • I am bfouts-osaro on github.
  • I am bfouts_osaro (https://keybase.io/bfouts_osaro) on keybase.
  • I have a public key ASBKi8rzIZ-EV3gmO2zGfdzhKtFnz-kM8ncSredCD3c-9Qo

To claim this, I am signing this object: