#unix

1 messages ยท Page 16 of 1

ivory wyvern
#

Putting in on the VM? Or you mean dual booting

royal aspen
ivory wyvern
#

Worst can happen if things goes bad while dual booting is you partitioning things wrong and you end up erasing your current system , and mess up the new system installation

or if installing your new operation system as your only main operating system , you can mess it up , and not succeed installing it , and you end up erasing your old system, and no system at all on your machine!

royal aspen
#

I was scared because I have to make a kirnal and ppl say that can mess up pcs

rotund girder
#

git cli question.

I usually use vim and compare with old versions of a file inside my editor. But sometimes I would like to just cat an old state of a file. I can do for example:

$ echo HEAD~1400:.envrc | git cat-file --batch

But this command is quite long, isn't there a shorter version?

#

Aha! git cat-file -p HEAD~1400:.envrc

spark mulch
rotund girder
#

oh ๐Ÿ˜… thanks!

#

I see myself as git expert but never noticed git show ๐Ÿ˜›

#

It's such a big software ๐Ÿ˜ฎ

heavy relic
#

i'm currently transferring files from a remote server using scp -r, but it's a bit slow. does anyone know of a faster way to transfer files between a local machine and a remote server, other than scp? Looking for something that can handle large directories more efficiently

spark mulch
main olive
heavy relic
#

i had to resort to asking chatgpt

spark mulch
#

o.O Isn't it just rsync source target?

heavy relic
#

i keep getting all kinds of errors

#

i tried installing rsync

spark mulch
#

What OS are you on?

heavy relic
#

windows 10

spark mulch
#

WSL or not?

heavy relic
#

im using scp -r right now, and its taking AGES

#

yes wsl

spark mulch
#

With WSL installing rsync should just work by doing sudo apt install rsync

heavy relic
#

wait no

#

i was using MSYS2

spark mulch
#

Oh, mingw64, that's not WSL

#

No idea then. Not really #unix either.

wise forge
#

Single file is transmitted faster

eager badger
rain cave
#

running the latest Python release on BSD

rain cave
#

The Python ecosystem on BSD is highly deprecated. The current default version of Python running on FreeBSD is Python 3.11

spark mulch
rain cave
rain cave
#

Is MacOS a derivative of the Unix tree blobhuh

nimble panther
#

Hey, you should re-ask your question in an off-topic channel as your post is outside the scope of this channel.

robust bridge
#

whereโ€™s off-topic btw ?

nimble panther
nimble panther
shy yokeBOT
rain cave
slim salmon
#

Registered UNIX system. Even recently.

radiant kraken
#

I just reinstalled Raspberry Pi OS (Debian 12 Bookworm) and I'm trying to compile Python 3.11.11 via pyenv to (1) have my own user installation and (2) use my locally built version of SQLite3MultipleCiphers present in /usr/local/lib (specifically libsqlite3mc.so.0.0.0, with a symlink for libsqlite3.so). I installed the build dependencies, libsqlite3-dev included: sh sudo apt-get install build-essential gdb lcov pkg-config \ libbz2-dev libffi-dev libgdbm-dev libgdbm-compat-dev liblzma-dev \ libncurses5-dev libreadline6-dev libsqlite3-dev libssl-dev \ lzma lzma-dev tk-dev uuid-dev zlib1g-dev libmpdec-dev
But despite this, pyenv couldn't build with SQLite support: sh $ pyenv install 3.11 Downloading Python-3.11.11.tar.xz... -> https://www.python.org/ftp/python/3.11.11/Python-3.11.11.tar.xz Installing Python-3.11.11... Traceback (most recent call last): File "<string>", line 1, in <module> File "/home/thegamecracks/.pyenv/versions/3.11.11/lib/python3.11/sqlite3/__init__.py", line 57, in <module> from sqlite3.dbapi2 import * File "/home/thegamecracks/.pyenv/versions/3.11.11/lib/python3.11/sqlite3/dbapi2.py", line 27, in <module> from _sqlite3 import * ModuleNotFoundError: No module named '_sqlite3' WARNING: The Python sqlite3 extension was not compiled. Missing the SQLite3 lib? Installed Python-3.11.11 to /home/thegamecracks/.pyenv/versions/3.11.11 I previously set this up on Bullseye, and I thought these were the only steps I needed... Any suggestions on solving this?

radiant kraken
#

Huh, after removing the symlink and building/installing the original SQLite 3.49.1 from source, it compiled correctly: sh $ sudo make install /usr/bin/install libsqlite3.so "/usr/local/lib" Setting up libsqlite3.so version symlinks... lrwxrwxrwx 1 root root 20 Mar 30 20:40 libsqlite3.so -> libsqlite3.so.3.49.1 lrwxrwxrwx 1 root root 20 Mar 30 20:40 libsqlite3.so.0 -> libsqlite3.so.3.49.1 -rwxr-xr-x 1 root root 4879992 Mar 30 20:40 libsqlite3.so.3.49.1 [...] $ pyenv install -f 3.11 Downloading Python-3.11.11.tar.xz... -> https://www.python.org/ftp/python/3.11.11/Python-3.11.11.tar.xz Installing Python-3.11.11... Installed Python-3.11.11 to /home/thegamecracks/.pyenv/versions/3.11.11 Following that, prepending /usr/local/lib to /etc/ld.so.conf and sudo ldconfig got my Python to start using 3.49.1, and then I removed the above SQLite library and added back my symlink to SQLite3MultipleCiphers.

#

Not sure why it didn't initially work with sqlite3mc symlinked, but oh well ๐Ÿ™ƒ

placid junco
#

Does anyone have any experience with packaging python with nix or writing nix derivations for python programs

rain cave
rotund girder
#

Anyone here using module (i.e. module load) system to distribute python environment?

Thinking about if there is any known good way to do it, or do's and don'ts.

severe rain
#

You mean like module as in the HPC tool?

#

module avail python should show you the options to choose from, and then you'd just module load python/x.y.z cuda/x.y example/x.y and module save somename.. been a while since I touched any of that so I'm not sure what the latest python available will be

#

I guess a best practice might be to use a 'group' that includes the tools you want, rather than al a carte?

#

Which I think you can see with module avail -t?

#

I never had to set up my own module collection from scratch, hopefully there's a nice repo to bootstrap from these days?

regal coral
#

Idk if this is python specific or if this even is the right channel, but is it normal for code like this to completely freeze my system to where i have to force restart it with the power button?

from functools import reduce

def prime_f_rec(n):
    def rec_format(factor):
        res = 2
        for _ in range(factor-2):
            res += 1
        return res
    factors = prime_factors(n)
    return reduce(lambda x,y:x*y, [rec_format(factor) for factor in factors])

def prime_factors(n):
    factors = []
    while n % 2 == 0:
        factors.append(2)
        n = n // 2
    for i in range(3, int(n**0.5) + 1, 2):
        while n % i == 0:
            factors.append(i)
            n = n//i
    if n > 2:
        factors.append(n)
    return factors

for i in range(5000):
    assert eval(prime_f_rec(i)) == i

This happens way too often because sometimes when i have to wait on something i'll just open python repl and play with it, and basically crash my computer. The screen still displays but it is fully frozen, and i cannot do anything, not even switch tty.
I use archlinux

severe rain
#

Whatโ€™s up with the eval()?

#

eval is for executing a string of Python code etc

wise forge
wise forge
# regal coral Idk if this is python specific or if this even is the right channel, but is it n...
from functools import reduce

def prime_f_rec(n):
    def rec_format(factor):
        res = 2
        for _ in range(factor-2):
            res += 1
        return res
    factors = prime_factors(n)

    # N^2 actions at least
    return reduce(lambda x,y:x*y, [rec_format(factor) for factor in factors])

def prime_factors(n):
    factors = []
    # Log2(N) complexity?
    while n % 2 == 0:
        factors.append(2)
        n = n // 2
    # Log2(N) * N of smth? potential infinity of actions can be may be
    for i in range(3, int(n**0.5) + 1, 2):
        while n % i == 0:
            factors.append(i)
            n = n//i
    if n > 2:
        factors.append(n)
    return factors

for i in range(5000):
    # loop one for 5000
    assert eval(prime_f_rec(i)) == i
#

on my very rought eye, u have potentially here N * Log2(N) * NSmth? actions complexity at least here
With potential N^3 may be?
So... a good thing will be actually just measuring time and seeing if it is performance issue or u created somewhere infinity thing it stucked

#

remove eval thingy and just measure time for each prime_f_rec(i) calculated

#

it is supposed to start with small amount of time and gradually increasing calculations in time if is not sticking

#
import time

for i in range(5000):
    start = time.time()
    assert eval(prime_f_rec(i)) == i
    print(time.time() - start)
#

if smth is growing in number gets written, with each next loop taking more time than previous... then u just created high in complexity algorithm (and python slowness in calculating such stuff 20-40 times more slower than other languages, plus lack of parallelism do not help a lot)

#

if number is not growing at all right from a start, then your logic is somewhere faulty and it just stucked in some infinity loop

wise forge
#

if your RAM jumps to maximum (and i guess all cores can be jumping to max too, but RAM is more interesting)

#

then u created a fault in algorithm that overflows RAM or created fork bomb (with eval) by accident potentially also

severe rain
#

Why are we not questioning the eval() again? Shouldn't that just be throwing an exception when you try to eval an integer?

wise forge
#

shrugs. I never used eval practically. Unsafe/impractical thing that is like using GOTO for me
But in theory u can fork bomb stuff with it, so that's why i recommend just in case monitoring RAM usage
TLDR: Monitor PC resources usage for more information, measure time (and remove preferably eval for more sanity)

whole trellis
#

Hey ๐Ÿ‘‹, I am currently looking to boost my CV, I'm looking for a new job as I'm not getting a permanent role at the company I've been interning at for a year and a half now. My skills are Unix , enterprise Linux, python, docker, Jenkins and kubernetes. Is there more I should learn, does anyone have project ideas? Thanks in advance.

regal coral
whole trellis
main olive
#

I can not figure out which file in /etc/ is responsible for bash trying to execute something from a file path that leads nowhere and I want it to stop doing this every time I start terminal. I thought I was looking for a .bash_profile but I don't see one in /etc/. Am I looking in the wrong place?

wise forge
#

try to input smth like ls ~/.bash and press Tab many times, u will see in your user profile existing files starting with that name, may be will show .bash_profile too

rustic sky
#

check ~/.bashrc, ~/.bash_profile, /etc/profile, /etc/profile.d/, /etc/bash.bashrc

wise forge
#

~ is your $HOME

rustic sky
#

those are the ones that come to mind

severe rain
#

/etc/bash.bashrc is a thing commonly

#

man bash should list them also

fickle granite
#

or just grep for the file name in everything in /etc

main olive
#

I'm on Mac OS Catalina terminal

#

Why would it be in /etc/ for some people?

wise forge
# main olive I'm on Mac OS Catalina terminal

Uh. Not a Linux. We were probably all mistaken u ask for Linux
No idea how stuff works at macOS

I am aware it is Unix based, but it is not using Linux kernel and should be different. Dunno how much it is different

main olive
#

Oh well it worked anyway. Thx!

wise forge
main olive
#

I see

severe rain
#

zsh is the default on MacOS and there's a hard-to-find default file at /System/Library/Templates/Data/private/etc/zshrc

#

Though I think it's just used to create /etc/zshrc? I'd have to dig into it.

spark mulch
rain cave
#

Is todays Unix super trademark proprietary. Is it still owned by AT&T

spark mulch
#

(Also, that is only enforced for the uppercase variant, you can call anything "unix", AFAIU)

rain cave
spark mulch
rain cave
#

That is unfortunate

lost parrot
#

bro ๐Ÿ˜‚

#

let everyone know

slate crypt
#

which state?

candid summit
#

