Skip to content

Instantly share code, notes, and snippets.

from threading import Lock, Thread
from time import sleep
import logging
logging.basicConfig(level=logging.DEBUG, format='[%(threadName)s] %(message)s')
class BackendConnection:
_lock = Lock()
2018-12-24 08:38:32 DEBUG Connect for attrs
init _BackendConnection
2018-12-24 08:38:32 aquire lock
2018-12-24 08:38:32 lock acquired
2018-12-24 08:38:32 _backend.connect
2018-12-24 08:38:40 ERROR status_update
Traceback (most recent call last):
File "/bt-mqtt-gateway/workers/mithermometer.py", line 24, in status_update
ret += self.update_device_state(name, poller)
File "/usr/local/lib/python3.7/site-packages/interruptingcow/__init__.py", line 153, in inner
execve("/usr/local/bin/lftp", ["lftp"], [/* 13 vars */]) = 0
brk(NULL) = 0x1cd2000
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
mmap(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f6e97976000
access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory)
open("/usr/lib/tls/x86_64/libgnutls.so.30", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
stat("/usr/lib/tls/x86_64", 0x7fff1221cf00) = -1 ENOENT (No such file or directory)
open("/usr/lib/tls/libgnutls.so.30", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
stat("/usr/lib/tls", 0x7fff1221cf00) = -1 ENOENT (No such file or directory)
open("/usr/lib/x86_64/libgnutls.so.30", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
[Macaron] 2017-03-25 16:52:12: Started GET /api/v1/repos/test/test/branches for 127.0.0.1
2017/03/25 16:52:12 [I] [sql] SELECT `id`, `uid`, `name`, `sha1`, `created_unix`, `updated_unix` FROM `access_token` WHERE `sha1`=? LIMIT 1 [args] [d716e7f20bbcbf59f9a4cf9e6e2564b6152a8b7d]
2017/03/25 16:52:12 [I] [sql] UPDATE `access_token` SET `uid` = ?, `name` = ?, `sha1` = ?, `created_unix` = ?, `updated_unix` = ? WHERE `id`=? [args] [1 trigger d716e7f20bbcbf59f9a4cf9e6e2564b6152a8b7d
d7a53 1490451704 1490457132 1]
2017/03/25 16:52:12 [I] [sql] SELECT `id`, `lower_name`, `name`, `full_name`, `email`, `keep_email_private`, `passwd`, `login_type`, `login_source`, `login_name`, `type`, `location`, `website`, `r
ands`, `salt`, `created_unix`, `updated_unix`, `last_login_unix`, `last_repo_visibility`, `max_repo_creation`, `is_active`, `is_admin`, `allow_git_hook`, `allow_import_local`, `allow_create_organi
zation`, `prohibit_login`, `avatar`, `avatar_email`, `use_custom_avatar`, `num_followers`, `num_following`, `num_star
@cybe
cybe / gist:603458382308f3bd27ee98b95641feb9
Created December 28, 2016 10:26
Gogs API: nil pointer dereference
[Macaron] 2016-12-28 11:03:09: Started GET /api/v1/repos/test/test/raw/master/Dockerfile for 172.22.0.1
[Macaron] PANIC: runtime error: invalid memory address or nil pointer dereference
/usr/lib/go/src/runtime/panic.go:443 (0x434ac9)
/usr/lib/go/src/runtime/panic.go:62 (0x433185)
/usr/lib/go/src/runtime/sigpanic_unix.go:24 (0x4498da)
/tmp/go/src/github.com/gogits/gogs/routers/api/v1/repo/file.go:22 (0xc966f2)
/usr/lib/go/src/runtime/asm_amd64.s:472 (0x464a4e)
/usr/lib/go/src/reflect/value.go:435 (0x51d5fd)
/usr/lib/go/src/reflect/value.go:303 (0x51c2c1)
/tmp/go/src/github.com/gogits/gogs/vendor/github.com/go-macaron/inject/inject.go:117 (0xc8b172)
@cybe
cybe / chanserv.log
Created July 7, 2012 15:50
strace output of the xrdp-chanserv process (strace -o chanserv.log -p 20640 -s 128)
select(14, [10 12 13], [], NULL, NULL) = 1 (in [12])
select(11, [10], NULL, NULL, {0, 0}) = 0 (Timeout)
select(14, [13], NULL, NULL, {0, 0}) = 0 (Timeout)
select(13, [12], NULL, NULL, {0, 0}) = 1 (in [12], left {0, 0})
getsockopt(12, SOL_SOCKET, SO_ERROR, [0], [4]) = 0
stat("/etc/localtime", {st_mode=S_IFREG|0644, st_size=2309, ...}) = 0
write(9, "[20120707-17:48:07] [DEBUG] clipboard_event_selection_owner_notify: window 29360129 subtype 0 owner 29360129 g_wnd 29360129\n", 124) = 124
stat("/etc/localtime", {st_mode=S_IFREG|0644, st_size=2309, ...}) = 0
write(9, "[20120707-17:48:07] [DEBUG] clipboard_event_selection_owner_notify: skipping, onwer == g_wnd\n", 93) = 93
recvfrom(12, "\35\372\27\0]\210\207\3\1\0\300\1\24\1\0\0\200s\307\0\0\0\0\0\0\0\0\0\10\0\0\0Y\0\27\0\1\0\300\1\17\1 \1\24\1\0\0_\210\207\3]\210\207\3\0\0\0\0\0\0\0\0", 4096, 0, NULL, NULL) = 64
@cybe
cybe / config.log
Created July 7, 2012 12:24
xdriinfo configure error
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
It was created by xdriinfo configure 1.0.4, which was
generated by GNU Autoconf 2.68. Invocation command line was
$ ./configure --prefix=/tmp/xrdp/xorg/X11R7.6/staging LDFLAGS=-Wl,-rpath=/tmp/xrdp/xorg/X11R7.6/staging/lib
## --------- ##
## Platform. ##