#ot1-perplexing-regexing

1 messages · Page 337 of 1

gentle moss
#

and can you imagine the overhead on that?

#

that'd be insane

tired osprey
#

there is no overhead i can feel on our internal openstack or azure cloud

#

where should the overhead be coming from?

gentle moss
#

what you're talking about probably isn't equal to an actual physical connection

#

it's probably still a remote shell

#

just rendered in a browser

tired osprey
#

well

gentle moss
#

shell / desktop

tired osprey
#

if we set it to vga in openstack we cant copy and paste from it, if we set it to serial we can copy paste form it

gentle moss
#

if it's an actual physical connection then you'd have full control of the virtual machine from boot

tired osprey
#

so im quite sure its at least a virtual connection

#

and yes bisk

#

thats is the point

solid pollen
#

Or you just don't suck at your job and don't lock you out of the server

tired osprey
#

i mean

gentle moss
#

you can actually completely lose access to AWS instances

#

even if you have the root AWS account login

#

losing a key requires a support ticket to fix, for example

tired osprey
#

in the end there are at least 3 devs in my group doing kernel development for openbsd which test their shit in the internal cloud, if they dont have control over the VM from boot they kinda have a problem / cant use the openbsd debugger

#

so

#

i am quite sure that these connections are real connections

#

at least real in the /dev/ttyX file system

gentle moss
#

i'm still not sure you can count that as the same as a physical connection

#

¯_(ツ)_/¯

#

can they get into the boot loader, etc

tired osprey
#

i mean if its existant on the machine like an actual /dev/ttyX connection

if i can copy paste from it

if i can type into it even if the kernel panics and drops into its debugger

if i can get into the bootloader

is that a real connection?

gentle moss
#

it's a connection but it's not the same as a true physical connection

tired osprey
#

i mean apart from the cable part i dont see a difference

#

¯_(ツ)_/¯

gentle moss
#

press f8 to load in safe mode

#

¬_¬

tired osprey
#

i dont think that is gonna work for openbsd

#

iirc the openstack cloud emulates their VMs on KVMs running qemu

gentle moss
#

well the comparable i imagine would be single user mode

tired osprey
#

we have to drop into single user mode for our installation at least twice

#

so yes that works

gentle moss
#

i meant comparable to safe mode

tired osprey
#

as i said you can even still type if the kernel panics, drops into single user mode and opens its debugger

gentle moss
#

but that does sound pretty deep for a remote connection

rough sapphire
#

i'm back

tired osprey
#

hello

rough sapphire
#

@tired osprey that's not serial

tired osprey
#

thats not serial?

rough sapphire
#

the framebuffer is just being transmitted over to you

tired osprey
#

no

#

that is VGA

gentle moss
#

i'm reading some azure documentation now

tired osprey
#

not azure

#

openstack

#

i am talking about our openstack cloud

#

we explicitly moved away from VGA / framebuffer stuff to serial so we can actually copy the output from kernel panics @rough sapphire

#

in azure thats gonna be framebuffers prolly yeah

#

but not for our openstack cloud

gentle moss
#

it's apparently not for azure

tired osprey
#

what do they do

gentle moss
#

also this doesn't appear to be for any normal setup

#

these are specialised deployments

rough sapphire
#

@tired osprey ok, even then it's deserialised way before it ever reaches you

#

as I doubt you can change the parity, baud rate etc

tired osprey
#

that i am not sure about

#

ill have to check when i get back to work in two weeks

gentle moss
#

i'm reading the documentation

#

i mean... it's basically just access to the virtual machine at a higher level

#

weird that they've called it a serial connection

#

then again i'm not sure what else it could be called

undone berry
plucky ridge
#

I can't get past the name

gentle moss
#

hahaha

plucky ridge
#

Also dibs on that being my stage name

gentle moss
#

Dick King-Smith?

#

and piers, dogs are the best part of any election

plucky ridge
#

name.split('-')[0]

gentle moss
#

so many good doggos

gentle moss
#

backdooring our own server to stop the apprentice breaking shit

#

letting him configure fail2ban tomorrow

plucky ridge
#

Not exactly what I'd call the smartest of things to do

#

Or most secure

solid pollen
#

You have installed a backdoor haha

gentle moss
#

it's temporary

solid pollen
#

Poor apprentice

gentle moss
#

besides the server isn't web accessible right now

solid pollen
#

He is learning at his own speed

plucky ridge
#

Can't you just give yourself admin rights rather than a backdoor? Or is that what you're doing

gentle moss
#

well to be fair he completely fucked up ssh

#

couldn't even get in as the root user

#

well, the ubuntu user

plucky ridge
#

That's.... how?

gentle moss
#

root login is obviously disabled

#

because he fucked with PAM

#

and broke shit

plucky ridge
#

Oh right right

gentle moss
#

just a little reverse shell

plucky ridge
#

Call it "The Magic Conch"

gentle moss
#

i prefer "fail 2 dumb"

sand goblet
#

I guess it was inevitable really

rough sapphire
#

"Bad people are bad people, news at 9."

rough sapphire
#

Anyone know anything of cryptocurrencies and merkle roots?

#

Trying to piece together why a merkle root would be \x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00

#

I think it just hit the end of what's available, so it just zeroed it out, and it's not setup to deal with the issue - but not 100%

solid pollen
#

Can it even have an end?

rough sapphire
#

¯_(ツ)_/¯

#

Hmm.

solid pollen
#

Don't think, since it just store hashes

rough sapphire
#

I mean more hit the end of the blocks that are currently available.

#

Since it pulls from the daemon's folder

#

Since the error only seems to happen at the end of all of the block commits

#

I'll print around and see what I can find

#

lol, looks like it might have been an .encode('hex') issue

#

Yep, that's it.

solid pollen
#

Hmm interesting

#

What's causing it?

rough sapphire
#

Well, I'm not 100% but I'm testing it and I think it just didn't get the information from something that was either .encode('hex') or .decode('hex') - which doesn't work on Python 3.

#

Checking it out now

clear turtle
#

just did my first github release :)

#

our model is starting to look good!

vestal briar
#

Firefox doesn't let me type

#

There we go, 2 restarts later

sinful copper
#