I don't know if it is a bug or not. I am now on Linux. So, I was trying to dual boot Windows and Debian. I don't want to be the bedion on the 1st option because my parents used the PC, so I was paying/trying in the Windows GUI search for other OS (I don't know what they call it). When I escape the Win Gurb, the Debian Gurb pops up, and I boot it to Debian. LOL

#

I just want to tell someone the experience/ story.

wise forge
#

Linux by default in OS picking in the grub

#

but if i exit it, then Windows Grub analog can appear

candid summit
#

๐Ÿ˜ฎ

wise forge
#

..i install my OSes to different SSDs

#

and i make sure to Remove Power Cord Cable from Linux drive during Windows installation

#

makes sure Windows does not touch my precious Linux

#

Linux becomes grub aware about Windows, and windows remains working without awarence of linux

#

since LInux is customizable, easy to adjust grub to whatever desired needs

candid summit
#

Ya think so to, win Gurb is old looking.

wise forge
candid summit
#

Is OSes a OS, OR multiple os?

wise forge
candid summit
#

Oo, cool ๐Ÿ‘

shy yokeBOT
#

:incoming_envelope: :ok_hand: applied timeout to @placid musk until <t:1744310063:f> (10 minutes) (reason: duplicates spam - sent 4 duplicate messages).

The <@&831776746206265384> have been alerted for review.

rain cave
#

Is anyone in systems engineering. Sysadmin Linux - BSD stuff

#

Windows too. WSL2 is pretty nice

brave fractal
#

#unix i am building a python script that looks like this this is stock python

shy yokeBOT
# brave fractal

Please react with โœ… to upload your file(s) to our paste bin, which is more accessible for some users.

severe rain
#

You can click that green + white checkmark to get it to put it on the paste site for you.

shy yokeBOT
#

Please react with โœ… to upload your file(s) to our paste bin, which is more accessible for some users.

brave fractal
shy yokeBOT
severe rain
#

Cool. What's the question?

brave fractal
#

this is on python 3.12 i am on windows 10. There's also a way to mount iso image on window and use the tool to go through the directory using the the python script. my question is how can i lock python down for user that are not admin? i am looking through reddit right now. i don't want users to have access to python.

severe rain
#

You can use Group Policy (gpedit.msc) to prevent users from running specific binaries

#

There should be a thing under Computer Configuration > Administrative Templates > System called "Don't run specified Windows applications"

#

There's also a thing these days built in called AppLocker you can do it from, but I'm not very experienced with it.

#

This is totally not a UNIX question though

brave fractal
#

this helps a lot

main olive
#

No more linux!

#

Linux is bad!

rustic sky
main olive
rain cave
#

Phew good thing I have BSD distros to fall back on. Linux โŒ BSD โœ…

main olive
#

Hey guys what's a serious good linux distro I can count on for many years for my future work ( I have a high-end good specs laptop) but I still want to know a good linux distro for work and one that will be nice to depend on . im currently using ubuntu and I have been seeing some people talk about linux mint too and other distros

severe rain
#

These days, there are a lot of interesting ways to go if you want.

main olive
#

yoo that's nice

#

I never knew about that

#

this is like rufus but for linux

fickle granite
#

I'd stick with ubuntu -- not because it's "the best" (whatever that might mean), but because it's clearly pretty good, and afaict it's the most popular. Popularity counts.

main olive
#

yup true

#

Is ubuntu like the windows of linux?

trail sapphire
main olive
#

ya it sounded weird ig but it felt like it kinda made sense too ๐Ÿ˜‚

trail sapphire
main olive
#

yup agreed some people are used to 1 distro none other than it

wise forge
# main olive Hey guys what's a serious good linux distro I can count on for many years for my...

Kubuntu faithfully serves me for years.
Reasons:

  • Ubuntu is first supported everywhere, easy to find guides
  • Easy to install everything, apt install smth, snap install smth, apt install ./some_deb, wget smth
  • Docker images are often debian based as easy solution, Ubuntu is debian based => so i am familiar with the most commonly used linux distro by default, differences between Debian and Ubuntu are very hard to notice
    • Also same Ubuntu/Debian pick is common way to go for servers too
  • Kbuntu is Ubuntu flavour with KDE Plasma GUI, it is just very familiar/comfortable one for me, former Windows user. Task bar is correctly at the bottom, desktop with links, Supet good default terminal with multiplexing/multi windowing feature (the most important part for me). GUI just works okay on defaults for me
#

In general if u are not a person that wishes to have a lot of brainfuc.k with Linux... picking smth Ubuntu based is good idea
Whatever GUI u will like to it (be it vanilla Ubuntu, or Xubuntu, or Lubuntu, whatever. my choice is Kubuntu LTS)

#

LTS - long term supported version, important to pick for maximum stability

#

P.S. when i visited at some point office of my company, everyone was having installed Ubuntu by default ๐Ÿ˜

wise forge
# main olive Is ubuntu like the windows of linux?

we can say that about KDE Plasma flavoured distros yes in terms of interface, except underneath can be not only Ubuntu but smth else
I pick ubuntu though. the same GUI is pairable with any other linux distro
So u pick usually your "Distro underneath" (their amount is fairly much low of common known and long term supported), your "Gui", and from there possible also some extra more specialized choices

#

====
Extra note. I am DevOps engineer and i am having Very Much enough brainfuc.k with configurating different tools (or coding some applications when i go for some Backend stuff)

#

Not going to build my own linux distro

#

I enjoy Kubuntu because it does just work out of the box and i don't need to configure anything extra in it (beyond running few apt/snap install commands and hooking my bash scripts for quick actions)
I enjoy Linux(Ubuntu) because it works the best for web development/server infrastructure tooling, everything is supported natively

trail sapphire
#

some people prefer rolling distros, but i would say that is either for more adventurous linux users or seasoned linux users
and for stability some people want some kind of immutable distros where you can easily reboot and be back to previous versions of all your os managed software

#

and some like declarative distros where you can reinstall everything on a new system and be back mostly as you where as long as you have a backup of your own files

main olive
trail sapphire
main olive
#

I also want smth stable so it won't cause problems with any type of work im trying to do

main olive
#

my first experiences with linux was with kali

#

tbh took me some time to get used because I was still a newbie with commands and programming in general

#

but I got used to it

#

which is why I don't have any problems attempting to solve bugs or use the terminal or mess around in the OS

#

and which is also why im ineterested and open to check out many more options

trail sapphire
severe rain
wise forge
#

While i am still young enough biogically in general, wishing to conquer all important languages at a deep level to be comfortable with them

#

very rewarding sort of, as each ecosystem/language unlocks to more possibilities what can be done (and more job stuff too hehe)

#

probably Java/Kotlin is the last important thing to conquer ๐Ÿค”

#

dotnet looks gradually more attractive though with being linux friendly and having some neat stuff in it. Seriously considering to add it to my plate, but i will be fine with just conquering JVM world may be too

severe rain
#

The dotnet intermediate representation language is pretty cool/interesting.

rain cave
#

Ubuntu is my favorite Linux distro

main olive
#

ok guys what do u think about manjaro?

severe rain
#

I'm pretty skeptical of distros that are "we're based on Distro X, but we're more user-friendly!"

#

It's really hard to do that well, especially without falling behind the update schedule of what you're based on.

#

And why didn't they just contribute back to "Distro X" etc etc?

#

That being said Manjaro supports Xfce so they do get some points. Xfce is great.

main olive
#

well tbh I wanna get more into computers and I'm down for the experience of low level so what do u think?

severe rain
#

If you're really down for the low-level I personally had a great time with https://www.linuxfromscratch.org/ but it's probably not what you want to run day-to-day, it's more about learning from the ground up.

main olive
#

mhm I see

severe rain
#

That being said there are a lot of fun distros to try, and these days whole distro 'approaches' to try

#

Like with this, you have an 'immutable' base install of Linux, and everything you care about is a package on top of that that you can change out as you desire: https://blue-build.org/

trail sapphire
severe rain
#

So it's still on my radar despite being a derivative

trail sapphire
rain cave
#

Each Linux distro has custom frameworks. Even if they were based on an original. ๐Ÿ‘€ I know because I comb thru the stacks (directories)

severe rain
trail sapphire
rain cave
#

I found this out because my student club is building a proprietary Debian based distro. Jk itโ€™s just custom built

severe rain
#

Yeah, it has a high bar to clear. I'm likely to do what I usually do and go right back to FreeBSD :V

rain cave
#

Should my club market our Debian build

#

Millions and billions and trillions of dollars yes greed batmanthink

#

I am kidding by the way

rustic sky
#

22.04 LTS, which is quite old by now
๐Ÿ‘€

trail sapphire
# rustic sky

that is really bad without ESM, but even with ESM probably not the best idea or practices

rustic sky
#

hahahahah

#

ESM and fairly airgapped do not fear

#

this is not a device i am running personally

trail sapphire
#

for an old 3d printer or something?

rustic sky
#

or well, not one i am using as a desktop, it's a server at work that more or less has to exist and stay around, it's migration is on the task list for some time later this year

rustic sky
trail sapphire
rustic sky
#

hahaha yeah

#

it just sits there and runs the interfaces to push signals through to a selection of PLC-type gubbins and hvac type stuff

quiet seal
#

@severe rain I've always been interested in Linux From Scratch and have wanted to build one for the longest. How was the build process for you? How long did it take and what was the Host distro you used when building it? What did you end up doing with the build? Did you customize it much? Still have the build and use it?

severe rain
# quiet seal <@163779435462393856> I've always been interested in Linux From Scratch and have...

Great questions. Here's what I remember, as it's been a long long time:

  1. I remember the docs being surprisingly clear, I expected to have to do more side research than I did
  2. It was also surprisingly fast, but I had a lot of SunOS (Solaris) experience at the time so that helped. I'd give it a weekend.
  3. I used the build as a little in-house webserver for a while before replacing it with Arch.
  4. Amazingly I used Slackware as the host distro, which I can't recommend, but was still semi-poipular at the time.
  5. I customized a lot of the choices, yeah, e.g. the syslog system; it's fun being exposed to all the choices you could make there
  6. Sadly I installed (Arch?) over it so I don't have it, that would be amusing, since it used init instead of systemd
jade raven
#

I'm trying to setup "hotplug" capabilities for a serial USB device to IO with a podman container. If I simply pass --device /dev/ttyUSB0:/dev/ttyUSB0:rw, I can communicate with the device. However when I remove the USB from my host and plug it back in, my container can no longer communicat.
Therefor, I am trying to setup a TCP proxy for this device such that in my Container I can listen for connections and in my host I can proxy through the connection. So now, my problem is described below:

#

I have a question for those familiar with socat and serial devices.
I have an embedded device I interface with over a serial connection, via character special (186/0) files.
I wanted to set up a virtual serial port "pipe" to this device with socat. However, I've noticed when I do that my physical device exhibits strange behavior (as if it might be pulled into reset? It should be blinking an LED but it is not when I set up this socat connection). Furthermore, I can't actually get my dev tools to communicate with it over this socat virtual piping.
Here's my host command:
socat -dd /dev/ttyUSB0,rawer,mode=777,user=(id -u),group=(id -g) TCP:localhost:12345
My container command:
socat -dd tcp-listn:12345 PTY,link=/dev/ttyVUSB0,mode=777,rawer,openpty
Then in the container I try to I/O with this /dev/ttyVUSB0
When I try to connect serially, I can see in the debug output that the connection is trying to write something. I believe the writing is happening from my tools side - trying to establish IO comms with the embedded serial device
There may be some TERMIOS options I need to set properly. So I followed up and found the man termios. I've tried everything at this point, I cannot get the device inside my container to behave like the underlying character device. I've used stty -F /dev/ttyUSB0 to try and match the termios flags inside the container, and that did not work (the flags did match)
I can simply obtain "hot plug" behavior by mounting the entirety of /dev inside the container. This is not my preference

main olive
#

Hm... Arch Hyprland btw or smh

deep scaffold
#

Hello there

dark ocean
#

typically for grabbing something from a text file, is it better to use unix commands with the os module or default python io

#

or does it not matter

prime magnet
fickle granite
#

I usually go for "default python io"

brave fractal
#

i use arch and the script i posted is in testing stages. I did not see that posting here was unix only. lol sorry about that. ๐Ÿ™‚

main olive
#

Linux has many ups an down but big down for Linux user is that it got wanna be Linux user and ragging comments on any social site / app without even thinking.

Does python community has these kind of people too?

wise forge
#

U mean that Linxu users promote it aggresively as it is the best thing

#

Or that other OS users think Linux is bad?

main olive
wise forge
# main olive

Ah. Yeah... typical behavour on Stack Overflow. Stack overflow is infamously famous for its bad attitude in general
And Linux users are known for being fanatically happy about their OS choice (i am Linux user too, hehe)
Join those things together and u will get answer like that

In general Linux users are just fanatically happy about it though. Agressive behaviour like that is more StackOverflow fault, as it brings the worst out of humanity for some reason.

wise forge
# main olive Linux has many ups an down but big down for Linux user is that it got wanna be L...

i did not see Superiority attitude in python community i think. I often told to people currently in university to be better investing in serious languages like Java/Golang
And recounted all the disadvantages python has. (Like bad CPU performance (20 time slower than other languages), lack of real multithreading due to GIL lock, lack of typing making difficult code maintanance and refactors and readability)
Rarely i got any conflicts back. Quite python community cozy and relaxed
I always told some advantages of python too though, that it is quite easy to unit test language due to everything mockable at runtime and nothing being private, and easy to start with

wise forge
# main olive Glad to hear that!

btw, as fanatical another Linux user i keep opinion that...
..Linux is best OS if u develop for Web development (Backend Development specifically) and as default OS for devs, and especially in DevOps engineering. Because last 10 years development of web happens only for deployment to Linux servers. It is just easier to develop from Linux for Linux ๐Ÿ˜

I think that for University students better to run Windows with WSL2 having linux though. More stuff they will be able to run and university expects often to run some Windows stuff anyway.
Plus Windows has advantage of more games to run. For regular user makes sense to still use Windows just because it has more games easier to run -_- but Linux SteamOS stuff catchs up nicely and gaming on linux sky rockets to be more available

I don't understand only people using MacOS. worse for development than Linux, worse for gaming than Windows. and 2-3 times more expensive. I think MacOs people are brainwashed by Apple marketing to buy smth that is worse than other OS in any capacity.
The only thing where MacOS is better than others... it is to develop for MacOs. and that's because it is ridiculously proprietary system that makes things difficult on purpose

main olive
severe rain
#

I vaguely resent Linux for its willingness to support things that lock you into it vs. UNIX standards, but I guess in general I manage to keep that under wraps.

manic brook
# main olive Linux has many ups an down but big down for Linux user is that it got wanna be L...

dude/lady... such people exist everywhere. It's not about Linux users or developers using a certain language. It's usually the people with the preachy attitude.

Someone would learn a new thing and they think that thing is the best thing since the slice bread and everyone should use it. Think, if you have a hammer everything looks like a nail.

I think in some ways it's the Dunning-Kruger effect too. But mostly it's about personalities rather than 'X' users.

distant fox
#

i open #unix channel of the Python discord and the discussion is about Unix users.. never change, developers ๐Ÿ˜‚

hot comet
# wise forge btw, as fanatical another Linux user i keep opinion that... ..Linux is best OS i...

I wouldn't say MacOS is worse than it's alternatives, but rather it just depends on your needs. For someone like me who doesn't really play video games anymore, there's very little benefit to owning a Windows machine (not to mention all the bloatware and spyware). Linux seems great, but it just doesn't have all the software I need. I own both a PC and MacBook, and I just generally prefer MacOS, especially because of how it plays nicely with my other Apple devices.

#

At the end of the day though... use whatever you want no one cares lol

main olive
#

where do i get amazing apis not the generic stuff like dog image api i mean useful apis?

severe rain
wise forge
main olive
#

i need unique apis to impress employers like something for knowing the best fruits to plant for a specific type of soil and know where to plant it

distant fox
#

i bet you can find geodata on soil and weather conditions and aggregate it for user's GPS location

sharp sentinel
#

i have a .deb file coded in py i need a .app file for a macbook

trail sapphire
sharp sentinel
trail sapphire
# sharp sentinel ok i dont have a mac ๐Ÿ˜ฆ i was going to do this so that my app could be on mac. t...

there are several ways to make an executable, one of the most common ones is by using PyInstaller on the platform that you want to make an executable for
cross compilation is somewhat possible but not realistically for mac or iOS/iPadOS and such due to Apples policies/EULA/ToS where they require you to compile things for their platforms from on one of their platforms, so it's all down to Apples restrictions on their products

#

in other words, they require you to get a mac or in some way get access to a mac to be able to create the application binaries for mac or any of their other platforms

sharp sentinel
nimble notch
#

@wise forge help me to get on with Linux (like give me some tips)... I'm a newbie btw ๐Ÿฅฒ

prime cave
#

@gilded surge share the image here

rain cave
#

If Linux is not Unix then why did they name Linux after Unix

spark forge
#

random for that unix linux thing you said

#

because i couldn't answer

rain cave
desert sky
summer trail
tidal plaza
#

What does mean something?

#

(something)

#

double underscore something double underscore

hexed cave
fluid lake
#

Hello I am having trouble running anaconda-navigator from my rofi drun menu.

#

I ran rofi -show -drun from my zsh and my anaconda-navigator works fine

#

but when i super + d and select anaconda-navigator nothing happens

#

this is my desktop entry for anaconda-navigator on /home/aadithya/.local/share/applications/anaconda-navigator.desktop

[Desktop Entry]
Name=Anaconda Navigator
Comment=Launch Anaconda Navigator
Exec=zsh -l -c "source ~/anaconda3/etc/profile.d/conda.sh && /home/aadithya/anaconda3/bin/anaconda-navigator"
Icon=anaconda
Terminal=false
Type=Application
Categories=Development;
#

I was trying to learn ML in python so i thought this server might be ok to ask i am sorry if this is not the right server

severe rain
modern sail
#

What do you call a process that just doesn't exist? Like for example, you lookup a process and it is a zombie, and zombies are dead for various intents and purposes, but what if you want to lookup a process to verify that it is completely dead like not a zombie, just doesn't exist due to being killed + reaped and all that jazz.

fickle granite
#

๐Ÿค”

#

I think I'd call it "a process that no longer exists"

#

what problem are you trying to solve?

modern sail
# fickle granite I think I'd call it "a process that no longer exists"

I'm working on code to start a process, use a wrapper, set the parent death signal, and testing that when the parent dies abruptly, the child will die. I started writing functions like verify_process_is_alive(pid) -> bool and verify_process_is_dead(pid) -> bool (for more general use than this problem too) but then I wasn't sure of the design or what should be considered dead or alive because a Zombie process isn't entirely a dead one, and I was going to check if it's alive by if the process existed in /proc/. Process that no longer exists is what I'm thinking of at the moment and just differentiating for functions between if it can be looked up, vs if it is a zombie or something.

fickle granite
#

I assume you have exactly three possibilities:

  • it doesn't exist at all
  • it exists, but is a zombie
  • it exists, and is not a zombie
#

I'd have thought there'd be one or two simple libc functions that, given a PID, would tell you which state it was in ... but I don't see any such thing. I guess it's specific to the Linux kernel, and I don't know its API, nor how to interact with that API from Python

modern sail
# fickle granite I'd have thought there'd be one or two simple libc functions that, given a PID, ...

Unfortunately the libc functions are lacking for some of this stuff but everything is available through the filesystem at least which I have covered, i.e.: It's just that I'm designing this and trying to account for multiple platforms for testing to see if a process has died, but "dead" doesn't totally mean dead in the way I'd thought it would when a Zombie process still technically exists in the kernel, and on top of that can still be looked up because it'll exist at /proc/{pid} still just with the stat file having a Z in the column. But yea, I think it's just 1) non-existent (not alive, not a zombie), or on windows just can't be looked up at all I think and not as interesting (speculating here) 2) it's alive (it exists and is not a zombie) and 3) it exists and is dead (like zombies are). So I think you're right and I'll just focus on weather or not it exists or not for what I care about and differentiate between existent or zombie where relevant.

