Skip to content

Instantly share code, notes, and snippets.

View belonesox's full-sized avatar

Stas Fomin belonesox

View GitHub Profile
H4sIAAAAAAAAAOy9a5IbOZaouRVO/LkzZhG6jjeQ/yKVmZJupaRoSdWyHlnaNQ/SI4KdDHo0H0opy/RnNjGLGbNeQ8+OBo8DOI4T7nSGpOrqa2PdVSUG6Z/jdR44AA7+dnZdb+z/L+v19uyHv305P5svPy5Xyz/r3bJ1f/rwN/eXp/bfu81+Dn+E372q75uzH85+7AjnZ4vlw6q9r+ef7a/O/rlez9v9x2bjPsA3u+X8ZbtY3iybjSOdvb2rN83i53Vzbx8RlSUv1zerfbOeW/aFrM7P2t1ds3maXtdB7W+f1g/N7F37x3rqG2j/DeLwDR3U/vZ5s9ou178vv+ULEtP+9C/19X71LeEBaH/3sr2tF8vt3X4qnU9o/Q76xf642T7YEVHfNi9r99+bMDSaT/ZdFvumubXfhr/dtqtFs768bfxr1/v762bz+uZZ9ld+frbducee1w8Py3WztX+jXLtnN029u2rah1XjHn5ol+vd9pd286r5tHvmvnvWrJtNvXra7te7MNj8n2fwd/eH+ap2wLN/rT/WT1b1+vbJC/tbV+Tzs4+1rbFr3OqLq9RDu1rOlw2M83/bN9sdqt6mWS1dxfAf98v1Fv1lV1txmderyxfwuZnfuZK4/92+abZNvZnfNQsrYmcvl+vl+taW5Krd2Qp8tv+6XC/v69Xs+X57Xa8X4U+3m+V8v9rtN83Zbxb4cTm37fU5e+mXcyetO192L7i7z5cvfmnne1fzq027CBIc/nLuv+9L9tn1frna/Wj/a2GLtPWla213NeudK8L9w93SDoh65xvux3r9u/2fp8tNAD5vNvfLnS2N/fevTe0q5eSo2czam9nVclvbv/9S+1Lbf73YtOs/2s3v7smn7ardbpv9vXuJbXJXUvvPl/vF7Orzpr5fLmYv2639wjXS/tp20Ozt/K5tV+73m22zrt2/3i/Xi/vlyv3z9aebdrOY/XW9tJpiayvqvnYvu2sffENv5s2qXq5D+exf3tX/OntZ33nOS6sBd/Xm8+zH
**Platform:** Android
**Version:** 4.10.12 (Build 971)
**Rulesets:** [Civ V - Vanilla, Civ V - Gods & Kings]
**Last Screen:** `com.unciv.ui.screens.worldscreen.WorldScreen`
--------------------------------
Device Model: M2102J20SG
API Level: 31
System Memory: 7499 MB
@belonesox
belonesox / strace-go-build-01.log
Created February 9, 2024 04:41
strace-go-build-01
[pid 286726] newfstatat(AT_FDCWD, "/usr/lib/golang/pkg/tool/linux_amd64/buildid", {st_mode=S_IFREG|0755, st_size=2549500, ...}, 0) = 0
/usr/lib/golang/pkg/tool/linux_amd64/buildid -w $WORK/b855/_pkg_.a # internal
[pid 286837] newfstatat(AT_FDCWD, "/home/stas/.cache/go-build/e3/e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855-d", {st_mode=S_IFREG|0644, st_size=0, ...}, 0) = 0
[pid 286837] openat(AT_FDCWD, "/home/stas/.cache/go-build/e3/e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855-d", O_RDONLY|O_CLOEXEC) = 3
[pid 286837] openat(AT_FDCWD, "/home/stas/.cache/go-build/5b/5be0a9afd5d9181c8f7d133ef2c02b11bc73fc9379cce5056191c67df81b36e8-a", O_WRONLY|O_CREAT|O_CLOEXEC, 0666) = 3
[pid 286837] utimensat(AT_FDCWD, "/home/stas/.cache/go-build/5b/5be0a9afd5d9181c8f7d133ef2c02b11bc73fc9379cce5056191c67df81b36e8-a", [{tv_sec=1707315301, tv_nsec=395381622} /* 2024-02-07T17:15:01.395381622+0300 */, {tv_sec=1707315301, tv_nsec=395381699} /* 2024-02-07T17:15:01.395381699+0300 */], 0) = 0
[pid
@belonesox
belonesox / Problem with rebuilding golang-github-prometheus-alertmanager on FC38, FC39.md
Created January 28, 2024 17:46
Problem with rebuilding golang-github-prometheus-alertmanager on FC38, FC39

Problem with rebuilding golang-github-prometheus-alertmanager on FC38, FC39

Using toolbox with FC39 to demonstrate:

wget https://dl.fedoraproject.org/pub/fedora/linux/releases/39/Everything/source/tree/Packages/g/golang-github-prometheus-alertmanager-0.23.0-15.fc39.src.rpm 

toolbox create bug-prometeus-fc39 --distro fedora --release 39 -y 
toolbox -c bug-prometeus-fc39  run sudo dnf builddep -y ./golang-github-prometheus-alertmanager-0.23.0-15.fc39.src.rpm
#!/bin/sh
set +ex
rm -rf ./dir4rpms
toolbox rm -f test-fc39 -y || true
SETPACKAGES="libtool rpm-build"
#dnf-utils rpm-build
toolbox create test-fc39 --distro fedora --release 39
toolbox run -c test-fc39 sudo dnf install createrepo -y
toolbox run -c test-fc39 sudo dnf download --downloaddir ./dir4rpms --arch=x86_64 --arch=x86_64 --arch=noarch --resolve $SETPACKAGES -y
@belonesox
belonesox / reproduce.sh
Created October 7, 2023 06:14
reproduce problem with buildep and local repo
#!/bin/sh
set +ex
toolbox rm -f test-fc39 -y || true
toolbox create test-fc39 --distro fedora --release 39
toolbox run -c test-fc39 sudo dnf install createrepo -y
toolbox run -c test-fc39 sudo dnf download --downloaddir ./dir4rpms --arch=x86_64 --arch=x86_64 --arch=noarch --resolve mpv -y
toolbox run -c test-fc39 sudo dnf builddep --downloadonly --downloaddir ./dir4rpms mpv -y
toolbox run -c test-fc39 createrepo ./dir4rpms
toolbox run -c test-fc39 sudo bash -c 'sudo echo -e "[offline]\nname=offline\nbaseurl=file://$PWD/dir4rpms/\nenabled=0\ngpgcheck=0\nrepo_gpgcheck=0\n" > /etc/yum.repos.d/offline.repo'
@belonesox
belonesox / gist:2a322b67fe763121f839aea82a3e13e2
Created September 2, 2021 18:15
log for obs-streamer crash
:00:15.827792444 30074 0x7f1ccc0bb5e0 WARN audiodecoder gstaudiodecoder.c:1778:gst_audio_decoder_drain:<mpg123audiodec0> audio decoder push buffers failed
0:00:15.995079738 30074 0x7f1ccc0bb5e0 WARN audiodecoder gstaudiodecoder.c:1778:gst_audio_decoder_drain:<mpg123audiodec0> audio decoder push buffers failed
double free or corruption (out)
Aborted (core dumped)
[stas@stas-fomin-hp8770 ~]$ GST_DEBUG=3 obs
(obs:30418): Gtk-WARNING **: 21:02:29.714: Theme parsing error: colors.css:71:44: Invalid number for color value
(obs:30418): Gtk-WARNING **: 21:02:29.714: Theme parsing error: colors.css:72:44: Invalid number for color value
@belonesox
belonesox / wtf-future.py
Created June 3, 2021 21:33
debugging problem vscode wtf-future.py
import subprocess
popenargs = ([
'python',
'-c',
'''
from __future__ import print_function;
print(2222)
print(111)
@belonesox
belonesox / build_test-run.sh
Created November 24, 2020 10:26
Issue with nuitka Infinite optimization loop with cv2/skimage
#!/bin/sh
export PATH="/usr/lib64/ccache:$PATH"
python3 -m nuitka --verbose --show-progress --show-scons --standalone --follow-imports --recurse-not-to=astropy --recurse-not-to=sympy --recurse-not-to=dask --recurse-not-to=ipywidgets --recurse-not-to=ipython_genutils --recurse-not-to=ipykernel --recurse-not-to=IPython --recurse-not-to=pexpect --recurse-not-to=nbformat --recurse-not-to=numpydoc --recurse-not-to=matplotlib --recurse-not-to=pandas --recurse-not-to=pytest --recurse-not-to=nose --recurse-not-to=systemd --include-module=skimage --plugin-enable=numpy test-scipy.py >build.log 2>&1
def publish_something_new(self):
self.load_published_urls()
lastlinks = self.site.allpages(prefix='201', start='20180301', namespace=0, limit=500, filterredir='redirects')
for link in lastlinks:
OK = True
url = u"http://0x1.tv/" + link.name
if url not in self.published_urls:
video_page = link.redirects_to()
for cat_ in video_page.categories():
if cat_.name.endswith(":Draft"):