i just had the most random thought

#

[yeah yeah fitting name laugh it up]

#

so, krispy kreme has a donut that is a yeast donut injected with cake batter

#

so i just randomly thought, wouldn't it be weird if after the success of that item they introduced a cake donut filled with raw yeast dough

rough sapphire
#

i need to scream

#

aaaaaa

gentle moss
#

ARRRRRRRRRRRRRRRRRGH

#

fuck everyone.

rough sapphire
#

hello police

#

omg don't swear Christian python server

#

I found a bottle of Monster Energy today.. thought of you Bisk.. because it's probably banned in the UK

gentle moss
#

uhhh

sand goblet
#

Well that exit poll wasn't super wrong

#

What is it, a 78 seat majority?

rough sapphire
#

about the energy drinks?

gentle moss
#

yeah, that's a dumb thing to suggest

#

"hurr durr UK bans everything so probably no monster lol"

rough sapphire
#

where do you buy your kitchen knives

sand goblet
#

At the kitchen knife store!

rough sapphire
#

that sounds scary

gentle moss
#

usually at a cookery shop?

sand goblet
#

They have other kitchen things too

gentle moss
#

or at a tesco

#

or a coop

sand goblet
#

Tesco doesn't stock knives here

gentle moss
#

or a lidl

rough sapphire
#

I miss Lidl

sand goblet
#

Why, is it banned?

#

:>

gentle moss
#

classic tronland

rough sapphire
#

no.. because it's not available outside the EU lol

gentle moss
#

banning cheap german food

sand goblet
#

It does exist in the US

rough sapphire
#

I once found a 1 € beer at Lidl.. it was amazing

gentle moss
#

i bet they don't even have fish and chips because they're banned

rough sapphire
#

lol

sand goblet
#

They probably do have face sitting though

rough sapphire
#

they actually do.. there's a lot of weird places in Tokyo.. for those things

#

look at it! that's a whole bottle of monster o.o

#

just ban food

#

No more overpopulation

solid pollen
#

You can’t buy it usually?

gentle moss
#

to be fair, you can't get it in bottles here afaik

#

but then again

#

you can buy a 4 pack which contains a total of 2L for £4.50

solid pollen
#

You can get it in a can, but not in a bottle??

gentle moss
#

yeah

solid pollen
#

That’s.. weird

gentle moss
#

i think it's a consumer demand thing

#

energy drinks are viewed as like a single serving rather than a thing to drink throughout the day?

rough sapphire
#

oh.. hmm this is like 500ml for 2.5 eur

solid pollen
#

Hmmhhhmm

gentle moss
#

oof

#

that's... expensive

#

monster tastes like shit anyway

rough sapphire
#

yeah.. everything is expensive here

gentle moss
#

rockstar has all the best flavours

#

tropical guava is a pretty good one

#

they also have some peach ones

#

or mango

#

i like my energy drinks not to taste like anus

rough sapphire
#

how do you know what that tastes like

gentle moss
#

¬_¬

rough sapphire
#

apparently there's more sugar in rockstar

#

and Monster has larger market share..

gentle moss
#

yeah but redbull is fucking super expensive and also tastes like shit

#

but people still buy it

#

branding i guess

rough sapphire
#

some people like how it tastes..

gentle moss
#

those people are monsters

rough sapphire
#

did you know the original formula for redbull is from thailand

gentle moss
#

yes

#

and technically redbull didn't start manufacturing it

#

they only purchased the rights to market it

#

they're pretty much just a marketing company

rough sapphire
#

people love those..

sand goblet
#

A marketing company with wiiiiings

rough sapphire
#

Wiiinngssssss 💸

gentle moss
#

can't doubt the success of redbull

#

tbh a lot of sports only get the coverage and events they now do thanks to redbull

rough sapphire
#

used to chug them down during high school years..

sand goblet
#

I've never really been a big fan of energy drinks

#

I used to drink powerade occasionally at school

gentle moss
#

i doubt without their investment that WRC would be as widely covered as it is now

sand goblet
#

It's like lightly flavoured water

gentle moss
#

i only drink them when i really want to ramp up my heart rate and anxiety

#

otherwise i go for coffee

rough sapphire
#

lol

#

i love Sting pretty sure nobody heared about it .
owned by PepsiCo

gentle moss
#

sounds tantric

rough sapphire
#