# FIXME work out a design for this/differentiating between it being dead or alive
def verify_process_is_zombie(process_id: int) -> bool:
    """
    Verifies that a process with the given id exists and is a zombie. If it can't be
    determined if the process is a Zombie on the platform, then False will be returned.
    """
    if sys.platform != "linux":
        raise RuntimeError(b"platform {sys.platform} not supported")
    try:
        with open(f"/proc/{process_id}/stat", "r") as f:
            line = f.readline().rstrip("\r\n")
            # if the value of the third column is Z then it is a zombie
            indicator_on_third_column = line.split()[2]
            return indicator_on_third_column == "Z"
    except FileNotFoundError:
        return False```
fickle granite
#

That's pretty much how I'd do it

#

pretty sure you won't find carriage-returns in files under /proc ๐Ÿ™‚

modern sail
modern sail
# fickle granite That's pretty much how I'd do it

It does have to work on multiple platforms but not all of it. It only has to if it has zombie processes in a meaningful capacity. Like if I look up a process on Linux it could be a zombie and not entirely dead (non existent) like I'd want it to be after. But on windows even though there is stuff that can go wrong that leaves stuff in a zombie like state in the kernel (if I read correctly) once it can't be looked up that's about as much as seems like should be cared about. At this point I am just gonna verify explicitly that it doesn't exist, or if testing for a specific platform and debugging further checking if it is a zombie or something.

summer trail
# modern sail I'm working on code to start a process, use a wrapper, set the parent death sign...

I'm working on code to start a process, use a wrapper, set the parent death signal, and testing that when the parent dies abruptly, the child will die.
It sounds like you wouldn't need to recognize zombie processes at all for this. You start a child process, then a grandchild process, then register that the grandchild process should die when the child process dies, then kill the child process, wait a bit, and make sure that the grandchild process is now dead as well, by checking that you can reap it

#

that is, you call os.waitpid with the grandchild's pid and the WNOHANG option, and you should be notified that the grandchild has died

#

once the child process has died, the responsibility for reaping the grandchild process bubbles up to its grand parent process, unless you've started a new session group at some point (in which case it falls to pid 1)

modern sail
# summer trail > I'm working on code to start a process, use a wrapper, set the parent death si...

I'm doing all of this at the moment minus the last partYou start a child process, then a grandchild process, then register that the grandchild process should die when the child process dies, then kill the child process, wait a bit, and make sure that the grandchild process is now dead as well but my issue was checking if it is dead and I wanted to do it in more of a blackbox fashion kind of where I'd look it up on the system and verify that it is truly dead, as in doesn't exist anymore through that. Aside from the definition of dead vs non-existent initially I've got it working and am doing in my test essentially as follows. 1 -> starting the child from the grand parent. 2 -> the child is starting the grand child and then sleeping forever. 3 -> the grand parent is giving it a sleep of one second so that everything has time to start up and so that the parent death signal will be sent ||(I'll consider improving the design to allow the wrapper script to give a proper indicator that can be found on the filesystem or something later)|| 4 -> sending SIGKILL to the parent process. 5 -> waiting for it to be dead 5.1 -> Actively waiting for it because sending the signal doesn't result in it dying right away, so giving a bit with a timeout. And right now I'm not reaping anything and it results in the process not existing at all and not just being a zombie.

    def test_should_have_end_result_of_child_script_dying_when_parent_dies_abruptly(self):
        # A script should be able to use GracefulProcess to start a process
        # and when that script is dead and unable to tell it to shut down,
        # it should be killed automatically and be graceful. The implementation
        # of this functionality for Linux can be to make the child set the parent death signal.
        #
        # And the above can be achieved through a wrapper script which does it before execl. This test
        # is not focused on implementation detail, but context is somewhat necessary to get the premise.
        start_command = _get_python_script_start_command("child_parent_graceful/parent.py", [])
        raw_subprocess = subprocess.Popen(start_command, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
        time.sleep(1) # -> removing this sleep I think results in the parent death signal not being set
        # ^ We're subprocess directly because inside it's where we have a graceful process that does the whole shebang.
        parent_process_pid = int(raw_subprocess.stdout.readline().decode().split(":")[1])
        child_process_pid = int(raw_subprocess.stdout.readline().decode().split(":")[1])
        os.kill(parent_process_pid, signal.SIGKILL)
        # raw_subprocess.wait()
        # raw_subprocess.kill()
        # self.waitForProcessToNotExist(parent_process_pid, 10, f"process {parent_process_pid} did not die in time")
        self.waitForProcessToNotExist(child_process_pid, 10, f"process {child_process_pid} did not die in time.")```
