Skip to content

Instantly share code, notes, and snippets.

View alisianoi's full-sized avatar
🔂

Alexander Lisianoi alisianoi

🔂
View GitHub Profile
var a = function () {
var __accu0__ = [];
for (var x of list ([1, 2, 3, 4, 5])) {
__accu0__.append (x);
}
return py_iter (__accu0__);
} ();
var b = function () {
var __accu0__ = [];
for (var x of a) {
======================================================================
FAIL: test_mktime_args (tests.modules.test_time.TimeTests)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/home/alex/Code/batavia/tests/modules/test_time.py", line 223, in test_mktime_args
self.assertCodeExecution(test_str)
File "/home/alex/Code/batavia/tests/utils.py", line 445, in assertCodeExecution
self.assertEqual(js_out, py_out, context)
AssertionError: '>>> [124 chars]n10360800.0\n>>> time.mktime((1970, 1, 5, 0, 0[259 chars].0\n' != '>>> [124 chars]n10364400.0\n>>> time.mktime((1970, 1, 5, 0, 0[259 chars].0\n'
>>> import time
======================================================================
FAIL: test_basic (tests.datatypes.test_str.FormatTests)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/home/alex/Code/batavia/tests/utils.py", line 201, in wrapper
res = function(self, js_cleaner, py_cleaner, *args, **kwargs)
File "/home/alex/Code/batavia/tests/datatypes/test_str.py", line 709, in test_basic
self.assertCodeExecution(tests, js_cleaner = js_cleaner, py_cleaner = py_cleaner)
File "/home/alex/Code/batavia/tests/utils.py", line 445, in assertCodeExecution
self.assertEqual(js_out, py_out, context)

Usually, the workflow looks like this on github:

  1. You find a repo you want to contribute to, say coala/coala
  2. You fork it on github, which creates a copy zenara/coala
  3. You copy it to your machine with git clone https://github.com/zenara/coala (actually, it's better to use ssh here, but let's omit that now) At this point, git creates origin that points to your repo: zenara/coala.
  4. You create upstream with git remote add upstream https://github.com/coala/coala that points back to original repo.
  5. You create a local branch with your changes: git checkout -b zenara-awesome-feature
  6. You develop/test it for a long-long time (the coala/coala repo moves forward in the meantime)
  7. You are ready with your local feature branch. Now, you need to catch up with the coala/coala repo.
  8. You get back to the local master branch (which is "old" now): git checkout master
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@alisianoi
alisianoi / quicksort.py
Created December 3, 2016 14:09
Quicksort implementations for the blog
def quicksort(xs):
def sort(xs, l, r):
if (l == r):
return
i, j = l, r
pivot = xs[(i + j) / 2]
while (i <= j):
while (xs[i] < pivot):
npm WARN deprecated cross-spawn-async@2.2.4: cross-spawn no longer requires a build toolchain, use it instead!
npm WARN deprecated minimatch@2.0.10: Please update to minimatch 3.0.2 or higher to avoid a RegExp DoS issue
npm WARN deprecated tough-cookie@1.2.0: ReDoS vulnerability parsing Set-Cookie https://nodesecurity.io/advisories/130
npm WARN deprecated jade@0.26.3: Jade has been renamed to pug, please install the latest version of pug instead of jade
npm WARN deprecated minimatch@0.2.14: Please update to minimatch 3.0.2 or higher to avoid a RegExp DoS issue
npm WARN deprecated graceful-fs@2.0.3: graceful-fs v3.0.0 and before will fail on node releases >= v7.0. Please update to graceful-fs@^4.0.0 as soon as possible. Use 'npm ls graceful-fs' to find it in the tree.
npm WARN prefer global coffee-script@1.10.0 should be installed with -g
npm WARN prefer global jsonlint@1.6.2 should be installed with -g
{ Error: ENOTDIR: not a directory, mkdir '/home/alex/Code/project/jquery/.git/hooks'
at Error (native)
@alisianoi
alisianoi / compiling.sh
Created January 16, 2016 17:18
console output when compiling libsoy
alex@tardis ~/Code/libsoy (hg)-[default] % ./waf configure
Setting top to : /home/alex/Code/libsoy
Setting out to : /home/alex/Code/libsoy/build
Checking for 'gcc' (C compiler) : /usr/bin/gcc
Checking for program 'pkg-config' : /usr/bin/pkg-config
Checking for 'gobject-2.0' >= 2.32 : yes
Checking for 'gthread-2.0' >= 2.32 : yes
Checking for program 'valac-0.26' : not found
Checking for program 'valac-0.24' : not found
Checking for program 'valac-0.22' : not found
@alisianoi
alisianoi / kernel log
Created September 19, 2013 10:58
kernel log, bumblebeed works fine
[ 0.000000] Initializing cgroup subsys cpuset
[ 0.000000] Initializing cgroup subsys cpu
[ 0.000000] Initializing cgroup subsys cpuacct
[ 0.000000] Linux version 3.11.1-1-ARCH (tobias@T-POWA-LX) (gcc version 4.8.1 20130725 (prerelease) (GCC) ) #1 SMP PREEMPT Sat Sep 14 19:30:21 CEST 2013
[ 0.000000] Command line: BOOT_IMAGE=/boot/vmlinuz-linux root=/dev/mapper/vg_tardis-lvol0 rw quiet
[ 0.000000] e820: BIOS-provided physical RAM map:
[ 0.000000] BIOS-e820: [mem 0x0000000000000000-0x000000000009d7ff] usable
[ 0.000000] BIOS-e820: [mem 0x000000000009d800-0x000000000009ffff] reserved
[ 0.000000] BIOS-e820: [mem 0x00000000000e0000-0x00000000000fffff] reserved
[ 0.000000] BIOS-e820: [mem 0x0000000000100000-0x000000001fffffff] usable
@alisianoi
alisianoi / Xorg 8 log
Created September 19, 2013 10:55
functoning bumblebee Xorg.8.log
[ 195.121]
X.Org X Server 1.14.3
Release Date: 2013-09-12
[ 195.121] X Protocol Version 11, Revision 0
[ 195.121] Build Operating System: Linux 3.11.0-1-ARCH x86_64
[ 195.121] Current Operating System: Linux tardis 3.11.1-1-ARCH #1 SMP PREEMPT Sat Sep 14 19:30:21 CEST 2013 x86_64
[ 195.121] Kernel command line: BOOT_IMAGE=/boot/vmlinuz-linux root=/dev/mapper/vg_tardis-lvol0 rw quiet
[ 195.121] Build Date: 13 September 2013 01:28:59PM
[ 195.121]
[ 195.121] Current version of pixman: 0.30.2