Skip to content

Instantly share code, notes, and snippets.

040cc5ed31fee1cc1d1a4219e9b43f0fce85a7f2f2cf78932f1b10aa80677c75ba9b914f16f983e2f97460da44202949ca061cdababc9234ebb251166fa25740ca;icvitkovac
@delicb
delicb / keybase.md
Created July 30, 2018 23:46
keybase.md

Keybase proof

I hereby claim:

  • I am delicb on github.
  • I am delboy (https://keybase.io/delboy) on keybase.
  • I have a public key ASDyAu5BmzJ9UxZeeAwp4rqXjy4o_E2l2OLAlNSMpTD8Hwo

To claim this, I am signing this object:

@delicb
delicb / README.md
Last active March 29, 2021 23:43
Getting OSO to work with Go on Apple M1 chip

Preparing OSO for ARM64

This is meant as a workaround for people using Apple M1 based computers and want to use OSO.

OSO provides Go package, but it depends on a core library, which is written in Rust in with which OSO communicates via C bindings.

First thing, clone OSO repository:

git clone https://github.com/osohq/oso.git
@delicb
delicb / error
Created October 6, 2021 18:21
flask error handling - mypy error
xxx/__init__.py: note: In function "register_error_handlers":
xxx/__init__.py:115: error: Argument 1 has incompatible type
"Callable[[Exception], Union[Union[Response, Any, Dict[str, Any], Generator[Any, None, None]], Tuple[Union[Response, Any, Dict[str, Any], Generator[Any, None, None]], Union[Headers, Dict[str, Union[str, List[str], Tuple[str, ...]]], List[Tuple[str, Union[str, List[str], Tuple[str, ...]]]]]], Tuple[Union[Response, Any, Dict[str, Any], Generator[Any, None, None]], int], Tuple[Union[Response, Any, Dict[str, Any], Generator[Any, None, None]], int, Union[Headers, Dict[str, Union[str, List[str], Tuple[str, ...]]], List[Tuple[str, Union[str, List[str], Tuple[str, ...]]]]]], Callable[[Dict[str, Any], StartResponse], Iterable[bytes]]]]";
expected "ErrorHandlerCallable[Exception]" [arg-type]
@app.errorhandler(Exception)
^
Found 1 error in 1 file (checked 8 source files)