Skip to content

Instantly share code, notes, and snippets.

View johnbendi's full-sized avatar

John Chijioke johnbendi

View GitHub Profile
@johnbendi
johnbendi / cljs require logs
Last active August 29, 2015 14:20
request log after cljs require call
example.main.net.repl(40000)
goog.net.xpc.CrossPageChannel {services_: Object, cfg_: Object, name: "wgVEFB0s42", domHelper_: goog.dom.DomHelper, deferredDeliveries_: Array[0]…}cfg_: ObjectconnectCb_: function (var_args){connectionDelay_: nulldeferredDeliveries_: Array[0]domHelper_: goog.dom.DomHelperiframeElement_: iframe#xpcpeer8HiTname: "wgVEFB0s42"peerLoadHandler_: goog.events.EventHandlerpeerWindowDeferred_: nullpeerWindowObject_: Windowservices_: Objectstate_: 2transport_: goog.net.xpc.NativeMessagingTransport__proto__: tempCtor
repl?xpc={"cn"%3A"wgVEFB0s42"%2C"tp"%3Anull%2C"osh"%3Anull%2C"ppu"%3A"http%3A%2F%2Flocalhost%3A3…:2092 XHR finished loading: POST "http://localhost:40000/".
repl?xpc={"cn"%3A"wgVEFB0s42"%2C"tp"%3Anull%2C"osh"%3Anull%2C"ppu"%3A"http%3A%2F%2Flocalhost%3A3…:2092 XHR finished loading: POST "http://localhost:40000/".
repl?xpc={"cn"%3A"wgVEFB0s42"%2C"tp"%3Anull%2C"osh"%3Anull%2C"ppu"%3A"http%3A%2F%2Flocalhost%3A3…:2092 XHR finished loading: POST "http://localhost:40000/".
repl?xpc={"cn
(defmacro when-let*
"simply implementation:
(if-let [[sym expr & more-bindings] (seq bindings)]
`(when-let [~sym ~expr]
(when-let* ~more-bindings ~@body))
`(do ~@body))
the form:
(when-let* [a 3 b 4] (+ a b))
@johnbendi
johnbendi / gist:826a2628758b2e9ca8aa
Created March 5, 2016 16:26
iDempiere iuimobile module error
Installing org.idempiere.iuimobile /META-INF/2Pack_3.0.0.zip ...
Mar 05, 2016 10:16:37 AM org.compiere.util.DB executeUpdate
SEVERE: INSERT INTO AD_Field (AD_Field_ID,Name,Description,AD_Tab_ID,AD_Column_ID,IsDisplayed,DisplayLength,SeqNo,IsSameLine,IsHeading,IsFieldOnly,IsEncrypted,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,IsReadOnly,IsCentrallyMaintained,EntityType,AD_Field_UU,IsDisplayedGrid,SeqNoGrid,XPosition,ColumnSpan,NumLines,IsQuickEntry,IsDefaultFocus,IsAdvancedField) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?) [PipoDS_6251da8a-3858-4606-92e4-0c3ffd217e26]
org.postgresql.util.PSQLException: ERROR: duplicate key value violates unique constraint "ad_field_column"
Detail: Key (ad_tab_id, ad_column_id)=(119, 1000070) already exists.
at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:2182)
at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1911)
at org.postgresql.core.v3.QueryExec
@johnbendi
johnbendi / angular-build-error.log
Last active April 23, 2016 23:19
Trace for angular build error when running grunt package command
Initializing
Command-line options: --verbose
Reading "Gruntfile.js" Gruntfile...OK
Registering Gruntfile tasks.
Loading "Gruntfile.js" tasks...ERROR
>> TypeError: undefined is not a function
>> at Array.filter (native)
>> at getPreviousVersions (/opt/javascript/angular.js/lib/versions/version-info.js:111:8)
@johnbendi
johnbendi / tss.log.1
Created February 22, 2017 10:35
tide tsserver log output
Open files:
~/projects/app1/src/app/user/user.service.ts
~/projects/app1/src/app/user/user.service.ts
~/projects/app1/src/app/user/user.service.ts
Info 28 event: {"seq":0,"type":"event","event":"configFileDiag","body":{"triggerFile":"~/projects/app1/src/app/user/user.service.ts","configFile":"~/projects/app1/tsconfig.json","diagnostics":[]}}
Perf 29 5::open: async elapsed time (in milliseconds) 1660.5745
Info 30 request: {"command":"configure","seq":"6","arguments":{"hostInfo":"GNU Emacs 25.1.1 (x86_64-unknown-linux-gnu, GTK+ Version 3.18.9)\n of 2017-02-04","file":"~/projects/app1/src/app/user/user.service.ts","formatOptions":{"tabSize":2,"indentSize":4,"insertSpaceAfterFunctionKeywordForAnonymousFunctions":true,"placeOpenBraceOnNewLineForFunctions":null}}}
Info 31 Host configuration update for file ~/projects/app1/src/app/user/user.service.ts
Info 32 response: {"seq":0,"type":"response","command":"configure","request_seq":"6","success":true}
Perf 33 6::configure: async elapsed time (in millisec
@johnbendi
johnbendi / recover-lost-agent.py
Created October 10, 2022 04:51 — forked from niedbalski/recover-lost-agent.py
recover a lost Juju agent
#!/usr/bin/env python
"""
This is a tool for recovering a lost juju unit
Usage:
{0} controller-ip unit-from unit-to basedir
"""
import subprocess
import shlex