Sting Energy Drink is a carbonated energy drink from PepsiCo International and produced by Rockstar Inc. Sting is available in three flavours, such as original Gold Rush, Gold (with Ginseng), Power Pacq (Gold Rush with Malunggay), Power Lime (Kiwifruit/Lime) and Berry Blast (...

#

i love it 😍

#

monster tastes like an unicorn's crack and i don't mean that in a good way

#

red bull is where it's at

gentle moss
#

string: every sip you take, every move you make, we'll be watching you.

rough sapphire
#

red bull and monster taste exactly same 2 me

#

what

#

no

#

they're nothing alike

#

that's sting not string

gentle moss
#

typo.

#

oh hey

#

that's interesting

rough sapphire
#

don't change topic

gentle moss
#

Talks to package millions of British medical records into a vast, commercially valuable database that may then be sold on are already underway between NHS England bosses and global giants

rough sapphire
#

i like this topic

gentle moss
#

energy drinks is a pretty limited topic

rough sapphire
#

i've always given a fake name at the NHS

#

nau drinks ?

gentle moss
#

red bull is fine for jagerbombs but i wouldn't drink it for normals

rough sapphire
#

there was a gap when i drank monster and redbull so maybe yeah there is a difference

#

you're a savage

#

jägerbombs require the cheapest, vilest energy drink ever

#

you know, the shit that's sixty pence a litre

#

don't taint my expensive red bull with your jäger

#

price_of_sting = price_of_monster/3.33

#

not cans

#

cans is like half

#

pint of ribby for 2 quid mate

#

it's expensive

#

but so good

#

whats quid ?

#

currency ?

#

the english pound

sand goblet
#

If you think 60c energy drinks sound bad

#

Let me tell you about 60c vodka

#

Hooooo boy

rough sapphire
#

let me stop you there

#

i don't want to go blind

sand goblet
#

Seriously though

#

Tesco vodka back when I was in university

#

everyone was fucking drinking it

#

and it was like paint stripper

#

I don't drink but I could taste it on the air

#

they were getting like, concentrated fruit cordial

#

filling up the glass and then adding a shot of this vodka

#

(so it wasn't diluted)

rough sapphire
#

i gagged

sand goblet
#

haha

#

I have no idea how they drank it

rough sapphire
#

hey man, students

sand goblet
#

some of us have standards

solid pollen
#

Vim users, which plugin manager do you use? Last time I tried vim-plugin, it did some dumb things (maybe my fault actually)

tired osprey
#

@solid pollen pathogen

#

not necessarily because its the most convenient but because i sometimes work on machines that are not allowed to communicate outside of our internal lan but id still like to have access to my plugins without having to download them from github (which i cant on those machines)

solid pollen
#

Hmm

#

Well, my machine can communicate with the internet

#

Is it pretty strait forward to use?

tired osprey
#

with pathogen you basically have a "call pathogen#infect()" in your vimrc and its gonna load all subdirectories in .vim/bundle as plugins

#

so you always gotta carry your .vim/bundle with you

#

which if it is a git submodule isnt really a problem

#

like

solid pollen
#

Hmm interesting

#

But I think I should start with something more simple

#

But.. I keep that in mind, thanks!

rough sapphire
#

hi there

rough sapphire
#

hello

rough sapphire
#

ok uni, but won't the fact that i graduated a year ago be a bit of an issue?

tired osprey
#

No @rough sapphire

#

Don't question the university

#

Bad boy

rough sapphire
#

so your name is Rasmus

#

what's the program about

#

idk some travel bollocks

#

not really interested

#

and I don't even think I qualify seeing as I'm not an undergraduate

terse sluice
#

woah i see the markdown previews now

#

that's cool

plucky ridge
#

It's soooooo nice

#

No more having to guess if you're lining something up properly

terse sluice
#

yeah agree it's awesome

rough sapphire
#

Auto completion could make it better ;-;

plucky ridge
#

I'm not going to look a gift horse in the mouth

#

This is leaps and bounds better than what it was

terse sluice
#

auto completion is probably far, far away

rough sapphire
#

still
a good Christmas present to us

plucky ridge
#

God damn it f1re, now the Star Wars opening theme is in my head

terse sluice
#

😂

stark prawn
rough sapphire
#

4058

#

my browser didn't liked that number and not loading it

undone berry
plucky ridge
#

AWWWW

#

That biggun's had a little too much cheesecake

cloud wren
#

@undone berry My brother and his two roomates have two rats. At first I was like why would you have rats, but they are actually super cute and fun to have.

plucky ridge
#

And they're so affectionate

undone berry
#

Yeah, they seem like great pets. I think I'll get some when I graduate

plucky ridge
#

And they'll sit on your shoulder and nuzzle you and clean your ears

rough sapphire
#

Plague.exe

rough sapphire
#

Nice to see the server kept this logo btw

#

It's really cool

gentle moss
#

Rats are amazing @undone berry

gentle moss
#

oh great

#

i'm still on a "temporary" 30 minute lockout from the Datto portals

#

friggin great

#

HAH

#

and it gets better

#

a customer's exchange server can't send or receive

#

and i can't access it because of the lockout

#

oh god, their support isn't going to be of any help again yaaaay

#

"it seems like your ticket has been assigned to the security and compliance team so i'm not sure how much i'll be able to do?"

#

we should've carried on self hosting labtech

gentle moss
#

an apprentices story; part 236347:

#

my ssh account hasn't got the correct permissions on the google authenticator file and i cannot login

#

default account works, but the 2FA barcode hasn't been saved anywhere

solid pollen
#

Time to use the backdoor!

gentle moss
#

quite

vestal briar
#

What's it called when something happens then just goes completely back to normal, making it feel like you just made it up

sand goblet
#

A surprise?

vestal briar
#

No, a suprise is more of a happy scare

pine vector
#

a figment of your imagination? 😄

vestal briar
#

Example is someone starts screaming at someone and stops, but nobody really reacts

pine vector
#

hehe. i call that being desensitized to someone's outbreaks. "Jimmy's at it again. meh."

#

but, i don't have a word for it... 🤷‍♂️

dark epoch
#

hi

solid pollen
#

Hey!

dark epoch
#

👋

#

Ive got as far as creating a repo

solid pollen
#

So, you are going to need a server that will receive the information from github that something has changed on the repo

dark epoch
#

I have a debian server

solid pollen
#

Have you configured nginx or apache or something?

dark epoch
#

No

solid pollen
#

Okay

#

I think we can make it run a specific port, so that's okay

#

Okay, have you ever used flask?

dark epoch
#

yes

#

I tried building a website for like 2 days and then I gave up

solid pollen
#

Great, so we are going to create an app for it to receive gh infos

dark epoch
#

okie

solid pollen
#

Can be as simple as that

from flask import Flask

app = Flask(__name__)

@app.route('/')
def push():
    # Pull data
    return```
dark epoch
#

wow

solid pollen
#

Well, we need something instead of # Pull data

#

What is your project?

dark epoch
solid pollen
#

Hmm, we are going to kill the process when we have a new push

dark epoch
#

sounds good

solid pollen
#

I'm looking for the docs

dark epoch
solid pollen
#

Python

#

Subprocess

dark epoch
#

oh

solid pollen
#

Okay so, do you have a link to your repo?

dark epoch
#

shall I just copy the url

solid pollen
#

Yep

dark epoch
#

ok

#

i dmed you the link

solid pollen
#

Man, it is a private repo, can't access it

#

That's okay

dark epoch
#

should I change it

solid pollen
#

How do you run your bot?

dark epoch
#

oh through cmd

#

right now Its running on my debian though

#

on a tmux session

solid pollen
#

What is the command?

dark epoch
#

to run the script?

solid pollen
#

To run the bot?

dark epoch
#

python3 main.py

solid pollen
#

Okay

dark epoch
#

I have multiple files

#

that are run by that main file

#

automatically

solid pollen
#

I think we can do something like this :

from flask import Flask
import subprocess

app = Flask(__name__)

bot_process = subprocess.Popen(['python3', 'main.py'])

@app.route('/')
def push():
    global bot_process
    bot_process.terminate()
    subprocess.run(['git', 'pull', '--force'])
    bot_process = subprocess.Popen(['python3', 'main.py'])
    return```
#

It should work

#

Try to run this file, the bot should start

#

It need to be in the same folder as main.py

dark epoch
#

ok

#

whats the command to make a new file?

#

wait nvm ik

solid pollen
#

What editor do you use?

dark epoch
#

atom

#

im doing it on the debian server no?

solid pollen
#

Yes

#

You have only shell access to the server or you have a GUI access?

dark epoch
#

gui

#

idk what the differance is

solid pollen
#

All g then

dark epoch
#

i think its a gui

#

ok

#

lemme do that

solid pollen
#

GUI you can click, shell you just have a terminal

dark epoch
#

i just have a terminal

solid pollen
#

So shell

dark epoch
#

yes

solid pollen
#

You need to use a terminal based editor then

#

Either nano, simpler but it is as basic as the notepad, or vim, but keybinds are weird

dark epoch
#

ye i use nano

solid pollen
#

So just nano <filename>

dark epoch
#

ye

#

i need ti install flask right

#

to*

#

do i need to install subprocess

solid pollen
#

Only flask, subprocess is built in

dark epoch
#

ok

#

done

#

lemme get my charger real quick

#

done

#

ok what do i do next

#

shall I run that script

solid pollen
#

Yep!

dark epoch
#

okie

#

done

#

its running

solid pollen
#

Nice!

dark epoch
#

what do I do now

solid pollen
#

Do you have a line * Running on http://127.0.0.1:5000/?

#

In your shell output?

dark epoch
#

no

solid pollen
#

Okay, add this at the end of your file

if __name__ == '__main__':
  app.run(host='0.0.0.0')```
#

The bot is still running?

dark epoch
#

ye

#

alright done

solid pollen
#

Hmmm, I think we need to kill the bot first

dark epoch
#

how do I kill it

solid pollen
#

Are you 100% certain that it is still running? The end of the script should have killed it

dark epoch
#

yeh still running

solid pollen
#

Try to run ps aux | grep -i python3

dark epoch
#

okie

solid pollen
#

kill 7682

dark epoch
#

operations not permited

vestal briar
#

sudo/run as root?

dark epoch
#

yeh it worked

#

bots still running though

solid pollen
#

It should have stopped now..

dark epoch
#

OH

#

I THINK I KNOW WHY

#

MY TMUX SESSION STILL RUNNING

#

caps

vestal briar
#

OK

dark epoch
#

nvm

#

no dont got any sessions running

#

but still not stopped

#

@solid pollen

solid pollen
#

Reboot?

dark epoch
#

the terminal?

solid pollen
#

The server

dark epoch
#

how do I do that?

#

nvm doing it now

#

done

#

yup bots offline

solid pollen
#

Okay, now restart the script

dark epoch
#

ok

#

I see it now

#

what shall I do now

#

it hasent auto shut yet

#

terminated*

#

@solid pollen

solid pollen
#

Try to push a new commit (something you can test easily if it has been updated) and then visit http:<server plublic IP>:5000/

dark epoch
#

ok

#

I dont have any files in the git thing yet

solid pollen
#

Oh, I thought you were in a git folder

dark epoch
#

how do i upload the files

solid pollen
dark epoch
#

done

#

i added the files

#

and added a new test command

solid pollen
#

Not 0.0.0.0, your server public IP

dark epoch
#

oh

#

same thing

#

thats the external ip

solid pollen
#

Are you on port 5000?

rough sapphire
#

your ports need to be forwarded if you're connecting from your external ip dog

dark epoch
#

im on port 5000 yes

#

@solid pollen

solid pollen
#

Yeah, probably something blocking it in between

dark epoch
#

how do I fix that

#

?*

rough sapphire
#

you need to set up port forwarding

dark epoch
#

what does that mean

terse sluice
#

it’s in your router settings

#

it’s different for each router model/brand

dark epoch
#

i dont have access to my router settings

#

im not the admin

terse sluice
#

this wouldn’t be possible then

#

you’d only be able to connect to it locally

dark epoch
#

rip all I wanted to do was to push my git code to my server lol

terse sluice
#

you could use a hosting service

dark epoch
#

?

vestal briar
#

Stumbled upon some strange semi-russian propaganda video for putin and found this comment:

#

Don't think that's quite how it works

undone berry
#

Given that half the world hates America (not unfairly so) its not a particularly surprising sentiment

rough sapphire
#

i don't hate america

#

i hate how america only thinks about america or seems to have this conception that the US is the only country in the world

#

but still

vestal briar
#

When it says the west, does it mean the west or just america

rough sapphire
#

also west from what

#

everything is west from something

vestal briar
#

West and east are just political terms on a 2d projection of map

rough sapphire
#

don't know about you dog but I live in a 3d world

vestal briar
#

That doesn't even corrospond on a 2d map anymore because of places like australia

undone berry
#

The west refers generally to NA, Europe and Oceania

vestal briar
#

Yeah

undone berry
#

Western culture vs eastern culture

#

Also, Central/Southern America very understandably hate the US - as does the Middle East

vestal briar
#

Going back to that comment, are they also saying some prudent political figures in the 20th century are good?

rough sapphire
#

@sonic night nah, even their compass/map projection works in a way where everything is west from something

#

it's like a circle unto itself

vestal briar
#

THE ICE WALL

rough sapphire
#

torus earth theory

vestal briar
#

I still don't get how you could even think it's flat

#

I mean if we dug deep enough we'd come out the other side?

undone berry
#

I think they just want to rebel against some universally accepted idea

#

like subconciously

#

so they don't give a shit about the logic in it

vestal briar
#

So then how would the earth be structually sound

rough sapphire
#

@vestal briar but nobody's ever dug even close to deep enough for that

#

no pic no proof

undone berry
#

It doesn't matter that they're wrong - just that they're different

vestal briar
#

Well how do they know the depth

rough sapphire
#

and don't give me that NASA doctored bs

vestal briar
#

Is it just a cylnder with one side populated or something to them?

rough sapphire
#

you know, my gf used to sorta believe the flat earth theory, or at least found it very plausible

#

she had this seemingly "smart" friend who misused her trust by telling her all of these fucking theories

#

freemasonry, illuminati, flat earth etc

vestal briar
#

What would be the motives in covering up the flat earth anyway

rough sapphire
#

and she believed her because she thought the friend was smart

#

kinda sad really

#

gotta be slightly sociopathic to keep that shit going for as long as it did

undone berry
#

Yeah, somewhat smart people who try to mislead others or just lie when they don't know something are some of the biggest scumbags

#

and then they turn around and say "its just a joke" or get annoyed because you don't trust them

vestal briar
#

Yeah

rough sapphire
#

makes me sorta really angry thinking about it

#

don't get angry very often

grave phoenix
#

Earth is a dinosaur

solid pollen
robust sierra
#

pfft nasa making rockets when they could have made the astronauts skydive off the edge smh

solid pollen
#

roothink x2

robust sierra
#

@vestal briar hmm say we did dig deep enough

#

would you just fall into space?

vestal briar
#

The void

#

Well gravity apparently doesn't exist

#

So i'm not sure

robust sierra
#

okay so

#

how far down until you start feeling the force of gravity on your head

vestal briar
#

Gravity isn't a thing

#

Forget all scientific knowlage becuase it apparently is all created by nasa

rough sapphire
#

gravity does not exist

robust sierra
#

we're all just really fat

rough sapphire
#

the earth is accelerating upwards at a constant rate of 9.8 m/s²

solid pollen
#

Gravity doesn't exist, it is all about fatness

robust sierra
#

^

#

helium can zoom up into the air because its anti-fat

#

i read the channel name as "no dirty alpacas"

wheat lynx
#

Surely if there was no gravity and the Earth was accelerating up you still wouldn't experience a gravity like effect

robust sierra
#

hm

solid pollen
#

Well, they are fat things

#

So their fatness make them go closer to the ground

robust sierra
#

no drag means no gravity like effect?

#

@wheat lynx because no drag?

solid pollen
#

No, they are all flat, because it is better

solid pollen
jagged fog
#

I'm getting tired of people who buy those

terse sluice
#

imagine spending over 56 grand on a mac pro

undone berry
#

I'm getting tired of people who buy those for osx power users, it's just the most sensible choice

#

But the ecc thing is pretty shitty

jagged fog
#

osx power users?

undone berry
#

Yeah

#

Tonnes of them

#

Including a lot of developers

jagged fog
#

ah ye the vicious circle

terse sluice
#

if i really wanted osx, i’d honestly use a hackintosh

jagged fog
#

but understandable

terse sluice
#

yeah

undone berry
#

Not even necessarily the vicious circle. It's just a good choice for a lot of people

jagged fog
#

ye I can't see that

#

if you're not making cash money with it then there's no reason to have it

#

(anything apple related really)

undone berry
#

Well. Most users are making cash with it

#

Or with the one they use at work, so they use the same at home

terse sluice
#

lots use logic pro, final cut, and other programs

undone berry
#

For a lot of people spending an extra couple of thousand on a computer just doesn't matter

#

And they don't care about the specs as long as it runs smoothly

jagged fog
#

Ye that mentality is meh

vestal briar
#

That's like being rich and not picking up a £10 note on the floor

rough sapphire
#

space is hot and we arelivinng in the inside of the hollow earth

vestal briar
#

Ok

undone berry
#

That's like being rich and not picking up a £10 note on the floor it's nothing like that. If you want a bad analogy, it's like being rich and buying a coke in one shop despite the fact you could get it cheaper a few doors down

gentle moss
#

it's like being rich and buying a pepsi that costs twice as much as offbrand cola.

#

no, it's related to the discussion of the $50k mac pro

#

tbh, some industries rely on Mac

rough sapphire
#

that bullshit

gentle moss
#

and you can't get mac servers

rough sapphire
#

yeah that sucks

gentle moss
#

and hackintoshes are flaky as fuck if you need it for your business

#

there's a place for a $50k mac

rough sapphire
#

in garbage

gentle moss
#

in a perfect world that place is a bin

#

but sadly not everything runs on windows

#

¯_(ツ)_/¯

#

skimping on the ECC is a bit shitty

#

but i mean, ECC is already pretty damn expensive

#

holy shit $1.2k for 2 x 32GB DDR4 ECC

#

that should be around ~$700

tough stratus
#

Correction, you can't get modern apple servers e.e
https://en.wikipedia.org/wiki/Xserve

Xserve is a line of rack unit computers designed by Apple Inc. for use as servers. Introduced in 2002, it was Apple's first designated server hardware design since the Apple Network Server in 1996. In the meantime, ordinary Power Macintosh G3 and G4 models were rebranded as M...

#

I remember my old High School had one of these specifically for the music department's macs... god knows how old it was e.e

gentle moss
#

well technically, you can get mac "servers"

#

you're supposed to rack up a shit load of mac mini's

#

🙄

vestal briar
#

Perfection

tough stratus
#

Yikes

vapid bluff
#

is there a way to make lsof just spit out the number of processes using a file?

gentle moss
#

oh, just the count?

#

you could use wc to count the lines and subtract the headers / pointless stuff?

vapid bluff
#

for some reason im getting multiple lines for the same process

#

but im pretty sure theres only one handle

#

🤷

#

maybe im having an xy problem here though

#

basically im trying to figure out if a piece of posix shared memory is currently in use or not (and how many processes are using it)

#

so using lsof on the corresponding... file? in /dev/shm

#
admin@admin-OptiPlex-9020:/dev/shm$ lsof test_memory 
COMMAND    PID  USER   FD   TYPE DEVICE SIZE/OFF NODE NAME
python3.7 8244 admin  mem    REG   0,25       16   21 test_memory
python3.7 8244 admin    3u   REG   0,25       16   21 test_memory
python3.7 8244 admin    4u   REG   0,25       16   21 test_memory

#
import posix_ipc
import os
import time

from mmap import mmap

class Lock:
    def __init__(self, name):
        self.semaphore = posix_ipc.Semaphore(name, posix_ipc.O_CREAT, initial_value=1)

    def acquire(self):
        self.semaphore.acquire(timeout=None)

    def release(self):
        self.semaphore.release()

    def __enter__(self):
        self.acquire()
        return self

    def __exit__(self, exc_type, exc_val, exc_tb):
        self.release()


if __name__ == '__main__':
    lock = Lock('test_lock')

    with lock:
        memory = posix_ipc.SharedMemory('test_memory', posix_ipc.O_CREAT)
        os.ftruncate(memory.fd, 16)
        block = mmap(memory.fd, 16)

    while True:
        with lock:
            value = int.from_bytes(block[:], 'big')
            print(value)
            value += 1
            block[:] = value.to_bytes(16, 'big')
        time.sleep(1)
#

i understand why the mem fd is in that list

#

but no idea why there are two below

#

does mmap open another handle?

#

this whole thing is actually, surprisingly, much less headache to accomplish on windows

#

since windows refcounts mmap shared memory automatically

gentle moss
#

ahhhh

#

a unique count?

#

hang on

#

i think i can help

#

lsof test_memory | awk '!seen[$2]++' | wc -l

#

try that @vapid bluff

#

repeated PID's will be discarded by awk there

vapid bluff
#

oh cool! thanks

#

!seen[$2]++ very interesting syntax biskthink

#

hmm, seems like it's giving 1 extra

gentle moss
#

basically "if not seen in column 2 before then print"

#

yeah, that's the top line

#

column names

vapid bluff
#

ohh right right

gentle moss
#

awk is super useful

vapid bluff
#

is there a list somewhere of other similarly useful utilities?

gentle moss
#

probably

vapid bluff
#

grep is the only one im familiar with 😅

gentle moss
#

grep, egrep (uses regex), awk (it's own frigging world) are kind of the main ones

#

wc for counting stuff

#

uniq is useful for counting occurances of things

#

oh sed, too

#

allows inline replacement

vapid bluff
#

thanks, ill check those out

gentle moss
#

if you ran something like uhh

#

lsof whatever | awk -F ' ' '{print $2}' * | uniq -c

#

you'll see the count of each PID

vapid bluff
#

i see

#

do you know whether mac has /dev/shm too?

gentle moss
#

not a clue

#

i'd assume so?

#

ah, seems like you'd have to create a ram disk

vapid bluff
#

oh rip.

#

need some cross-compatible way of figuring out whether some shared memory is in use or not

#

which again, surprisingly, windows does automatically

#

then cleans it up when no longer needed

gentle moss
#

that stuff's beyond me :D

#

i just like terminals <_<

lilac glade
vapid bluff
#

including command prompt? :D

gentle moss
#

well, i'm getting better at powershell

#

but command / batch scripting is kinda basic bitch level

#

<_<

#

the school i worked at had a mac mini acting as a server for the media wing

#

that thing... the fucking worst

lilac glade
#

And so did we, until we moved onto JAMF for full management.

gentle moss
#

does JAMF integrate with AD in anyway?

#

macs in a windows environment is such a hrrrrrrrnnnnnnngggg problem

rough sapphire
#

Linus tech tips will roll out a video tommorow with 2 terabytes of RAM . test consist a tons of chrome tab consuming 60 gigs.

gentle moss
#

wow what a useful thing to do

lilac glade
#

IIRC yes.

solid pollen
#

Not sure if inshoukd continue whatching his videos

lilac glade
#

Coworkers don't really let me touch the mac server.

gentle moss
#

tbh they're so fickle it's probably for good reason

#

:D

undone berry
#

LTT is just clickbait trash

gentle moss
#

well i've seen a few that were good

#

but a broken clock blinks 12:00

gentle moss
#

fuck yeah

#

birthday dinner \o/

undone berry
#

Happy birthday

gentle moss
#

thanks, forgot i didn't mention it in here

wheat lynx
#

Happy birthday 🎉

rustic arrow
#

is that raw meat

#

hey guys

#

is it true that python can do the same thing as php and there's no point of learning php?

gentle moss
#

it was raw meat

sand goblet
#

now it's slightly less raw

gentle moss
#

:D

#

i did have it rare.

rustic arrow
#

lol

#

is it true that python can do the same thing as php and there's no point of learning php?

gentle moss
#

yeah sure why not

#

don't learn php

#

you'll save yourself infinite headaches

rough sapphire
#

oh yeah

#

i did it

#

i run rm -Rf / --no-preserve-root

gentle moss
#

now rebuild it

rough sapphire
#

nah

#

was in a vm

#

just to know what happens

gentle moss
#

did you do it as roulette?

rough sapphire
#

no

#

Should i?

gentle moss
#

[ $[ $RANDOM % 6 ] == 0 ] && rm -rf --no-preserve-root / || echo Click

#

i think my longest is in the 20's or so

#

click click click click

frosty berry
#

it's not interresting if it's not in production

#

(happy birthday!)

rough sapphire
#

happy birthday bisk

gentle moss
#

thank you thank you

#

rm roulette in production

#

oof

#

i mean i'd have little problem with it in our production

#

as i can just restore the volumes in like 2 minutes

#

and just blame amazon

rough sapphire
#

Anyone that is a software engineer and what company do you work for? Please private message me as I need some help.

terse sluice
#

@rough sapphire

granite plover
#

@gentle moss saw just now, happy birthday dude! have a nice one!

gentle moss
#

ty. it's over where i live now though

#

i am no longer celebrating

#

i've moved onto accepting how many years are between me and jurassic park

granite plover
#

hahahah 😛

#

i'll get older in 25.12 too

#

it's not nice when you past the 18's

solid pollen
#

(From the code jam 5 judging stream)

#

The last one made me laugh too much than it should

rough sapphire
#

hot ones? am I in there?

rough sapphire
#

its about to be doubled

vestal briar
#

Why 🤔

#

Oh

#

From the video

solid pollen
#

Almost 30k!

manic patio
#

When was the last time inactive discord accounts were purged? 😂

solid pollen
#

They don’t purge account I think well, they do

sand goblet
#

they do occasionally purge here

solid pollen
#

I never understood the point of purging members

sand goblet
#

makes your user counts more accurate

solid pollen
#

Hmm fair enough

sand goblet
#

I don't think that's true

#

there's an upper limit of active users before the process falls over

#

not really the same thing though

oak tangle
#

We've gotten an upgrade of the maximum simultaneous online members, since the cap used to be 5k (not sure what the default cap is these days)

sand goblet
#

that's exactly what I said, yes

#

Active users, haha

#

but pruning doesn't help with that problem much

#

since the users are already offline for a while

#

and whether you have a role

#

yeah

rough sapphire
#

Anyone used https://ifttt.com/

solid pollen
#

Used it yep

#

It is great!

sand goblet
#

yes, that is a very well known service

rough sapphire
#

should i agree ?

solid pollen
#

Of course?

rough sapphire
#

I did. I don't say weird things to my google assistant ;-;

solid pollen
#

IFTTT is used to create custom commands -_-

plucky ridge
#

IFTTT = I Filled Twenty Tuna Tubs

#

You're welcome

sand goblet
#

You're on the ball today

#

haha

rough sapphire
#

Wait google himself gives support to make custom commands ?

sand goblet
#

well no

#

you can make routines yes but they can't interact with external services

rough sapphire
#

Thats sad :C

#

IFTTT now only

plucky ridge
#

Wait. "Google himself"?

rough sapphire
#

Itself*

plucky ridge
#

Oh okay good. I thought Google became an actual being.

#

Got scared

rough sapphire
#

huhh

#

you really need some sleep , looks like

plucky ridge
#

I'm just being silly

rough sapphire
#

weirdly silly *

plucky ridge
#

This is pretty baseline for me, actually

#

As many here will attest to

royal lakeBOT
#

Yeah, Hemlock's acting pretty normal.

frosty berry
#

corporations are people too!

rough sapphire
#

Did you just echo that ?

#

Sneaky

plucky ridge
#

I plead the 5th

rough sapphire
solid pollen
#

Your baseline is to need some sleep or to be silly? 😄

plucky ridge
#

Both honestly

rough sapphire
#

@solid pollen you have experience with sql ?

#

I want a little help

solid pollen
#

Very little

rough sapphire
#

See this is a table

solid pollen
#
SELECT hemlock FROM user WHERE status is 'sleepy/silly'```Okay, I think I’m just as tired as you hemlock
#

I see it

rough sapphire
#
SELECT * FROM 'GIVEAWAY' WHERE guild_id = 579053596310765600
#

Should work right

#

it return nothing

#

WTF

#

\o/ HELP ME

terse heron
#

No quotes around the table?

#

@rough sapphire

rough sapphire
#

STILL NOTHING

#
SELECT * FROM GIVEAWAY WHERE guild_id = 579053596310765600
#

If you meant this

terse heron
#

Yea

sand goblet
#

Try quotes around the guild ID

rough sapphire
#

nothing

sand goblet
#

It might be a string

rough sapphire
#

Its INT

terse heron
#

Table is case sensitive by the way in case it’s lowercase

sand goblet
#

Surely it should be a Long?

rough sapphire
#

Does length even matter ?

plucky ridge
#

Yes.

#

But your int is large enough to accommodate it

rough sapphire
#

any reason why its not returning anything ?\

terse heron
#

Try GIVEAWAY.guild_id

#

@rough sapphire

rough sapphire
#

I dont't got how

terse heron
#

?

rough sapphire
#

LIKE ```sql
SELECT * from giveaway.guild_id is 213512616

#

?

plucky ridge
#

Nooo

rough sapphire
#
SELECT * FROM GIVEAWAY WHERE GIVEAWAY.guild_id = 579053596310765600

Both didn't worked

plucky ridge
#

Okay, just quickly

#
SELECT * FROM GIVEAWAY;```
#

Does that properly give you both rows?

rough sapphire
#

AFFIRMATIVE

#

I mean yes

#

It works with time

#
SELECT * FROM GIVEAWAY WHERE time is 20191213125058880000
coral void
#

Quote the column

#
SELECT * FROM GIVEAWAY where `guild_id` is ...
plucky ridge
#

I hate that = is equal to

coral void
#

And unfortunately backticks vs single quotes matters

plucky ridge
#

It's so counter to every other language

rough sapphire
#

NEGATIVE @coral void

#

no response

coral void
#

That is quite strange

plucky ridge
#
SELECT * FROM GIVEAWAY AS T0
WHERE T0.guild_id LIKE 579053596310765600;
coral void
#

try

SELECT `guild_id` from GIVEAWAY;
rough sapphire
#

@plucky ridge your code returned nothing

plucky ridge
#

Sounds right

rough sapphire
#

@coral void your one returned 2 rows as expected

plucky ridge
#

Okay, so it doesn't have an issue with the column name like I thought it might for some reason

#

Although...

gentle moss
#

uhh

plucky ridge
#

Hi bisk

rough sapphire
#
SELECT * from GIVEAWAY where `guild_id` is not 579053596310765600;

return 2 rows

plucky ridge
#
SELECT * FROM GIVEAWAY
WHERE `item` = 'asfa';
gentle moss
#

shouldn't be be "guild_id = <Value>"

#

not "is"

rough sapphire
#

returns 1 row

#

both works @gentle moss

#

OOPS

plucky ridge
#

Okay, I think I almost have it

solid pollen
#

almost :)

coral void
#

I can't reproduce the problem locally, which is interesting

plucky ridge
#
SELECT * FROM GIVEAWAY 
WHERE guild_id=579053596310765600;```
#

Long shot

coral void
#
>>> import sqlite3 as sq
>>> db = sq.connect(":memory:")
>>> c = db.cursor()
>>> c.execute("""
... create table GIVEAWAY (guild_id INT(50))""")
<sqlite3.Cursor object at 0x10a0701f0>
>>> c.execute("""PRAGMA table_info('GIVEAWAY')"""")
  File "<stdin>", line 1
    c.execute("""PRAGMA table_info('GIVEAWAY')"""")
                                                  ^
SyntaxError: EOL while scanning string literal
>>> c.execute("""PRAGMA table_info('GIVEAWAY')""")
<sqlite3.Cursor object at 0x10a0701f0>
>>> c.fetchall()_
  File "<stdin>", line 1
    c.fetchall()_
                ^
SyntaxError: invalid syntax
>>> c.fetchall()
[(0, 'guild_id', 'INT(50)', 0, None, 0)]
>>> c.execute("""INSERT INTO GIVEAWAY VALUES (579053596310765600)""")
<sqlite3.Cursor object at 0x10a0701f0>
>>> c.execute("""SELECT * FROM GIVEAWAY""")
<sqlite3.Cursor object at 0x10a0701f0>
>>> c.fetchall()
[(579053596310765600,)]
>>> c.execute("""SELECT * FROM GIVEAWAY WHERE guild_id = 579053596310765600""")
<sqlite3.Cursor object at 0x10a0701f0>
>>> c.fetchall()
[(579053596310765600,)]
plucky ridge
#

Have we compared the two numbers directly to make sure we're not transposing a number somewhere?

rough sapphire
#

Nothing

#

yeah thats the issue

plucky ridge
#

Wait

#

Seriously?

rough sapphire
#
INSERT INTO GIVEAWAY VALUES(124,1251515,12521512,12512512,"guns"
plucky ridge
#

Back up, so the issue was that the numbers didn't actually match?

rough sapphire
#

I can give you db file tho

royal lakeBOT
#

Hey @rough sapphire!

It looks like you tried to attach a file type that we do not allow. We currently allow the following file types: .3gp, .3g2, .avi, .bmp, .gif, .h264, .jpg, .jpeg, .m4v, .mkv, .mov, .mp4, .mpeg, .mpg, .png, .tiff, .wmv.

Feel free to ask in #community-meta if you think this is a mistake.

plucky ridge
#

!e print(579053596310765600 == 579053596310765600)

royal lakeBOT
#

@plucky ridge :white_check_mark: Your eval job has completed with return code 0.

True
plucky ridge
#

I'm at a loss then

solid pollen
#

The laziness

plucky ridge
#

Laziness my ass, I typed that out by hand

rough sapphire
#

.bm 656170394876903444 hahahahah

solid pollen
plucky ridge
#

AG, can you replicate it with channel_id or message_id?

#

I know you said time worked fine

rough sapphire
#

yes with channel_id

solid pollen
#

Can we have a new OTname laziness-my-ass pleaaasssee

sand goblet
#

My money is still on precision

rough sapphire
#
SELECT * from GIVEAWAY where message_id is 654945846944858100
plucky ridge
#

int(50) would imply that it's accurate up to 50 digits, right?

rough sapphire
#

returns NULL

sand goblet
#

well, 50 bytes

plucky ridge
#

Use = not is

rough sapphire
#

^

#
SELECT * from GIVEAWAY where message_id = 654945846944858100
#

returns NULL

plucky ridge
#

same if you do message_id in backticks?

rough sapphire
#

yes

plucky ridge
#

What in the magical hell

solid pollen
#

And with the id in backticks too

plucky ridge
#

What the number?

rough sapphire
#

like the no. ? @solid pollen

#

654945846944858100 message_id

solid pollen
#

Yep

plucky ridge
#

You wouldn't want to do it with the number

rough sapphire
#

^

solid pollen
#

The database is pretty strange, better safe than sorry

plucky ridge
#

The backtick ` is used in MySQL to delimit literals that represent identifiers (not strings). This allows you to use not usually accepted characters like spaces, reserved words, etc. as identifiers.

solid pollen
#

Oh, quotes, my bad

rough sapphire
#
Error: no such column: 654945846944858100

#

if i do backticks

#

BTW file is made with sqlite3
but manual entry works fine as it should

plucky ridge
#

Can you confirm the datatypes for each column?

#

Now I'm all curious about all this

rough sapphire
#

INT INT INT INT VARCHAR

#

item is VARCHAR OFC

plucky ridge
#

Right

rough sapphire
#

should i download a sqlite viewer , maybe website is faulty

plucky ridge
rough sapphire
#

Downloading 1 min left

solid pollen
#

Why you don't just download the sqlite engine and do queries from it?

rough sapphire
#

sqlite engine ?

#

I am using sqlite3 library tho

plucky ridge
#

Why not make queries through that then

#

Although I will say, having a browser/viewer on hand does make quick checks pretty friggin' easy

rough sapphire
#

installing BTW

#

DB BROWSER

plucky ridge
#

I think if my PyCharm Pro license ever runs out I might snag that, honestly.

#

But as it stands, Pro has a built in DB viewer that's really handy

#

Bit unwieldy but eh

sand goblet
#

Datalore, yeah

#

I like it

rough sapphire
#

That shitty installer stopped my windows explorer

#

Why is windows explorer ever do that conflicts installing

solid pollen
#

Never had any problems with it

plucky ridge
#

Happens from time to time

#

Just run the query through Python, dude

rough sapphire
#
651468912587964485
plucky ridge
#

And those guild id's are also not the same

rough sapphire
#

huhh ?

#

!e
print(651468912587964485 == 651468912587964485)

royal lakeBOT
#

Sorry, but you may only use this command within #bot-commands.

plucky ridge
#

g was right

rough sapphire
#

True

plucky ridge
#

It was a precision issue

rough sapphire
#

@sand goblet

plucky ridge
#

Compare the guild_id you have on the DB Browser to the one you had at that website

rough sapphire
#

Can you elaborate your point

plucky ridge
#

The website is rounding up to the 100's place for some reason

#

On all 3 of the id sections

#

Which explains why they all ended in 00

rough sapphire
plucky ridge
#

That's bizarre, I have never seen that

rough sapphire
#

fucking bullshit site

plucky ridge
#

@sand goblet Good call

rough sapphire
#

Now it works

#

TADAHH

sand goblet
#

\o/

#

it's always floats

#

even when it's not floats

plucky ridge
#

Just makes me wonder why the site is showing it being rounded but obviously calculating it as if it's not

sand goblet
#

floats make things sink, occasionally

#

You're probably not doing math on IDs anyway so strings are probably fine to work with

rough sapphire
#

doing same now

plucky ridge
#

True

rough sapphire
#

Am doing it with time tho

plucky ridge
#

There should be an actual date or time type, right?

sand goblet
#

Yup

rough sapphire
#

But i like this way if being honest

#
giveaway_channel = int(cur.fetchone())```