u/green_bisonstd

Czy uważacie uzależnienie od mediów społecznościowych za jeden z największych problemów naszych czasów?

Miliony ludzi codziennie marnuje godziny na bezsensownym przeglądaniu tiktoka czy instagrama. Tylko dla szybkich strzałów dopaminy. Czują się przybici, bo ich życie nie przypomina wyidealizowanego obrazu przedstawianego przez różnych infuencerów. Jeszcze gorzej jest z małymi dziećmi, które nie mają jeszcze dobrze rozwiniętych filtrów poznawczych i zupełnie nie rozumieją, że to czysta fikcja.

Moim zdaniem najgorsze jest nieuchwytność tego uzależnienia. O ile palacz czy alkoholik może się oszukiwać, że po prostu to lubi. To i tak ludzie w jego otoczeniu widzą że ma z tym problem. Z mediami społecznościowymi jest o wiele trudniej, bo każdy ma i używa codziennie telefonu. Granica między sprawdzeniem co u Twoich znajomych, a pełnym uzależnieniem jest bardzo cienka i często trudna do wyłapania. Dopiero dłuższy detoks pokazuje jak duże szkody to wyrządzało.

reddit.com
u/green_bisonstd — 1 day ago
▲ 43 r/poland

Polish intelligence nabs middle-aged Pole and teenage Belarusian in foreign spy plot

"A 19-year-old Belarusian and a 44-year-old Polish man have been detained by Poland's Internal Security Service on suspicion of working for a foreign state in exchange for money.

The suspects, identified as Aliaksei B. and Rafał G., are accused of spying for Belarus and recruiting people via Telegram between 2024 and 2025 to carry out “sabotage activities” in Poland in exchange for payment in cryptocurrency."

tvpworld.com
u/green_bisonstd — 4 days ago
▲ 19 r/ruby+1 crossposts

Alexscript a Polish-syntax language written in Ruby. With fully implemented OOP, fiber based async and its own web framework.

Alexscript is a general purpose scripting language I've been working on for the last 1.5 years. With a goal in mind to combine Ruby's strongly object-oriented philosophy with some features borrowed from JS and syntax written in my native language.

modul Geometria {
    klasa Punkt {
        funkcja konstruktor(x, y) {
            niech @x = x
            niech @y = y
        }

        funkcja x() { zwroc @x  }
        funkcja y() { zwroc @y }
    }

    klasa Kolo {
        funkcja konstruktor(srodek, promien) {
            niech @srodek = srodek
            niech @promien = promien
        }
    }
}

niech p = Geometria::Punkt.nowy(3, 4)
niech k = Geometria::Kolo.nowy(p, 10)

It's a from-scratch language, with a hand written lexer, parser, AST and tree-walking interpreter. Not just a preprocessor or transpiler. Ruby works here as a host language.

Some key features:

  • Async runtime is fiber based with a cooperative scheduler: czekaj (await) parks the current fiber and hands control back to a custom reactor (ready-queue + timers + an IO.select loop). Concurrency comes from explicitly spawning work with uruchom_rownolegle (run_parallel) and joining with Obietnica.wszystkie (Promise.all).
  • Modules work both as namespaces, to avoid name pollution in larger projects and as mixins. A set of methods that can be injected into classes. They are also open, multiple modul Foo {} blocks across files merge into one definition. I've purposefully decided to keep classes closed though.
  • Classes have built-in reflection methods. E.g. to check a class's ancestors/descendants, if a given method exists, list of methods, etc. More broadly, every data type carries a rich set of built-in methods.
  • Exceptions are just special purpose classes that inherit from the base exception class. You can write your custom exception by simply defining a new class that inherits from already defined exception class: klasa MojWyjatek < WyjatekPodstawowy {}
  • Standard library is implemented natively in Ruby (Time, Math, JSON, Socket etc), but native methods aren't kept in a separate registry, they're injected into the same [:methods] / [:static_methods] hashes that user defined methods live in, flagged with :native_lambda
  • In addition to regular functions there are also anonymous ones/lambdas. They can be assigned to variables or passed into higher order functions as arguments:

​

niech arr = [10, 20, 30] 
niech wynik = arr.mapuj(fn(el, idx) { el + idx }) 
pokazl wynik        # [10, 21, 32]

funkcja zastosuj(f, val) { zwroc f(val) } 
pokazl zastosuj(fn (x) { x * 3 }, 7)  # 21 
pokazl zastosuj(fn (s) { s.duzymi() }, "alex") # ALEX
  • built-in debugger which is intended to work similarly to byebug

you can check full documentation (in English) here: www.alexscript.pl/docs

you can also try it online on your own: https://www.alexscript.pl/try

or simply download it on your local machine via homebrew:

brew tap N3BCKN/alexscript
brew install alexscript

As a proof of concept I've built a couple of real life projects:

  • Zubr - a micro web framework. With routing, static files serving, middleware chain, body request parsing, sessions and streaming of larger files. With 50 open connections it can handle up to 1,590 req/s, and streams large files at ~1.97 GB
  • ASBasic - an interpreter of classic BASIC language written from scratch in Alexscript.
  • Posel - HTTP client inspired by Axios and HTTParty

Any feedback is more than welcome!

github.com
u/green_bisonstd — 3 days ago