summer trail
#

If you can reap it, it's definitely dead. If you can't reap it, either it is still alive, or someone else has already reaped it. If you did not start a new session group, no one else could have possibly reaped it.

#

Unless the grandchild died before the child, I guess (in which case the child could have reaped the grandchild)

modern sail
#

If I set the parent death signal on the the grand child and the child (it's parent) dies abruptly, then it doesn't become a Zombie or anything like that and wasn't what I was concerned about. I'm just building up a decent amount of stuff along side of this and trying to get the definition of dead, alive, non-existent correct and for using it here. e.g.

parent.py

import os
import sys
import time
sys.path.append("../../../../")
from pathlib import Path
from <redacted>.processes.normal import GracefulProcess


print(f"parent-pid:{os.getpid()}", flush=True)
process = GracefulProcess([sys.executable, Path(__file__).parent / "child.py"])
# I think in our test cases by the time we kill it, it hasn't set the parent death signal in the child script
# assert process.get_line_output_reader() == "parent_death_signal_set"
process.start()
print(f"child-pid:{process.pid}")
while True:
    time.sleep(0.1)```
child.py
```py
import time

# print(f"child-pid:{os.getpid()}", flush=True)
while True:
    time.sleep(0.1)```
summer trail
#

If I set the parent death signal on the the grand child and the child (it's parent) dies abruptly, then it doesn't become a Zombie or anything like that and wasn't what I was concerned about.

Huh? It absolutely should. A zombie is just a process that has died and that has not been reaped. The parent process is responsible for reaping it, but if that parent is dead, the grandparent is (and so on, up the chain), until you reach a living process or a process in a different session group (in which case it falls back to init, pid 1)

#

If your grandparent and grandchild are in the same session group (you haven't called setsid), then the grandparent should be the one that needs to reap the grandchild, and the grandchild should be a zombie until the grandparent does

summer trail
#

Ooh, no, apparently I'm wrong: the orphaned process isn't reparented to the grandparent, it's always reparented to init, unless the grandparent has called prctl with PR_SET_CHILD_SUBREAPER

#

That makes it even easier, though, tbh - as long as you have a functioning init process the child will never be a zombie for more than a few microseconds

modern sail
# summer trail Ooh, no, apparently I'm wrong: the orphaned process isn't reparented to the gran...

||(I've retracted my entire previous statement to not spam the channel and to make my response more concise)||. Yea, I was able to reproduce this in an isolated experiment where I did it all raw basically and spent hours (on various days) debugging this and wondering why my test would pass when I changed stuff slightly but not other times. In regards to a functioning init process (not so educated on it) but in my tests it has never reported as being a zombie, just existing and alive, or non-existing and completely dead so I think the time is definitely too small to matter and I'm prepared to actively wait for it with a timeout at this point as that's what I'm expecting the end result to be. So my problems were race conditions. I'm attach the files for context for reproducing all of it.

https://paste.pythondiscord.com/R5FDSHHWKZOUK3Y5OYJ2VW65RA

elder knot
#

Hi! I have a very curious problem: I would like to manually activate a venv (without using source .venv/bin/activate, I need that for my vimspector debugpy config). My test venv has a module that I do not have installed globally. Looking at the activate script, I cannot see it doing anything other then (i) setting VIRTUAL_ENV, (ii) setting PATH, (iii) unsetting PYTHONHOME, and (iv) defining a deactivate function. However, if I set those 3 environment variables manually and run my python script, it complains that the module from the venv was not found. But if I activate the venv via source .venv/bin/activate and then run my python script, it works. So there is some magic happening that I cannot find ๐Ÿ˜ฆ I have even diffed the output of env | sort in the activated environment and in my manually recreated environment, and except for the OLD... variables, there is no difference. Does anyone know what I am missing?

wise forge
#

u don't need to activate venv then

elder knot
#

Unfortunately, that doesn't work either, it still complains that the module cannot be found

wise forge
elder knot
#

(should be caused by prepending the venv path to $PATH anyways, but I also tried directly running python with the entire global path and I got the same effect)

elder knot
#

Wait, sorry, I must have broken the venv somewhere along the way, now I cannot repro getting it to work in the venv.

wise forge
#

changes to Abs path break it

elder knot
#

Sorry, it seems I need to debug myself a bit more - this is a venv I created using nix develop, and depending on how I activate it, it works or doesn't work. Seems more like some dark nixOS magic that I need to figure out than a venv problem.

severe rain
desert sky
#

Thats a lot of long messages ๐Ÿ˜ญ๐Ÿ˜ญ๐Ÿซก๐Ÿซก

worn summit
#

(Unreleated to python) Anybody here knows dwm's desktop environment?? Especially on Debian's -- I just want to know how do you start it after you've finished edited some things in .xsession (or .xinitrc) file?

desert sky
#

Is it the one that u have to recompile every time?

sudden socket
#

I used it a decade ago. yep. reconfigure by recompiling

turbid ore
#

Hey guys anyone use qubes OS?

desert sky
#

I dont need it nd honestly tails on a portable stick is more secure if thats the main concern

turbid ore
desert sky
#

there is also parrot os, which is from hackthebox.com a good website, it's just locked behind a paywall

turbid ore
gilded heath
#

Unix is a kernel of Linux, correct?

#

What is Unix good for aside from being user-friendly?

wise forge
wise forge
wise forge
wise forge
# gilded heath What is Unix good for aside from being user-friendly?

Performance efficient to your hardware, runs mostly anywhere
Does not contain annoying malware avg windows has, no AI, no windows updates, no security beaches with recall and etc. Linux is made to be used by real people instead of promoting greedy corp interests and annoying features

gilded heath
gilded heath
# wise forge Great for anything related web, backend, DevOps development. Native docker run. ...

What does DevOps mean and what does it do? What is a Docker Run?

Iโ€™m sorry if these are silly questions to ask. I am brand new to computer science as a whole. All that I am familiar with is that there is three main Operating systems (iOS, Linux, Windows), a couple of programming language names, that RAM and SSD mean two different things, and that you can reroute the function of certain hardware through the software. That is all that I am familiar with right now. But I am genuinely interested in expanding my knowledge so that I can be a great software developer.

wise forge
# gilded heath What does DevOps mean and what does it do? What is a Docker Run? Iโ€™m sorry if t...

DevOps has different meanings, but practical one would be saying using Infrastructure as a code tools for programmatic management of server infrastructure. For usually running of backend applications but not only that

Modern web/cloud solutions have quite sophisticated setups to run well in high availability, horizontal auto scaling performant and monitor able and etc stuff. Special tools/languages simplify it considerably

wise forge
# gilded heath What does DevOps mean and what does it do? What is a Docker Run? Iโ€™m sorry if t...

Docker is a thing... In web development that became a standard for last ten years as better alternative to virtual machines for running applications. Or instead of running them in polluting main os directly with their dependencies
Instead of creating entire VMs, we now wrap all web apps to lightweight containers, that embed infrastructure as a code approach to build them, they reuse existing Linux kernel/core for their lightweight running, and run with uniform way for deployment.

If u learn to use docker, u will be able raising any db in 30 seconds
Including raising things like even entire complex apps as long as they have docker compose to them written

wise forge
gilded heath
fickle granite
#

yes.

#

It's the opposite of user-friendly, though.

#

Many of us nerds like it; but for normal humans, it's awful.

gilded heath
fickle granite
#

such as very little decent work done on user interfaces

#

User interfaces are hard, and unpleasant to develop; and the only people who do them well are professionals who get paid a lot of money. Totally free software cannot afford to pay their salaries, so they go work for Apple or Microsoft.

This is a controversial opinion.

#

You might as well download a Linux distro and play with it; it's free (if your time has no value ๐Ÿคฃ)

#

I recommend Ubuntu

distant fox
gilded heath
gilded heath
# fickle granite such as very little decent work done on user interfaces

What do you mean by โ€œdecent workโ€? Are most Linux kernels unfinished and unusable without much work put in? I understand that some kernels do not have user interfaces like Windows and iOS does, but what I am curious about is how some systems donโ€™t have keyboard controls? I understand not having mouse controls, but keyboard? How are you able to input commands without a keyboard?

#

I can understand that programmers donโ€™t need user-interfaces because all that matters is the ability to look at the code itself and make changes. None of which requires a user-interface to function.

#

I hope that I can get to a point where I can have the knowledge to code without using a user-interface. I think that would be quite fun to do.

fickle granite
wise forge
wise forge
#

That some people find it not user friendly, araises only from people having freedom to do everything and they try to do everything (arch users), and attempts to launch windows only software at it, or being in general not used to it non tech users unable to read

wise forge
#

Kubuntu is most close looking to Windows and easy to use, makes nice transition

wise forge
#

After u get used to it, u see Windows interface as User Not Friendly. How the heck to work with OS where any program installation and its usage IS NOT telling why it is not working?

#

After using LInux i feel pretty much crippled in how much Windows is NOT POWER USER friendly

#

all Windows focus always aimed to be friendly for DUMB NON TECH user. And pushing for whatever corporate shit they wish at the moment in addition.

#

At the end of a day Windows is not even aiming to be friendly for Dumb Non Tech user as first priority, they push to make cosmetic changes to their interface for the sake of justifying to sell more copies/licenses of it

#

if u will start using Linux and get used to it, u will discover what is OS that is actually made Friendly with (Power) User in Mind.

fickle granite
#

sure -- when I say "not user friendly", I mean your grandma won't want to use it. Developers generally prefer it.

#

But you know -- I'm a developer, and I like (most of) the grandma-friendly stuff too.

wise forge
#

or at least all my grand parents rarely figured out stuff

fickle granite
#

heh well

#

we're all "family IT"

wise forge
#

Linux very grows on you and u become very attached to its structure and logic at some point

fickle granite
#

well I know that. But I'm a long-time programmer

wise forge
#

...any thing they learned about Windows probably got already too much outdated ๐Ÿ˜„

fickle granite
gilded heath
gilded heath
gilded heath
wise forge
wise forge
wise forge
# gilded heath Should I learn how to use terminal before I install Linux or afterwards? Does Wi...

Does Windows prevent people from using the terminal console effectively?
Windows is essentially not automtable beyond some crude measures. Windows is made with GUI first in mind.
Linux is made with terminal/console first in mind.
Linux has grown ecosystem around it to automate it, from professional way to hobbiest ways different tools.
Any automation u will find for Windows are only crutches to work around to bring some level of it, but it willl never be even close to Linux in terms of automation.
Linux will remain dominating in terms of being automations to be configured as desktop and server machine just because people invest only into it, because linux has Free licenses and can be spawned in whatever amount it is necessary for it, and windows is not free.

#

Modern web infrastructure requires dozens/hundreds of server machines being spawned in autoscaling

#

Windows has High overhead due to a lot of trash running in background besides lack of automations, it is just too much more expensive, so the obvious domination of Linux in server web infra happens already last dozen of years at least

#

Some Windows administratrators try to automate windows anyway, but they deserve only a lot of pity for their sufferings

gilded heath
# wise forge At the end of a day Windows is not even aiming to be friendly for Dumb Non Tech ...

I had a feeling that Microsoft Windows is hiding a lot of important things behind its โ€œbells and whistlesโ€. I have already noticed that it is a hassle to access important functions on Windows, and recently I have noticed that they removed certain features like the ability to change the clock from 12-hour intervals to 24-hour intervals. It severely pissed me off as I very much prefer to have the clock set with the 24 hours option than the 12 hours that is the default on Windows.

gilded heath
wise forge
#

i have rarely needs to launch Windows though as i am web backend dev / devops engineer / just picking games friendly for linux

#

i launch Windows only like... 1 time per year ๐Ÿ˜„ usually regretting doing that and turning it off back

#

Anyway, using Linux u will benefit right away at least just by saving a bit of money on licenses, and needing less hardware to run it

wise forge
#

i plan on my current weekends to raise Minecraft modded server for example ๐Ÿ˜‹ works well too.
More than that, Minecraft-Java tech is friendly for launch on Extra Cheap arm64 Linux servers from hetzner

#

Enjoyed to play Starsector in previous vacation

#

Great games usually support Linux, if they don't support it, they are usually not that good in the first place ๐Ÿ˜„

gilded heath
wise forge
gilded heath
wise forge
#

Steam does really good stuff in promoting Linux gaming

#

It would be nice if one day it entirely dominated landscape, then the last major point for Windows usage at Desktop will fall

gilded heath
gilded heath
#

@wise forge May I ask what you do as a DevOps person? Do you make certain mobile apps or something?

wise forge
# gilded heath <@370435997974134785> May I ask what you do as a DevOps person? Do you make cert...

DevOps engineers operate with server infrastructure as a code usually.

  • Company has dozens of backend server applications to run. Who has written infra code to have them running? DevOps engineers by using Infrastructure as a Code tools (Docker, Terraform, Pulumi, Kubernetes, providers like AWS, GCP, Azure and etc)

  • Company has dozens of backend, frontend web apps. and devs wish to write features only and not being distratected by how it is automaticlaly tested, built, released and deployed? Devops engineers using Docker, AWS cli tools, Github Actions, and different other scripting glue if necessary. Devs just marge to master branch, and the rest by their code automatically gets deployed to staging.

  • Company has dozens of backend, frontend applications, and even mobile ones. Who gives help to raise centralized distributed monitoring systems to monitor their performance if they behave correctly in production? Devops engineers using Grafana/Loki/Tempo/Mimir-Prometheus, or Sentry, or Datadog and etc tech, deployed through Terraform/Kubernetes/Docker whatever means

  • Company has bad performance on frontends, too much high traffic, needing caching. Who will fix it? Again devops enginers will configure CDN from cloudflare/bunny/aws whatever

  • Devops engineers will automate deployment of web applications

  • Devops engineers will automate tracking health and performance of applications

  • Devops engineers will seek optimizations to spend less money onto all this infrastructure to run this stuff

#

I was originally just Web Backend Developer that had responsibilities to deploy backend/frontend on my own with whatever means ๐Ÿ˜„
I wished to automate stuff, and not keep in my head how the things are done regarding productional running, so eventually learned plenty of tech for that

#

There are Devops engineering roles with more focus onto Operational routine to handle just raised problems, and they could be handling baremetal servers too. Such people are usually called Site Responsibility Engineers, but i have more focus onto being Dev first DevOps engineer and have aim onto just making software development easier for devs

gilded heath
#

Cool!

wise forge
#

A good first step towards devops stuff, learning how to wield docker containers well. That will be useful skill for backend devs/fool stuck devs too
And learning at least just how to write CI for their stuff at repo
Docker alone helps u having more flexible dev env, fully emcompassing all dependencies it has.
That is usually still responsibility of backend devs to learn though

gilded heath
#

What is the difference between DevOps and Networking?

#

I was recommended Networking because some of my interests lie in that field

wise forge
# gilded heath What is the difference between DevOps and Networking?

devops engineers can be needing networking, but i think it is pretty minor and just basics stuff. ๐Ÿคทโ€โ™‚๏ธ
at most biggest networking devops engineers do... configuring Public/Private networking separation for the soft to run. it is not a big problem too and thing that can be done with small amount of tries and errors.

fully fledged Networking job roles usually assume you are network designer / advanced form of system administrator that is able to set networks and servers in a physical world.

Devops engineers usually do not interact with physical world and configure it at the level of infra code provider automating tools.
Unless the devops engnieer is more site reliability engineer, sys admin on steroids more focused on operational duties, in which case he can be having network profficiencies too, to operate correctly hardware.
Depends on the specific role and how company understandards them.

Some DevOps job roles never deal with physical servers
Some Devops job roles deal a lot with physical servers and networks. only the latter ones need deeper networking knowledge

#

Both job roles by accident are named with same name of a Devops engineer, despite very opposite duties.

gilded heath
#

Would you say this falls align more with DevOps or Networking?

โ€œBecause the reason why I want to become literate when it comes to technology. I want to have more control over my technology, more control over my data, avoid malware and predatory services, and stick it against big corporations that holds a monopoly on everything we have in life. Iโ€™m just fed up with the direction the world is going right now, and I am even more pissed off with how the big software companies are controlling our digital lives.โ€

#

I really want more control over my data and what I can do with the technology at hand. Whether it is automation or something else.

wise forge
#

I prefer to stick to balanced pragmatic level of it.

#
  • i make sure my server infrastructure is using self hosting means if i can, for homelab at least
#
  • i make sure i manage my backups on my own, and make sure i will not get locked out of accesses because of ridiciulous corporate decisions
#
  • i like to manage my own site
  • and i of course enjoy using linux as OS, as it is more fitting my dev needs and just tastes in general at this point
#

otherwise i will not be bothering ever with managing my router software, or email, not going to do anything related to phone too, those are all difficult challenges, or not worthy of my time challenges. I am happy to pay money to my Internet service provider and having things running in this direction

#

although i did actually rather.. big thing of relocating to another country where internet is way better and not censored

#

my origin country went a bit crazy with censoring everything

gilded heath
wise forge
#

i probably at some point will make dedicated Network accessable storage/servers to store my files though may be. that could be a good thing to have

#

i am now not at risk to have all my accesses lost if anything happens to my google acc

#

So... i do self hosting my life in reasonable amounts, the ones which are easy to implement/maintain/free to maintain

gilded heath
wise forge
gilded heath
wise forge
# gilded heath DevOps sound more interesting than Networking does. Mainly because I love the id...

How should I start learning how to be a DevOps developer?
learn to be Backend developer first, build backend apis, web sites,
Learn smth like building things with Golang, .Net, or Java Quarkus stuff
Master being backend dev, learn working with relational databases properly and building things in quality in general
https://darklab8.github.io/blog/favourite.html#UnitTestingPrinciplesPracticesandPatterns
https://darklab8.github.io/blog/favourite.html#TestDrivenDevelopmentByExample
https://darklab8.github.io/blog/favourite.html#CodeCompleteAPracticalHandbookofSoftwareConstruction
Build stuff with quality
Learn backend dev fluff https://roadmap.sh/backend

learn to own infrastructure more with learning how to use docker (read book about it too, like Docker up and running)
Progress eventually to automate all server infra (Terraform up and running is good step forward)
Explore stuff devops engineers use https://roadmap.sh/devops

alternative path assumes being sys admin more somehow first, i have no idea how the path goes from this.
I went to devops from being backend dev, and i help backend devs with infrastructure/automations/observability for their apps

gilded heath
# wise forge i lived in Russia, i chose to live in Serbia

Oh cool! I was raised in and still currently reside in the US. With how things are going along right now I figured it was high time to learn how to develop software and become computer literate. That and also because it fits the skill set that I currently have as well as desire.

gilded heath
gilded heath
wise forge
# gilded heath Would it be advisable to stick with Windows for right now or just jump straight ...

i think it is great to go for Linux right away. less to relearn after that
It is best to do IT career with getting CS degree first though, and in university u can be asked to run Windows specific stuff
there can be a point to use Windows with WSL2 during your university education for those reasons, or at least keeping Windows at dual boot in case of emergenecy
if keeping Windows at dual boot, i think there is nothing holding to go for Linux as primary OS

gilded heath
wise forge
# gilded heath Oh? I thought that it is perfectly reasonable to learn how to code without getti...

Ask in #career-advice , there should be plenty of people from USA too.

As far as I am aware with CS degree u just have good avg chances to make the career in IT.
4 years help a lot to train your skills.
With some self studies on top and if possible internship, career has quite high chances to go

On another hand Plenty of companies filter people away if they don't have higher education in STEM by default for dev jobs.
It is possible to do without degree, but just way less likely by 10 times.
Harder to get career perspective positions
U will need somehow shine despite this big hole in your resume. Having good enough luck or relatives in necessary positions, having very good portfolio or plenty of experience in some lower ranked positions

gilded heath
long python
#

hi just have a question, i get some weird things on RPI4 after some time and reboots the SD card looses its partition table i guess i get this error

#

did anyone experience smthng like that maybe before and has a solution? when i format the sdcard and burn the image again it works again

tight zinc
#

idk tbh'

cursive aurora
long python
dusky granite
#

is it possible to make a bootloader as if it's just a program, but instead of loading an operating system, I mean for example make it like a program that adds two numbers? And the second thing is, does the BIOS put the interrupt table with it in RAM, which is the IVT, and put it at a specific address in RAM and put the value of this address in a register inside the processor which is the IDTR? And if for example in the case that the program did int 0x10, it would go for example to a specific address in the BIOS ROM and execute display code on the screen for example? Is this correct or wrong?

copper tree
#

hAC

tender plinth
#

Has anyone come across a tool that can automatically identify configurations to be enabled/disabled for a given function to be comliled into the linux kernel?

rotund girder
tender plinth
# rotund girder I don't know anything about compiling Linux, so maybe the question already makes...

When you compile the kernel, there are these configurations that u can tweak, each configuration enabled or disabled conditionally compiles in code from various modules (guarded by #ifdefs). Now, problem is these configs enabled specific modules (one or more kernel source files) for compilation. I want more fine grained control, ie, given a function name, i want to identify all configs need to be enabled/disabled along with conflict resolution (certain configs may conflict with certain other conflicts)

wise forge
#

Assuming that kernel/unit test is smart enough to Panic/Crash/(preferably with Traceback) if u try to invoke not enabled stuff, it should work perfectly and be proper GitOps to the management of this thing

#

TLDR: regular git centric dev env

#

for unit testing writing to refer to popular unit testing framework/organization of a chosen language for which this thing is intended ๐Ÿ˜

trail sapphire
tender plinth
wise forge
#

I make assumption here that linux kernel source is indeed large and has always changing documentation.
With organization stuff through GitOps with unit tests first, may be u will have at least some level of reliability instead of the approach u wish to do

#

your original question assumed relying onto the tool if everything was identified and turned on correctly

#

i encourage to see if it is possible to organize Git centric, Unit testing centric approach instead.

#

My line of thinking araised from: if u compile smth and call functions from it, then it should be automated buildable and validatable process?

#

Git first s friendly approach for system level dependencies configurations regarding infrastructure configurations

#

so could be the same approach used here, instead of attempting resolving it with third party tool?

#

if you have the idea how to make linter u make as reliable, it is good too, but regardless if u make it or not, u could be wishing some level of validations towards it
git centric approach to configuring anything usually has a level of more... reliability, self documentation to it, reproducing, everything

wise forge
#

tldr:
Consider possibility of workflow. U need extra feature in kernel?
open git repo, searched necessary option (may be even with your tool made), run tests, git commited, CI ran tests
Once u confirmed that CI run is succesful, applying automated deployment to where u need it

#

Perhaps with this approach u will not even need the tool u originally considered?

#

if all validations to correct running will be present in gitops approach like that and validated, u will have reliability that everything is turned on as it is (if main concern was that)

#

and it will be lesser effort each time just checking which features to turn on from documentation search

small wraith
# dusky granite is it possible to make a bootloader as if it's just a program, but instead of lo...

I didn't quite understand the second question. The CPU starts in 16 bit real mode. This is real mode and all physical addresses are real. Segmentation is mandatory for x86. You are using virtual memory as segmentation. Virtual memory is available in 32 or 64 bits. There is also something called protected mode.

Virtual addresses are used by an application program. They consist of a 16-bit selector and a 32-bit offset. In the flat memory model, the selectors are preloaded into segment registers CS, DS, SS, and ES, which all refer to the same linear address. They need not be considered by the application. Addresses are simply 32-bit near pointers.

Linear addresses are calculated from virtual addresses by segment translation. The base of the segment referred to by the selector is added to the virtual offset, giving a 32-bit linear address. Under RTTarget-32, virtual offsets are equal to linear addresses since the base of all code and data segments is 0.

Physical addresses are calculated from linear addresses through paging. The linear address is used as an index into the Page Table where the CPU locates the corresponding physical address. If paging is not enabled, linear addresses are always equal to physical addresses. Under RTTarget-32, linear addresses are equal to physical addresses except for remapped RAM regions (see section RTLoc: Locating a Program, sections Virtual Command and FillRAM Command) and for memory allocated using the virtual memory manager.

so

virtual -> linear -> phy memory.

// it is for x86. Not others.

small wraith
#

Actually this 16 bit mode is complete nonsense. Nobody buys 9950x3d and installs DOS in it. It is protected for historical and backward compatibility reasons. That is why segmentation exists.

dusky granite
#

i want someone to confirm if my understanding is correct:

When someone presses a key on the keyboard, for example the letter "A", the character goes to the keyboard controller, where it's stored in one of its registers.
Then, the controller sends an interrupt request to the CPU.
The CPU checks the Interrupt Vector Table (IVT), which was placed in RAM by the BIOS.
But in order for the CPU to know where the IVT is located, it reads the IDTR register to get the IVT address.
After finding the interrupt address, the CPU jumps to the BIOS code that handles the keyboard interrupt.
Then, the CPU reads the character from the I/O port of the keyboard controller, where the character is stored.
Finally, the CPU stores the character (e.g., "A") somewhere in RAM.

Is that correct?

rain orchid
#

With python for android can i include ask the extra modules required in my apk? I have an app already and in just trying to launch a python repo

trail sapphire
rain orchid
#

I'm kinda stumped on my project

trail sapphire
trail sapphire
rain orchid
#

Right now I'm using chaqoupy which gets me about 60 percent of the way. But that's proving to fall short. I've already got an apk which I just use gradlew to build. I've added chaqoupy and it seems like a good option except it's missing pydantic v2 and I'm not sure about building the wheel for.

#

I'll get a link of the project

#

The apk from the main branch fully works. This is just to add the mod manager

trail sapphire
rain orchid
#

But those create entire apps yea?

trail sapphire
rain orchid
#

Just run the script, my apk is a full dynamic game launcher. I want to run the python main() function that so run the full mod list Downloader. All the code to display it in the ui is done, I just can't get the script to fully run from missing pydantic v2, and also struggling to get def open_url to trigger the browser

#

The script currectly uses xdg-open for Linux

trail sapphire
rain orchid
#

Ok thanks

#

It's definitely tricky and there's not much info

#

Not much i can understand anyways

dusky granite
#

Are integrated components like the network card, USB controller, and onboard sound card all connected through the PCIe bus?

slate crypt
#

Some things are pci, some are usb. See lspci and lsusb

jade oyster
#

how do i make ls pretty

#

i cant read gray font on green background

rotund girder
prime magnet
# jade oyster how do i make ls pretty
  • try by just changing the theme of your terminal.
  • there are aliases out there that can help you to change the way colors are used in the terminal.
  • there are things like oh-my-zsh that helps you to customize the way your terminal looks.
limpid dirge
#

i use arch (btw) and not just for the meme tbh

rotund girder
latent bolt
#

i was using fedora then went back to windows 7 for games but now im stuck doing devel on windows (i can dual boot anytime i just wanna see when will this thing fail)

dusky granite
#

The motherboard comes with a pre-divided address space - meaning certain address ranges are allocated for RAM, certain ranges for I/O devices, and certain ranges for BIOS, etc. But the processor just puts addresses on the address bus that's connected to all of them. Based on how the motherboard manufacturer divided the address space, when the processor puts an address on the address bus, the processor doesn't know what this address belongs to - but this address gets routed based on how the company that manufactured the motherboard determined the address space for each component.
For example, if the address space allocated for RAM is 8GB, I can't install 16GB of RAM because that would exceed the allocated address space. But I can install less, like 4GB. Is this the correct understanding?

desert sky
fluid lake
#

why does my discord eats up so much memory

#

not only discord, somtimes even firefox with 2-3 tabs makes my lap go brrr...

wise forge
#

basically it is having Chrome/or some other browser under the hood

#

and for browser it is normal to consume up to 1gb+ of ram per single tab in heaviest cases ๐Ÿ˜„

fluid lake
#

I thought electron apps are supposed to be light

#

damn

wise forge
# fluid lake I thought electron apps are supposed to be light

comparatively.
Skype in C++ was fast and furious. Skype in electron became a lagging crap.
Vscode browser in electron is quite fast and light, Jetbrains IDEs in Java manage to be way more heavier and slower

So... it is smth of the level
C++/Rust is super fast, C#/Go slower, Electron is slower yet reasonably fast, then Java (but in some cases Java faster than electron), then PHP/and other scripting go and then Python

#

Despite whatever language is used devs could be lazy and not optimizing their stuff properly, in this case things can be slow in any language ๐Ÿ˜„

fluid lake
#

I see, thank you.

dusky granite
#

Does "Memory Mapped I/O" mean, for example, if the CPU is 32-bit (so the address space is 4GB), the BIOS can allocate 3GB of addresses for RAM, and when the BIOS does enumeration, it gives each device (like the graphics card) an address range from the remaining 1GB of addresses?
So basically, the term "Memory Mapped I/O" means that you take part of the address space that could have been used for RAM, but instead you assign it to a device (like the graphics card).
This way, when a program sends an address, the CPU checks if it belongs to RAM or to the graphics card, for example. Is that correct or not?

mortal jasper
mortal jasper
wise forge
# mortal jasper Did they switch to electron when microsoft took over? I remember that period aft...

https://www.osnews.com/story/30585/microsoft-kills-win32-skype-client-in-favour-of-uwp-version/
https://www.reddit.com/r/skype/comments/fkj19n/skype_uwp_is_dead_long_live_electron/
Originally it was made in C++, with some kind of Delphi mix?
They remade it to UWP (highly likely C# based) in 2018 year already, and they faced performance issues ๐Ÿค”
And in 2020 year they remade it to Electron

mortal jasper
#

I remember it became usable after a while, yeah, but I also clearly remember how they destroyed it back then. It was striking.

wise forge
# mortal jasper I remember it became usable after a while, yeah, but I also clearly remember how...

it was serous of sabotage both on Desktop and Server side looks like
UWP tech was crap already in 2012-2020 era of Windows 8 when they remade it to it, but they remade it even crappier version in Electron since 2020

But besides sabotage of Desktop, they also sabotaged Servers with changing from decentralized p2p to centralized Azure servers ๐Ÿค”
https://arstechnica.com/information-technology/2012/05/skype-replaces-p2p-supernodes-with-linux-boxes-hosted-by-microsoft/
https://www.theverge.com/2012/5/1/2992341/skype-replacing-p2p-supernodes-hosted-machines-security

Ars Technica

Microsoft has replaced P2P Skype supernodes with thousands of Linux boxes.

The Verge

A security researcher has discovered that Microsoft has moved Skype away from its reliances on P2P supernodes to a solution using security-hardened Linux machines hosted by Microsoft and Skype themselves.

#

Micro$oft in all its glory

#

๐Ÿ˜…

#

3-4 years ago i unfortunately had to try Teams

#

That was such a lagging glitching crap back then as a desktop client (that crashed for me somehow in addition)

#

not really enthusiastic to install or try it again

mortal jasper
#

I've yet to see a company organise interviews other than in teams... it's pretty insane ๐Ÿ˜„

#

they're all Microsoft full on.

wise forge
#

all tech works excellently fine without big complains

#

i guess except i still haven't figured out how to work with desktop Slack well ๐Ÿ˜… but its browser version works good enough to me

vapid panther
#

unix

fervent mortar
#

Hi everyone,
I built a small tool to save clipboard history. I often copy an API key and then accidentally overwrite it by copying something else in between. So I created a lightweight Linux service that pulls the clipboard content every 500 milliseconds in the background. You can use it just like git stash with commands like hcp list to view clipboard history and hcp <index> to retrieve a specific entry.

Please see if this could be helpful for any of you. https://github.com/Agent-Hellboy/hcp/releases/tag/v1.0.0

fervent mortar
latent flame
slate crypt
fervent mortar
#

Wayland based system

slate crypt
#

Also, you should respect xdg directories. Store your database file in ${XDG_STATE_DIR:-$HOME/.local/state}/hcp/history.block

fervent mortar
#

And it's default in Ubuntu 25.04

slate crypt
#

I think with wayland, you'll need to use the dbus to listen to a copy event

fervent mortar
#

Wayland doesn't allow background sniffing, I am working on pocs to resolve the security aspects

fervent mortar
fervent mortar
#

Any other suggestions?

slate crypt
#

FYI KDE plasma has a clipboard applet

fervent mortar
#

Yeah, there are a plenty of open-source projects out there, created this for learning only.

fair cypress
#

Guys i need help in bash anyone?

rotund girder
lucid mason
#

Tf are ppl keep using this trash system

rotund girder
lucid mason
lucid mason
slate crypt
#

I will teach bash. curl is a separate topic.

lucid mason
slate crypt
#

Find what?

upper prairie
#

a way to cope with the OS ecosystem's current state, perhaps

slate crypt
rotund girder
#

Bash is a nightmare, I have yet to abandon it ๐Ÿ˜ญ

dusky granite
#

The idea of the GDT is that I define the address of the code, where it starts, like from address X to Y, and the data has a size from this to that, and the stack has a size from this to that, so I can enter Protected Mode. All of this is set up just for the code, data, and stack, so when the Kernel executes, it determines the size of all these based on the Kernelโ€™s own size. In other words, I allocate fixed parts of the RAM for the Kernel, which is the operating system. Is my understanding correct?

slate crypt
#

You can now capture a process without a subshell

#
x=1
out=${ x=$((x + 1)); xxxx; } 
echo $x # 2
echo $out
rotund girder
#

What did you have to type before?

I don't think I'm getting new bash very soon. My other reasons to trying to switch to fish or zsh is syntax highlighting.

But mainly I'm just tired after going long wrestle games with PROMPT_COMMAND and tty settings after trying to run the command fg as a keybinding ๐Ÿ˜ญ๐Ÿ˜ฉ

slate crypt
rotund girder
#

Ah! ๐Ÿ‘Œ

lucid mason
exotic whale
#

bash is great, y'all just lack good taste

fickle granite
#

bash is trash

#

srsly I only stopped using bash interactively after Apple strongly encouraged me to move to zsh. I still use it for short scripts, though

trail sapphire
#

the interactive shell i use is almost always bash on linux, which is my main OS
and zsh on mac just because it's the default there
i don't think it's such a big deal or such a big different really (then again, i don't spend so much time on macOS and hence zsh)
but for scripts i try to go POSIX compliant or just use bash specific features when POSIX is too much of a hassle or drawback, bash is available in most unix like environments today anyways

formal schooner
#

It's the old tradeoff: portable code vs. portable runtime

lucid mason
visual vessel
#

Hello

spark mulch
#

!tvmute 1340518774423421001 14d Spamming is not the way to pass the voice gate, as you have been warned in bold letters in #voice-verification

shy yokeBOT
#

:incoming_envelope: :ok_hand: applied voice mute to @deft stirrup until <t:1753958012:f> (14 days).

rotund girder
# fair goblet Why

I have set up so many helper stuff in, otherwise I would already be on fish. But also most colleagues use bash and it's valuable to use the same.

rotund girder
# fair goblet Why

Things I have wrestles with is Job management (trying to figure out if vim is currently open and running or in the background) , trying to understand tty and realizing fg shouldn't/can't be run from a keybinding.

Also by default it doesn't:

  • show return value of last command

And I don't know if it supports:

  • have abbreviations
  • syntax highlighting

Setting up the prompt is quite complicated as I had to learn about bash arrays and PROMPT_COMMAND

deft stirrup
#

Hi

fickle granite
#

my current zsh prompt, e.g.

rotund girder
#

Yeah, no I don't really like those prompts, it's a bit too much. I have something dedicated for my work environment. Depending on which of 2 to 3 modules are loaded. Plus git info of course ๐Ÿ™‚

#

I only tried starship I should say.

#

Not sure how they would interact with direnv and nix-shell. I guess there is a chance they fix things, but I would rather haver fewer moving parts to debug ๐Ÿ˜…

spark mulch
#

@rotund girder Hey, I've recently found you making comments on an old uv issue (the one about human-readable rule names). Did you ever end up working on that; or do you know what the status of it is? I can't understand it from the ticket.

desert fog
#

need help : i am using linux mint cinnamon, with gnome terminal. I have made my terminal transparent but don't know how to add the blur effect.

rotund girder
# spark mulch <@185793553539137537> Hey, I've recently found you making comments on an old uv ...

Do you mean this ruff issue? https://github.com/astral-sh/ruff/issues/1773
I know about it, but it doesnt seem to mention my name? And no I don't spend time to develop in my free time, I stop at filing issues ๐Ÿ™ˆ

GitHub

Pylint, ESLint and Clippy all let you enable or disable lints via human-friendly names e.g. Pylint lets you configure: disable= wildcard-import, method-hidden, too-many-lines The idea is to also su...

rotund girder
#

Oh right, needed to expand the list

rotund girder
spark mulch
rotund girder
#

Me too ๐Ÿ˜‚

spark mulch
#

(not really interested in working on it right now)
I was just asking because someone commented that apparently they (astral) want a different solution and I couldn't find what that means.

rotund girder
#

@spark mulch I just found this short discussion: https://github.com/astral-sh/ruff/pull/11757

So it might just be that they want to decide on the details before continuing. But I think they are focusing effort elsewhere still.

I've been hoping for stable pycodestyle lint rules for a long time ๐Ÿ‘€

GitHub

Summary

Works towards #1773.
Allows users to write noqa directives with human-friendly rule names. Users can write noqa directives with a comma-separated list of rule names (# noqa: ambiguous-vari...

knotty igloo
#

was wondering when that was gonna land

real vapor
#

apparently ruff lsp allows looking up the definition of codes

spiral widget
#

outing myself as hyper-noob here but....ok so JUST learning Linux on ubuntu with WSL and occasionally I'll mess up a command and it gives me nothing but ">" on the screen and not returning anything so matter what I type. How do I get back? (Also appologies if this is not the right pace for this kinda question)

upbeat lotus
upbeat lotus
spiral widget
#

yeah, thats actually exactly what I did. Forgot to close quotes which sent it to that. Cant seem to get it to return though, even replying to echo commands. Just comes back blank

upbeat lotus
spiral widget
#

ah, ctrl c worked. Hoping I eventually get to a level where I roll my eyes at asking this question ๐Ÿ˜… Thanks a million!!

trail sapphire
rotund girder
clever cape
#

Is it important to start ssh service in the beginning of learning Kali or not important?

#

I am using Kali as a VMWare btw

trail sapphire
trail sapphire
# clever cape I am doing cs stuff for sure

CS as in Cyber Security and not as in Computer Science, right? ๐Ÿ˜‰
okay, if it's for cyber security Kali linux is fine ๐Ÿ‘
but if you want to use it for general linux usage or development i would recommend something else

trail sapphire
# clever cape cybersec yeah and I learn terminal

learning to use the shell/terminal/command line isn't specific to cybersec and can be done on mostly any linux distro
but sure, i'm guessing you're using utilities that aren't typically installed by default in just any distro but is in Kali

clever cape
barren sorrel
#

I'm an expert in chromeos

trail sapphire
#

please remove that and don't post things like that here on the server

odd notch
#

!warn 1365315568533639168 Don't post malicious commands here

shy yokeBOT
#

:incoming_envelope: :ok_hand: applied warning to @main olive.

median pasture
#

hey

#

how are yall doing>?

main olive
#

got a warning :c

flat sentinel
#

hello

main olive
normal spear
#

Helo

spark forum
normal spear
spark forum
#

i am here not for learning bc i hate python( why bc it's really slow )

#

just for having some fun

spark forum
#

or you dev on python?

#

i respact devs tho

normal spear
spark forum
normal spear
spark forum
#

i am dev on: C++ , Rust , my lang , Luau , PowerShell , Batch , LLVM APIs

spark forum
spark forum
#

and help you learn it too

normal spear
spark forum
#

i think you don't care it's alright O_o

normal spear
normal spear
spark forum
normal spear
#

So i am so new to some terms they r going above my head

spark forum
#

POV: mods right now looking at my msgs

normal spear
#

Like so u created a lang
Right?

spark forum
#

yup.

#

if you don't belive me it's real i can show you some codes tho

normal spear
#

Hm I think firstly i should learn something bout coding so I can understand basics
I'm totally new, u know
Switching so quick is difficult for me

#

Also I have to ask one frnd before
Will do wht he says

spark forum
#

tip. start with luau

#

is simpler then python and will let you learn the basics

spark forum
normal spear
#

Okk thx for ur time ๐Ÿ™‚

spark forum
#

i mean: DLS = lang use for 1 thing like game dev

normal spear
spark forum
#

GPL mean lang use for very things like web AI apps etc...

normal spear
spark forum
normal spear
spark forum
normal spear
#

Um so i should switch to rust in future

spark forum
normal spear
#

Can u tell the difference between llm ,api

spark forum
#

API like you have a computer you send the data ( input ) and do the work and get you the ( output ). use most time for bridge between 2 programs

normal spear
#

Gottcha

spark forum
#

so API use every where

#

you right now using API

#

your pc , discord , browser , internet , all use APIs

normal spear
#

Last que
Like after python what I am going to have skills in

spark forum
spark forum
normal spear
#

Ah alright tysm bro

#

๐Ÿ”ฅ

spark forum
#

last thing. never give up

normal spear
#

Ok cya

spark forum
maiden agate
shrewd jewel
#

hi

alpine pebble
#

Whats the difference between Linux and Unix?

formal schooner
# alpine pebble Whats the difference between Linux and Unix?

Unix is an old and historically very important operating system dating back to the 70s, and the term is also used to mean operating systems that are "unix-like" in their design. Linux is one such operating system, which is open source and available free of charge, unlike Unix which was a commercial product

alpine pebble
#

Wouldnt it be linux instead

formal schooner
alpine pebble
formal schooner
#

So it's not just Linux, it's anything descended from Unix including BSD and MacOS as well as command line tools and other details that are common across descendants of Unix

abstract narwhal
#

Which linux is used most in industry?

light haven
#

headless

frank nebula
#

Hi

abstract narwhal
#

is it not allowed to install linux on macos?

granite aspen
#

Mac -- a brand of computers
MacOS -- the operating system that comes with Macs

#

if you buy a computer that comes with Windows, you can make a separate partition and install Linux on that. That Linux partition isn't "linux on windows". it's a separate partition of the computer itself, and linux is talking directly to the machine. not windows.

#

make sense, @abstract narwhal?

abstract narwhal
#

is it not possible to single boot?

granite aspen
#

are you wanting to fully replace windows with linux?

abstract narwhal
#

dual boot is slow

#

people told me

granite aspen
#

is this on an older laptop, or something like that?

abstract narwhal
#

on macos

#

brand new macbook pro m2

odd plover
#

no, dual boot isn't slower compared to a single boot. you only have one OS running at any given time.
what you reduce is disk space.

granite aspen
#

I wouldn't replace the OS on a brand new machine.

abstract narwhal
#

why

#

i want to learn linux

granite aspen
#

you can make linux VMs

abstract narwhal
odd plover
abstract narwhal
granite aspen
#

only one is using it at a time. that doesn't slow it down.

abstract narwhal
#

i have 8gb ram

abstract narwhal
formal schooner
# abstract narwhal i want to learn linux

Dual booting linux on a new Mac is going to be a challenge beyond just learning Linux. I think you will have a much easier time if you use a dedicated cheap computer like a raspberry pi, or use a virtual machine

formal schooner
#

Just getting Linux to run at all on a newer Mac has been a substantial technical achievement, look up Asahi Linux

abstract narwhal
#

should i get linux on that

formal schooner
#

That's more likely to be an easier experience, but you should download a Windows recovery installer and create a recovery USB just in case you want to go back

uneven pasture
#

you can also learn all the relevent linux stuff that a regular dev needs on your macos , you dont have to install a seperate linux distro

formal schooner
#

Note that laptops can be challenging with Linux as well

formal schooner
formal schooner
#

I recommend against installing on a laptop for your first intro

abstract narwhal
#

is ubuntu not for arm architecture?

uneven pasture
formal schooner
#

Probably the easiest way to get started is to just use Docker Desktop for Mac

formal schooner
uneven pasture
abstract narwhal
#

docker , kubernetes and many other dev things work on linux

#

not on mac

uneven pasture
#

says who

abstract narwhal
#

and don't even talk of windows

uneven pasture
#

they work on windows too , just fine

odd plover
# abstract narwhal ubuntu doesn't work on mac?

Running Linux on Apple Silicon Macs needs substantial changes. Asahi Linux packages them for you in an integrated distro.
Ubuntu does have ARM64 builds, but Apple Silicon is not a standard ARM64 environment.

abstract narwhal
#

and not others

#

since m1 chip

abstract narwhal
formal schooner
abstract narwhal
#

my linux won't work now

#

๐Ÿ˜ญ

abstract narwhal
#

i think i'll have to work on dell now

uneven pasture
abstract narwhal
#

๐Ÿ˜ญ

odd plover
abstract narwhal
#

i wanted linux on my macos

#

๐Ÿ˜ž

uneven pasture
#

you can setup your dell as a headless linux machine and ssh into it using your mac

abstract narwhal
#

what's this stuff

#

so i'll have to carrry two laptops everywhere i go?

uneven pasture
#

for the stuff you are saying you need to learn , you dont need a different linux distro at all

#

you can do all of that on your mac

abstract narwhal
#

i want to experience full fledged linux

odd plover
#

you're not out of options
you could use a VM

abstract narwhal
#

i don't want to miss out on anything

uneven pasture
#

then use your dell to get a feel for linux

abstract narwhal
#

VM or dual boot

#

VM doesn't allow many things

#

dual boot allows

#

but it consumes disk space

#

i'm cooked from both sides

#

๐Ÿ˜ž

abstract narwhal
#

it's touchpad and keyboard is better than dell

odd plover
abstract narwhal
#

idk man i'm just stuck

odd plover
# abstract narwhal

That comparison table is suspect
As far as I know, being in a VM doesn't affect cgroups features at all
I wouldn't expect significant limitations in sysfs either

shrewd stratus
#

โ€ฆwhat is Kubernetes cluster realism?

abstract narwhal
zenith anchor
zenith anchor
#

What do you want to do with it? Maintain your OS yourself?

#

If so yeah, you won't be able to do it

uneven pasture
abstract narwhal
#

and there are many dev things which are not in macos

shrewd stratus
#

It seems like you have already made up your mind

zenith anchor
#

like bro

#

listing everything you cant do

#

idk

abstract narwhal
#

i'm still not sure

#

that whether i should switch to linux

#

from macos

summer trail
#

Plenty of people run Linux containers on macOS using Docker

abstract narwhal
#

actual performance of mac reduces

shrewd stratus
#

Is the slowness noticeable?

abstract narwhal
#

also you don't get many features in linux vm

shrewd stratus
#

Because I definitely haven't noticed it

abstract narwhal
#

which you get in complete linux os

abstract narwhal
#

slow

#

many other things

shrewd stratus
#

Lasts a day

shrewd stratus
summer trail
#

I've never heard any of my coworkers complain about Linux VM slowness, but - even if it is slower, so what? You're looking at using it for Linux features, not for speed

abstract narwhal
#

are you using linux vm on macos?

shrewd stratus
#

Yes, for Docker

summer trail
#

sure. You can do that with a VM

abstract narwhal
#

i have to do coding

#

i don't want anything slow

abstract narwhal
shrewd stratus
#

Again, is the slowness noticeable for you?

abstract narwhal
#

how's the experience

#

which mac you have

summer trail
#

most code is IO bound, not CPU bound. VMs don't introduce any slowdown for IO bound work. And modern VMs introduce very little slowdown for CPU bound work, tbh

abstract narwhal
#

and what's the RAM

#

also you have less linux features on VM

summer trail
#

if you run your software in the cloud, it's running in a Linux VM

shrewd stratus
#

M1. 16 GB.

summer trail
#

you might be thinking of Rosetta, tbh

#

there's a pretty big slowdown for emulating x86 on an arm macbook

shrewd stratus
#

I'm mostly running arm64 containers, though, yeah

summer trail
#

yeah. If you've got an arm macbook, run arm containers, not intel ones

abstract narwhal
#

it's running on linux OS

#

VM just has linux

summer trail
#

yes, it's running on a Linux OS, running in a VM

abstract narwhal
#

that's not where every software running

#

you can run without VM

#

it needs linux OS

#

not VM

summer trail
#

cloud offerings are basically always virtualized

abstract narwhal
shrewd stratus
#

cloud baremetal is expensive

summer trail
#

the overwhelming majority of backend software runs in a VM these days

#

it's been that way for at least a decade at this point

#

anywho, if you really do want to run Linux outside of a VM, I'd strongly recommend not doing that on your macbook. I'd buy another machine to install it on

#

Apple isn't particularly open with their hardware specs, and don't write Linux drivers for their custom hardware, so the Linux drivers for Apple hardware tend to be buggy and feature-incomplete, based on reverse engineering by hobbyists

odd plover
summer trail
summer trail
trail sapphire
summer trail
#

interesting, TIL

#

I've never actually needed to do any GPU programming, so everything I know about it is second hand

trail sapphire
#

it's probably mostly aimed towards hosting, could infrastructure and enterprise environments from the looks of this https://docs.nvidia.com/vgpu/latest/grid-vgpu-user-guide/index.html
but the supported hardware seems to range from quite normal workstation Quadro RTX GPUs and upwards
on the software side, host support seems to range from KVM, XenServer, Proxmox (found that last one on another site) to vmware vsphere
sure, you could probably get it up and running in a homelab with the right hardware and software and licenses, but it won't be a cheap setup

zinc pivot
#

should i switch from windows 11 to ubuntu, like are there any cons?

left grove
uneven pasture
trail sapphire
trail sapphire
formal schooner
#

Has anyone here tried using FreeBSD as a desktop OS? If so, what was your experience like?

#

I've been thinking about migrating my handful of self hosted services to some BSD variant and using jails instead of Docker images. But I really appreciate the BSD base system + ports model and it seems appealing for a desktop OS

rustic sky
#

I haven't used solely as a desktop OS but I did have a machine that I was doing a lot of work on

#

it is pretty decent how much is supported on FreeBSD actually

#

I was using it probably 3-4 hours a day, had KDE running on it etc., things were pretty smooth

#

& yes, jails are fantastic

#

there is a period in my open source project history where all my projects have deployment instructions based on BSD jails rather than containers ๐Ÿคฃ

#

so overall yeah, I can definitely vouch for it, it's a different experience but if you're willing to put the learning effort in and accept that some things are going to be a PITA that are easy on other systems it is very rewarding

upper prairie
shy rover
#

I am a software engineer with a BSc Honours in Computer Science from BITS Pilani. I am currently in the process of developing a Linux-based distribution operating system from scratch as a side project. I welcome anyone interested to connect with me.

zinc pivot
zinc pivot
left grove
zinc pivot
zinc pivot
left grove
uneven pasture
uneven pasture
#

but it gives you power to use everything as if you had linux running on your PC

rustic sky
fresh dust
#

hello how do i instal python?

rustic sky
fresh dust
rustic sky
fresh dust
rustic sky
fresh dust
#

Thx

zinc pivot
zinc pivot
frank tree
rustic ingot
#

I mean, I get what you're going at, I have the same reason for using Linux, I just really like Gnome
other factors are in play but that's just a part of my "emotional reasoning"

#

I'm dual booting because I don't have a strong enough reason to completely leave Windows
I moved because I like Linux, not because I hate Windows

fresh dust
#

mb for the messege my acc got hacker but the guy didnt knew i do cyber sercurity

cyan hawk
#

@zinc pivot use wsl sub system for scripting it's more convenient

#

But it's partially has slightly lost in efficiency

torn tapir
#

Powershell is nice

rustic sky
#

powershell has some nice ideas

rustic sky
#

huh, never realised how fucked library resolution for libraries from homebrew is on apple silicon macs

#

there is almost no way to have python pick up libraries installed via homebrew because the variable that python looks for is purposefully removed by the shell

fickle granite
#

?

rustic sky
#

Homebrew patches their Python versions it seems so it's not so bad, but out of the box with, say, a uv env you cannot use libraries installed from homebrew

fickle granite
# rustic sky https://github.com/orgs/Homebrew/discussions/3424

I have the vague sense that

  • /opt/homebrew/lib is not the right folder bzzt, wrong; it clearly is ๐Ÿ™
  • when you brew install whatever, it typically prints out a message like "to use these libraries, add /opt/homebrew/lib/Cellar/whatever/3.2.1/ to your library path" I probably am thinking of something else -- finding executables on PATH, maybe ๐Ÿ™
rustic sky
#

/opt/homebrew/lib symlinks to the cellar files

fickle granite
#

yeah I just noticed that

rustic sky
#

whilst i was struggling with this I did forget that homebrew is not like apt and does make python versions available at reasonable times

fickle granite
#

odd that I've never run into this myself. Perhaps when I uv install some-fancy-package, it installs the shared librairies for me, and fixes up the LD_LIBRARY_PATH too

rustic sky
#

so I guess the solution is to just ensure you're always backed by homebrew versions of Python and to stop uv trying to pull it's own versions in

fickle granite
#

heh

rustic sky
fickle granite
rustic sky
fickle granite
#

yeah I think "uv" is automagically taking care of things: ```
/Users/not-workme/.local/share/uv/:
find . ( -iname *.so ) -ls
111908319 52 -rwxrwxr-x 1 not-workme staff 50784 Feb 2 2025 python/cpython-3.10.16-macos-aarch64-none/lib/python3.10/lib-dynload/_crypt.cpython-310-darwin.so
111908320 76 -rwxrwxr-x 1 not-workme staff 75232 Feb 2 2025 python/cpython-3.10.16-macos-aarch64-none/lib/python3.10/lib-dynload/_testclinic.cpython-310-darwin.so

bitter salmon
#

terminal talk!

lucid ridge
#

hello

bitter salmon
#

ghostty +show-config --docs | prettybat --language yaml

#

piping to bat made it readable

lucid ridge
#

what's prettybat

#

is that a formatter

bitter salmon
#

bat wrapper.. i use it for code, but this config was not triggered..

main olive
bitter salmon
#

i think --lanuage yaml is wrong

bitter salmon
lucid ridge
#

like nedbat? ๐Ÿ‘€

bitter salmon
spark mulch
#

unbuffer ghostty .... | less -R should also work, right? Then you should get the correct colours

woeful dome
#

ghostty: where scrollbar?

main olive
#

or was it foo: bar i don't remember

bitter salmon
#

well.. cat should work right?

spark mulch
#

(unbuffer to trick Ghostty into thinking it's displaying things on a TTY, and -R to have less output the raw data, instead of escaping ANSI codes)

bitter salmon
#
tino/proc.h:511:3: error: too many arguments to function โ€˜IGURโ€™; expected 0, have 1
  511 |   IGUR(ret);
      |   ^~~~ ~~~
In file included from tino/file.h:102,
                 from tino/buf.h:33,
                 from tino/buf_line.h:26,
                 from tino/main.h:26,
                 from tino/main_getext.h:26,
                 from unbuffered.c:9:
tino/debug.h:121:18: note: declared here
  121 | TINO_INLINE(void IGUR()) {}     /* see http://stackoverflow.com/a/27672750 */
      |                  ^~~~
tino/sysfix.h:47:39: note: in definition of macro โ€˜TINO_INLINEโ€™
   47 | #define TINO_INLINE(X)  X; __inline__ X
      |                                       ^
In file included from unbuffered.c:14:
tino/signals.h: In function โ€˜tino_siginterruptโ€™:
tino/signals.h:64:3: warning: โ€˜siginterruptโ€™ is deprecated: Use sigaction with SA_RESTART instead [-Wdeprecated-declarations]
   64 |   if (siginterrupt(sig, flag))
      |   ^~
In file included from /usr/include/sys/wait.h:36,
                 from tino/proc.h:19:
/usr/include/signal.h:324:12: note: declared here
  324 | extern int siginterrupt (int __sig, int __interrupt) __THROW
      |            ^~~~~~~~~~~~
make: *** [<builtin>: unbuffered.o] Error 1
==> ERROR: A failure occurred in build().
    Aborting...
error: failed to build 'unbuffered-2.2.0-1':
error: packages failed to build: unbuffered-2.2.0-1
๏…ผ ๏€•  ~                                                                                                                          ๏‰’  11s ๏€—  15:17:33 โ”€โ•ฎ
โฏ
```\
main olive
spark mulch
main olive
#

why not just write to a file

#

so you can also search the contents of the docs

lucid ridge
#

usually | cat or env PAGER=cat is what I do in those situations

bitter salmon
woeful dome
spark mulch
main olive
bitter salmon
main olive
spark mulch
main olive
bitter salmon
#

yeah... im just experimenting with languages

#

whats the uv tool command to install black globally?

main olive
#

uv tool install black i believe

bitter salmon
#

nice... prettybat uses black under thhe hood.. neat

gray pivot
#

i think most package managers have something along the lines of python-black

bitter salmon
#

alacrtitty

bitter salmon
main olive
#

uv is god sent

gray pivot
main olive
#

wish it was made sooner lol

bitter salmon
#

im testiing uv now siince i already have a new machiine setup

#

im very slow to move over to new tooling

#

but once ii do, i go all in

main olive
#

in that case perhaps you should try ruff instead of black lemon_fingerguns_shades