#development

1 messages · Page 13 of 1

inner wraith
#

Anything you can envision completely involving information and inputs you know the computer has and outputs you can derive from that information.

#

Be it a game, tool or whatever.

spark torrent
#

how many hours do i need to make that? or idk pong?

#

some simple thing like a box moving around, pong, snake a simple pocket calculator

inner wraith
#

Depends on if you care if the result's a mess or not lol. I liked XNA (survived by Monogame) when I started

#

But that's kinda dead now

#

You could look at Godot or Unity.

spark torrent
inner wraith
#

You start by writing shit code

#

Then you figure out enough to know why it's shit and what you should have done instead

spark torrent
#

by it not working?

inner wraith
#

That's certainly one way but really it's when you come back to the code later... do you still know what it does? Can you easily follow what it's doing? Can you modify its behavior easily?

#

...Can you test parts of it without needing to fight the rest of the program?

#

I inherited a codebase for HTML document generation for a website that had loops in loops in loops until the 4 spaces of indentation for being each one pushed it off the right side of my screen. It had values it touched that were shared by the rest of the program and could be changed anywhere, "cleverly" fixed by the former team by trying to reset or offset them. It was about 6,000 lines long.

#

Code for each document variant was copy-pasted over and over and bugfixes were applied here and there.

#

It was quicker to look at the generated document and rewrite the whole thing from scratch than figure out any of the nonsense it did.

#

End result was something like 400 lines for ~16 types of reports (though it turned out several were duplicates or near duplicates).

#

It also had a separate copy of the whole thing just for documents it'd email despite them all being the same format.

#

My favourite part of that project (node.js w/express) was that the former devs used one function per endpoint, and when they wanted to re-use code in one spot their solution was to do an API call to the other function and then parse the response it got back.

inner wraith
#

I did a cert 2 in game dev with XNA+C# and a school Python class. Both gave me a bit of confidence to do my own stuff. I spent at least as much time as I spent in classes making stuff on my own time.

#

Both had crap teachers but really just the nudge to write something was enough to get the ball rolling.

#

Made a Discord bot that did a bunch of stuff I wanted to do and learned a bunch that way

urban mulch
#

Does anyone know Flutter Animations? I'm trying to make an animation based on a slider, but if I put any other value than 0, the animation always jumps straight to the end

cloud knot
#

coder does what he knows, but doesn't think about the whole thing globally. developer does

#

i mean sure, i still have copy-paste code here and there, but it boils down to situations where when you get 2-3 very similar situations, it's ok-ish to do copy paste

#

more than that, and it might be worth creating an abstraction or parametrized function/object/template etc

#

i can see it with my coworkers sometimes how they can't be bothered to learn new stuff/figure out stuff. Like one of our coworkers upgraded to latest macOS, which meant he had to use xcode 15. compilation of the webview based iOS app broke on his combination of software, and he couldn't be bothered to figure out what was the issue. Sure, there are deadlines etc, but i just couldn't live with the "oh, it doesn't work, i will let someone else figure it out later" mentality

young plover
#

My mentor got me to rewrite a simple graphing tool three times over two weeks going from one block of code for one graph to individual files for each graph we wish to generate

#

You need to get through the bullshit to get to be a good programmer

#

Also, if you’ve got a language in mind you wish to learn, that’s great, just be aware it’s mostly the same under the hood for most languages

#

Learn the fundamentals and learning some language will be way simpler

#

Once you’re at that point it’s then the weird details of the language do you spend your time

#

Like, list of many object types in C# isn’t really a thing, ie List<int,string> for some shenanigans you want to get up to
However, you can bodge, List<(int,string)> which is specific to the weirdness of C#, or how default function means list mutation doesn’t carry through each call for default values, broke my brain when going into python

cloud knot
#

i mean List<int, string> makes sense to me, but what you wrote doesn't

young plover
#

I think the right code would be something ungodly as, List<Tuple()>

cloud knot
#

nah, just List<Tuple>. It is just a simplified way to make a POJO (plain old java object) without all the boilerplate code

charred cargo
#

am making instagram clone website,, i have done everging,, but i need whenever i reload it should load with an unique instagram style in the upper windows,,i do no how to make it

spring skiff
#

Hey all, is there anyone experienced in GNOME Extension development that can point out some docs or guides for implementing keyboard shortcuts for an extension? The only thing i've found so far is a 6 year old stackoverflow Keymanager class implementation that I'm scared of trying cause a lot can change and break in 6 years on Gnome haHAA
It doesn't need to be too dynamic or extensible, just one hardcoded shortcut with no config will do for my use case.
So if anyone has any links to stuff to read ~~even a Medium guide haHAA ~~ I'd be grateful.

empty pier
#

Life hack

young plover
drowsy elbow
#

Am I stupid? Trying to get some random project of a coworker of mine to work, but it doesnt seem to make any tables (except for __EFMigrationsHistory)

#

I'm not very familiar with EF, I used to just write my queries by hand for performance reasons

#

Hmm, guess I fixed it by deleting the migration table

#

thanks 🦆

neon oriole
# spring skiff Hey all, is there anyone experienced in GNOME Extension development that can poi...

depending , but keyboard shortcuts are not handled by gnome ,not even for extentions but by X11 or wayland respectively i think. , besides that i also dont think you can demand shortcuts to work from a client perspective , and they wil only work when the window is active and has direct access to the keyboard and other input , from the display server. now how this would work in terms of extentions i dont know , but i think you just have to register them somewhere in the gnome config files (you can browse them with gconf-editor

drowsy elbow
#

Finally 😎

inner wraith
#

Dependency hell over now

#

No more dependency hell

solemn solar
#

Is this a good place to ask for help fixing some code?

spring cradle
#

yes good place to ask for help, but a bad place to ask if you can ask for help

fading osprey
icy thunder
#

what if we ask to ask if we can ask to ask? 🙂

solemn solar
#

I've got some code here and the javascript part of it is just completely broken. I've assembled it with the help of ChatGPT so it's probably gonna have to be rewritten (It was my only option), but if there is some simple solution as to why it gives an error after pressing the button, I'd greatly appreciate it

fading osprey
#

what error does it give

solemn solar
#

Wait no that code is completely broken, this is the one that is only mostly broken. Error is this with console debugging:

Values: disp 1 Apple 0 C wip html 
Input: disp 1 Apple 0 C wip html 
Error selecting a phone. Please try again.```
fading osprey
#

your code is very truthy and expects very specific options to be selected

#

it works, it just doesnt have a suggestion for a good 70% of the combinations you could choose

solemn solar
#

I see, so it only works if that hyperspecific combination is selected?

fading osprey
#
[
    { preference: 'Apple', budget: '9', phone: "iPhone 15" },
    { preference: 'Apple', budget: '10', phone: "iPhone 15 Pro" },
    { preference: 'Apple', budget: '11', phone: "iPhone 15 Pro Max" },
    { budget: '1', phone: "Redmi 10C" },
    { budget: '2', phone: "Redmi Note 13" },
    { budget: '3', phone: "Redmi Note 13 Pro+" },
    { budget: '4', phone: "Poco F5" },
    { budget: '5', phone: "Poco F5 Pro" },
    { preference: 'perf', budget: '6', phone: "Poco F5 Pro" },
    { preference: 'cam', budget: '6', phone: "Xiaomi 13T" },
    { preference: 'disp', budget: '6', phone: "Xiaomi 13T" },
    { preference: 'bat', budget: '6', phone: "Xiaomi 13T" },
    { preference: 'over', budget: '6', phone: "Xiaomi 13T" },    
    { preference: 'perf', budget: '7', phone: "Poco F5 Pro" },
    { preference: 'cam', budget: '7', phone: "Xiaomi 13T" },
    { preference: 'disp', budget: '7', phone: "Xiaomi 13T" },
    { preference: 'bat', budget: '7', phone: "Xiaomi 13T" },
    { preference: 'over', budget: '7', phone: "Xiaomi 13T" },
    { budget: '8', phone: "Xiaomi 13T Pro" },
    { budget: '9', phone: "Xiaomi 14" },
    { budget: '10', phone: "Xiaomi 14 Pro" },
    { budget: '11', phone: "Xiaomi 14 Ultra" },
  ]

this is your phone selection ^^

if the phone hasn't got a preference tied to it, it cannot be selected based on your logic. So if I were to select a budget of 800-900 EUR and a preference of "performance", there wouldn't be anything to match against, since nothing fits those requirements, (even if the Xiaomi 13T Pro matches the price, it has no performance preference and wouldn't work) so your code would simply log "Error selecting a phone. Please try again." instead of choosing the phone that matches the closest

solemn solar
#

Ah, I see the issue. Is there a simple solution to make it accept the closest one?

fading osprey
#

"simple", not that i can see off the top of my head, you could probably come up with one given time, but I unfortunately do not have that luxury right now, if someone else has any suggestions then please feel free to pop up and get involved 🙂

solemn solar
#

I see. I guess my only option is to reduce the number of variables and just type out each one by hand for now

woeful rapids
#

so i wanted to make a custom 2230 M.2 card, but i don't have any ideas as to what purpose it should serve

inner wraith
#

SSD's are often key M or B, WiFi cards are key E or A+E.

#

Or soldered, just to piss me off.

woeful rapids
#

it has USB, UART, I2C, SDIO etc etc

#

I'm not at the PCIe level yet

woeful rapids
#

which wouldn't be that bad of an idea

#

something nice would be embedding a full RTL-SDR into my laptop, as it has a plastic shell

#

but designing a PCB like that is a bit too complex for me

woeful rapids
#

6 antennas M.2 sure is funky to look at

marsh star
#

what file format are game maps usually in? i.e. Call of Duty, Valorant, or Apex Legends maps

woeful rapids
#

making progress, learning kicad

cursive grotto
#

can anyone help me with this problem?

#

so i have an unresolved external symbol error in my code in VS. The problem is i have one project platformer that references another project shadow (the engine) and i have moved the main function of platformer to shadow using an entrypoint.h file which is included in shadow.h along with other includes. then shadow.h is included in platformer.cpp. now entry point looks like this:

#pragma once
#include <iostream>
#ifdef SHADOW_PLATFORM_WINDOWS
//extern Shadow::Application* Shadow::CreateApplication();
extern int var;
int main(int argc, char** argv) {
//    auto app = Shadow::CreateApplication();
//    app->run();
//    delete app;
    std::cout << "var: " << var;
}
#endif
``` and platformer.cpp is ```
#include "Shadow.h"
class Game : public Shadow::Application
{
public:
    Game() {
    }
    ~Game() {
    }
};
int var = 100;
Shadow::Application* Shadow::CreateApplication() {
    return new Game();
}``` i get a lnk 2001 and lnk1120 error regarding var (shadow outputs a dll)
#

i am following the cherno's game engine series as a tutorial for this and his code doesn't return any error

woeful rapids
#

alright it's done

#

i'll make a 2242 version as well, since it's super simple

woeful rapids
#

done

neon oriole
# woeful rapids making progress, learning kicad

not really a mechanical cad person (i can only do electronic schematics and pcb layout/routing) however ive come to like openscad allot for doing 3 model drawing as it does not really require much CAD knowledge and its really easy to do iterations of the same thing in (just change some parameters in a loop eg)

woeful rapids
#

oh yeahh i've used OpenSCAD

#

i'm not making a 3D model

#

like i'm making a real PCB

neon oriole
#

ah 🙂 the 3d image is just a mockup for doing the routing on or ?

#

(assuming you mean you are making a pcb to be made, not actually making the pcb itself , (meaning cutting out the plastic , putting a copper layer on it , puthing light sensitive coating on top of that , then ...) :d

woeful rapids
#

yeah im not milling the pcb myself ahahah

acoustic pine
#

working on my algorithm skills
any advice to improve it?
this a simple program to find nth number of prime, implementing Sieve of Eratosthenes.

#

though the sieve algorithm gets slower with large number and i'm wondering if there are better ones

agile coral
nocturne galleon
#

CommercialScript BT is the best IDE font

solemn solar
#

I regret eyesight

fading osprey
#

I've never wanted to commit manslaughter more

cloud knot
#

(that's Hello World in a language which name would get me muted 😄 )

hollow basalt
#

brainfuck

acoustic pine
cloud knot
hollow basalt
cloud knot
#

i am out of my rebelius phase 😄

hollow basalt
solemn solar
#

I've got an issue, the image only expands within the bounds of the container and I've tried many times but there's no way to expand the thumbnail container (The image that hovers container) without screwing other stuff up
If possible, I'd like for it to expand in all directions and when you hover over the link text it wouldn't unexpand.
HTML, CSS, & JS files attached below

acoustic pine
#

the image should expand without being cut by parent container

solemn solar
#

Yep that fixed that part, how would I make it so that the container is only as wide as the image is?

acoustic pine
#

i'll try to see a solution

#

though that aside
this is missing a closing div

solemn solar
#

Yeah that happened while I was copying over code, thanks for pointing it out

spring cradle
#

how would i figure out what is wrong with my spi device?

quiet nest
#

Hmm... This is something I actually didn't know about.
https://www.youtube.com/watch?v=ZMzdrEYKyFQ

You've heard of structures, you've heard of functions, maybe you've even heard of the C preprocessor. But, have you heard of unions? Unions are a weird type in C that don't get a lot of love. In this video we'll discuss what a union is, how unions work in memory, and wether or not you should use unions.

🏫 COURSES 🏫 Check out my new courses at h...

▶ Play video
prime rampart
neon oriole
# solemn solar I've got an issue, the image only expands within the bounds of the container and...

while i must admit that the div era was i pretty easy era to be making websites, everything was a div,.. unfortunatly html5 has allot more stuff to remember and know the right usecases for. however it makes the code allot more readable and many bring their own niceties, like this <details>+summary setup i use as my email footer(collapsible with just html)... and not defaulting to a div for everything might have its advantages... so i would suggest , maybe looking into the following html5 tags : <figure><figcaption>section> , <label> (also used for toggle/ sliders/checkboxes eg, there are quite allot) and maybe a little petpieve of mine but you might also want to consider moving logo's and images that are part of the site's design to the css of the page leaving only the actual content and the sturcture as the html 🙂

solemn solar
#

I should, any solution you found for the sizing? I plan on cleaning code up when I feel like it

restive ore
#

am i crazy or did chrome remove the ability to check cookie values!?

#

i literally remember doing this last semester to check if stuff is working and now i cannot

hollow basalt
#

You cannot

polar moth
#

I have an esp8266 node MCU and I want to run a graphic test on 1.8TFT SPI 128x160 v1.1.....can someone provide me the code to do so????

iron forge
neon oriole
#

you know what is really fun, fixing the tui of a terminal loadmeasuring app , that just printed lines to the terminal , and while doing that you notice that the values being printed in your improved version make no sense ,... but why, then you find out the original also had values that make no sense but due to the character forrest that it printed it was not so obvious,... so i dug deeper and found : lol ```ahk
// TODO:
// * we need to do some real tests & math here to have accurate values.. !

arctic lantern
#

been trying to get c working on pico
gave up
realized im trans
moved to rust
😎

neon oriole
#

doesnt rust also depend on a runtime ? 😄

#

i mean i think it even links in the C runtime so 😄

arctic lantern
#

ye but rust is working unlike c soooooooo

#

idc it works lol

spring cradle
#

use circuitpython ;P

arctic lantern
#

alreddy have
got issues with http request eventualy crashing pico
too meny but carnt be helped

spring cradle
#

fair

arctic lantern
#

i would so use it if not for that one small problem

umbral saffron
#

so i’m trying to pulse an led every time i receive a specific input, but i rarely actually deal with coding so idk what i’m doing. can someone help me figure out what to do? this is for arduino btw

pliant ether
finite meteor
#

What’s the best language for game development?

#

It would be a multiplayer open world kind of game idea.

fading osprey
#

C# or C++

Unity uses the former and Unreal uses the latter

finite meteor
fading osprey
#

I wish I could tell you, but that is a decision you will have to come to based on research and a better understanding of your own goals for the project

finite meteor
#

Alright, thanks for the assistance.

hybrid citrus
# finite meteor It would be a multiplayer open world kind of game idea.

that’s seems like a pretty big project for a first game! It could take you very long if you don’t have experience and you might burn out, ESPECIALLY as a beginner solo dev. Maybe you could make a little prototype (with basic features) in either of the engines, then see how you feel about it. If something feels wrong, maybe try the other engine.

Unity has a bit of drama because of the company behind it but I have had a positive experience with actually working with the engine. Though, keep in mind I’ve never used Unreal, so I wouldn’t know if it’s better. And, of course yeah you should also do your own research

finite meteor
solemn solar
#

Any idea how I could take the new, more detailed dark mode light mode toggle and make it fit within the bounds of the navbar? I don't know if it's even possible with how intricate the design is so I'm fine with just expanding the navbar to accomodate the bigger toggle

neon oriole
#

Not really a how-to of game dev but def some best practices https://youtu.be/OtozASk68Os?si=k5Qm7hP9vDj1CInX

nova coral
finite meteor
#

What language does unity use?

fading osprey
#

C#

hollow basalt
#

JS

inner wraith
# finite meteor What language does unity use?

C#. It has supported other options from time to time but they're all gone by now. Being .NET you can still bring stuff in written in other .NET languages or even other languages but your project will start in C#.

worn wind
#

hi folks where can i sak questions here?

solemn solar
#

I'm gonna do what was done to me

hollow basalt
glass vessel
frozen flame
#

That doesn't matter

silent moon
#

Beginner web developer here!
I just designed a sign up form within like 4 hours (?) and would like know if there could be any improvements to it

solemn solar
#

That looks great!
Does the mountain have any specific association with the site? I would suggest putting a gradient left to right in the same blue as you used for the background and yellow accents for the boxes, it might look quite nice, but that's just my opinion

silent moon
neon oriole
# silent moon Beginner web developer here! I just designed a sign up form within like 4 hours ...

while it looks good, you should check your source with a browser sometime, i mean not the right button view source , but the F12 way (so what the dom made of your code) especially look at what it did to the <head> tags... ill help a little , note that if you break html rules , the browser tries to fix it and you shouldnt rely on that.
<header> is not allowed within the <head> tag so the browser auto closes the </head> above it ,leaves your </head> as a stray one

solemn solar
#

And also rounded corners for better consistency of the site

#

Now in this case, emphasis falls from the text onto the image, so if the image is something very impactful and relevant, this helps push that even further.
If the discover text is the priority, this kinda falls apart

neon oriole
solemn solar
#

Sorry I'm quite new to this whole thing, what are alpha backgrounds?

neon oriole
#

ps aside from the <header> inside the head tag, im actually amazed by the correct use of allot of the tags, (compared to what them js-junkies churn out these days , <h> tags inside of <p> tags , or nested <p> tags, eg all things the browser have to correct for , and then when their layout does not work in one situation ,they dump a load of js on top to fix the stuff... whil all they had to realize is that p.content p.intro {} wont ever work since there cant be a p tag inside a ptag 😄

#

ow and also maybe , you dont have to give everything a class , since tags are essentially there own class anyway , so if there is only one nav , you can just make the css apply to the element and work down from there nav ul {} and nav ul li{} and nav ul li a{} nav ul li a:hover {} and if there were 2 navbars , you can so the css that they share in the same way and if one is on the top of the page and the other on the bottom you can #navbar-top and use <nav id="navbar-top">

solemn solar
neon oriole
#

and this : ```css
*{
margin: 0;
padding: 0;
box-sizing: border-box;
color: #000000;
font-family: 'Inter Tight', sans-serif;
}

#

instead of setting : css background-color: #RRGGBB; you can also set it like this: ```css
background-color: rgba(0,0,128,0.5);

#

ah you already did that , couldnt see it on the little image

solemn solar
#

Yeah I did it on ~0.8

neon oriole
#

ps you can also put the Name , email and such texts , within the input like : ```html
<input type="email" name="email" id="email" placeholder="john.doe@domain.com" ...>

#

setting the type to email , is nice for people who like to use autofill 🙂 and it will recject things that arent email by default

solemn solar
#

Ironically dashlane detected the email field as email and the name last name fields for identity, but changing it fixed the password, so yeah, definitely recommend you do that

timber stag
#

My winter vacation just begun and i really want to get into programming where should i start

solemn solar
#

What are you programming

timber stag
#

Nothing

#

I wanna start learning it

solemn solar
#

I've started with some basic site designing with HTML, CSS, and JS and I find it quite easy, but it depends on what you actually wanna do

neon oriole
#

i honestly could not say what the best lang is to start with,... here is the dillemma: if you start with any lang but C, you will miss the basics of C down the line. But C is prolly not the best language to start with in terms of staying motivated as it will take a while before you can program anything actually usefull in C, and you dont really need to be an expert C programmer , only understanding its basics will do but how does one learn a lang just for understanding the basics, only thing i could say for sure is , stay away from javascript,java and (visual) Basic as a first language, overcoming them will be a pain later on...

#

btw, while i have no experience with it , the things i hear about GO , would make it a good starting language i guess

timber stag
#

So i really dont know about any lang to be specific

timber stag
neon oriole
#

also for knowing memory on the heap , and on the stack, , how a stack works,... and manually freeing memory (because no garbage collector in C) , go is somewhat similar but easier and quicker to get things of the ground so it seems https://www.youtube.com/watch?v=446E-r0rXHI vs https://www.youtube.com/watch?v=U3aXWizDbQ4

Learn the basics of the Go Programming Language. Go (not Golang) was developed at Google as a modern version of C for high-performance server-side applications. https://fireship.io/lessons/learn-go-in-100-lines/

#programming #go #100SecondsOfCode

🔗 Resources

Go in 100 Lines https://fireship.io/lessons/learn-go-in-100-lines/
Go Docs https://go...

▶ Play video

The C Programming Language is quite possibly the most influential language of all time. It powers OS kernels like Linux, Windows, and Mac and many other low-level systems. Its syntax has inspired many other languages, including Cpp, Csharp, Java, JavaScript, Go, Perl, and more.

#programming #compsci #100SecondsOfCode

🔗 Resources

C Manuel h...

▶ Play video
timber stag
#

Can i become a expert if i spend 10000 hrs on a particular subject

solemn solar
#

I mean depends, I have been alive for 142368 hours but I'm not particularly good at living
Question is do you spend that time wisely or do you repeat the same thing and never try anything new

stiff furnace
#

What’s the best GPU under 700 for cuda ai software?

rapid delta
nocturne galleon
#

Does anyone join a fan project.

They Tryna restore online functionality in a ps2 game

#

And a bunch of other things like custom new content but mostly restoring the online service

#

The game is called test drive unlimited and it ran it's servers on quzal

red mulch
vapid sentinel
inner wraith
drowsy pelican
graceful drift
#

can someone help me i loaded a file by accident and i get this now from google dev console

silk eagle
#

whats the problem

cerulean path
#

Do we have an LTT AOC leaderboard?

nocturne galleon
#

How are custom mod tools created for games that didn't release their SDK or don't even have an Open engine (like unreal engine etc)

#

People that got stuff like model editors etc to GTA 5 are fr based

uneven owl
#

Hey, does anyone over here have experience with Azure Streaming Analytics? We're running into this error when using the Sample Data function.

The streaming analytics job works fine, just a weird error I noticed.

hallow wing
#

So when you build an app for something like PS4 or PS5. are those more closely related to an android app, or something? are they their own animal? Are there tools to help port over apps from other platforms? I'm entirely clueless in how different that platform is from others. Curious how systems like PS5/xbox/roku stack up against Andoid/IOS

neon oriole
#

latest consoles are closer to a pc then to an mobile platform , in terms of hardware and how to develop for them,...

#

ps3 would be an entire different animal (but it could run linux if you had the original launch version) but it did not ran on any conventional cpu platform instead it ran on the much overpowerd ibm/sony/tocshiba cell cpu's 🙂

neon oriole
#

sometimes i feel like docs are talking to me personally 😄

solemn solar
#

I do not understand why on earth that offer doesn't center to the left and I don't wanna change the global settings for it cause that comes with its own issues, any advice?

neon oriole
#

just a dumb questions but how many offertext and offertitles does your site expect to have ? (of only those ... why a class? remember a class is like a group of something sharing the same propreties))

#

then <title> </title> should be inside your <head> tags

#

specifying lang="en" once should be enough

solemn solar
#

Only that one twice for two pages
I also prefer classes for now, I've tried the html 5 tags and they don't feel too different

neon oriole
#

and you can use a <ol><li>... for the offertext div actually , 🙂

#

saves you the <br /> s at the end

solemn solar
#

Fair point
Main concern for me rn is the positioning to the left and I've no clue how to do that

neon oriole
#

by center to the left you mean allign to the left , or do you mean vertical center , but horizontal alligned left

solemn solar
#

Yeah left horizontally

neon oriole
#
/* Global presets for all elements unless specified otherwise */
body {
    margin: 20px; 
    padding-top: 80px; 
    display: flex; /*Enables flex layout, allowing for more complex designs without effort*/
    justify-content: left; /*nters elements*/
    height: 125vh; /*Makes the height of the site 125% of the vertical height*/
    font-family: Helvetica; /*Changes font to Helvetica*/ /*fuck you ruta*/
    background-color: var(--bg-color); /*Makes it so that the colour of the background varies based on what the toggle for dark mode/light mode is*/
    color: var(--font-color); /*Makes it so that the colour of the text varies based on what the toggle for dark mode
``` if you set justify-content , to center , then the contents of the body will be centered, so if you put it to justify left you have it justify to the left side of the window
#

a

solemn solar
#

I'll check if that breaks any content in other parts of the site

covert saddle
neon oriole
#

Lol pure html css and js Startpage .. what else is there ?Java and flash applets ?

void pagoda
solemn solar
#

I've got some issues regarding my Javascript. The icons don't update correctly. Here's a sample html, css, and js file for your convenience
Anyone got any ideas on how I could fix this? I don't do any javascript and ChatGPT really isn't helping that much here

hearty coyote
#

I'm looking for a laptop to make 3D godot games with and do some light gaming, my games will never need a super high intensity laptop
any good recommendations
I need it for probably 4-5 years

neon oriole
#

probably not much help here for that , all i can tell is that if i were to program on a laptop , id attach 2 24" monitors to it at the verryleast allong with a mechanical keyboard , and that laptop would spend its time closed under one of the screens or so. and i dont do 3d game programming where i prolly would want even one more screen to see whats happening in the render...

woeful rapids
#

submitted my first patch to ffmpeg

#

hopefully i did everything right and won't get yelled at

fading osprey
#

It's open source, someone will find a way to yell at you for something, but congrats!

woeful rapids
#

i did not, in fact do everything right

#

i had to resend 🫨

#

but now its all good

#

i never really sent an email before

raven nacelle
#

anyone here coding on mac?

frozen flame
#

plenty of people do that

round crypt
#

Preferred method honestly, but only one employer I have had has wanted to foot the bill for one for me.

raven pine
#

If I made a noise suppression software which worked by using voice recognition to block all sound not identified by the voice recognizer, would anyone use it?

silk eagle
#

I think there are already a few options out there but if it was open source with enough contribution it could definitely find a lot of users

solemn solar
steel nova
#

Hey new to the discord thread. I have a weird question regarding programming and hardware setup. Is this the best place to ask?

solemn solar
#

oh boy time to do the fun thing again

olive oriole
solemn solar
#

?

olive oriole
#

how did you make the link like that

solemn solar
#

Ah, it's quite simple actually

olive oriole
#

thats cool ngl

solemn solar
#

[text] (link) (Without spaces)

#

Specifically has to be an https:// start otherwise the hyperlink won't work

olive oriole
#

cough

#

neat

solemn solar
#

Yeah it's quite cool, it's the universal formatting for that if a text editor doesn't have a preset for it like reddit does, you can theoretically put this anywhere that supports hyperlinks

hollow fable
#

Does anyone use the free cloudflare plan for their wordpress site?

bright cedar
solemn solar
#

That's true, be careful with hyperlinks

fading osprey
#

lucky for you, clicking on any link in Discord opens a popup, just never check the box and you will always be prompted to confirm first, which makes this less of an issue if users actually pay attention to the ocntent of the box, which they should be doing anyway

solemn solar
#

See I just trust whatever I see blindly and click whatever I want because no one would be so rude as to potentially do harm to my information or property, it never happens!

mental panther
neon oriole
acoustic pine
#

Made a little project, basic calculator
you've seen it thousand times prob lel
i need tips on making it cleaner. It's quite rough, i'm still a huge newbie at this ehe.

#

cleaner code not cleaner gui

neon oriole
#

dumb question here (to think about) , but doing math is usually a pretty procedural experience , ... why make it part of a class ?

neon oriole
#
import tkinter as tk

def digit(number):
    current = disp_in.get()
    new = current + number
    disp_in.set(new)


def operator(symbol):
    disp_out.set(disp_in.get() + symbol)
    disp_in.set("")


def solve(*a):
    current = disp_out.get() + disp_in.get()
    disp_out.set(eval(current))
    disp_in.set("")


def clear(*a):
    disp_out.set("")
    disp_in.set("")


def Run(text, function):
    def run():
        function(text)
    
    return run

#Create tkinter root
root =  tk.Tk()
root.geometry("300x200")
root.title("Calculator")

#Create display section
disp_in,disp_out = tk.StringVar(), tk.StringVar()
disp_in.set("")
disp_out.set("")
headerTitle = tk.Label(root, text="Calculator", font=(16)).pack()
calculatorDisplay = tk.Entry(root, state="readonly", textvariable=disp_out, justify="right").pack(fill="x")
calculatorEntry = tk.Entry(root, state="readonly", textvariable=disp_in, justify="right").pack(fill="x")
buffer = tk.Frame(root).pack(pady=10)

#Configure inputContainer
inputContainer = tk.Frame(root)
for i in range(4):
    inputContainer.columnconfigure(i, weight=1)
inputContainer.pack(fill="x")

#Inputs
buttons = [("1", 0, 0,digit), ("2", 0, 1,digit), ("3", 0, 2,digit), ("+", 0, 3,operator),
           ("4", 1, 0,digit), ("5", 1, 1,digit), ("6", 1, 2,digit), ("/", 1, 3,operator),
           ("7", 2, 0,digit), ("8", 2, 1,digit), ("9", 2, 2,digit), ("-", 2, 3,operator),
           ("CE", 3, 0,clear), ("0", 3, 1,digit), ("=", 3, 2,solve), ("*", 3, 3,operator)]
for text, row, column,function in buttons:
    tk.Button(inputContainer, text=text, command=Run(text,function)).grid(row=row, column=column, sticky=tk.W+tk.E)

root.mainloop()
acoustic pine
#

like i input 36, then + then 52, then + again it resets

nimble shore
#

how can I collect and combine multiple xhr data packages into one video
I tried downloading a couple of them using a script that I made but the video was choppy and some of sections in the combined clip is missing
I also have m3u8 url

acoustic pine
#

pressing + again after should produce this

neon oriole
#
import tkinter as tk

def digit(number):
    current = disp_in.get()
    new = current + number
    disp_in.set(new)


def operator(symbol):
    current = disp_out.get()
    if current:
        solve()
        disp_out.set(disp_out.get()+ symbol)
    else:
        disp_out.set(disp_in.get() + symbol)
        disp_in.set("")


def solve(*a):
    current = disp_out.get() + disp_in.get()
    disp_out.set(eval(current))
    disp_in.set("")


def clear(*a):
    disp_out.set("")
    disp_in.set("")


def Run(text, function):
    def run():
        function(text)
    
    return run

#Create tkinter root
root =  tk.Tk()
root.geometry("300x200")
root.title("Calculator")

#Create display section
disp_in,disp_out = tk.StringVar(), tk.StringVar()
disp_in.set("")
disp_out.set("")
headerTitle = tk.Label(root, text="Calculator", font=(16)).pack()
calculatorDisplay = tk.Entry(root, state="readonly", textvariable=disp_out, justify="right").pack(fill="x")
calculatorEntry = tk.Entry(root, state="readonly", textvariable=disp_in, justify="right").pack(fill="x")
buffer = tk.Frame(root).pack(pady=10)

#Configure inputContainer
inputContainer = tk.Frame(root)
for i in range(4):
    inputContainer.columnconfigure(i, weight=1)
inputContainer.pack(fill="x")

#Inputs
buttons = [("1", 0, 0,digit), ("2", 0, 1,digit), ("3", 0, 2,digit), ("+", 0, 3,operator),
           ("4", 1, 0,digit), ("5", 1, 1,digit), ("6", 1, 2,digit), ("/", 1, 3,operator),
           ("7", 2, 0,digit), ("8", 2, 1,digit), ("9", 2, 2,digit), ("-", 2, 3,operator),
           ("CE", 3, 0,clear), ("0", 3, 1,digit), ("=", 3, 2,solve), ("*", 3, 3,operator)]
for text, row, column,function in buttons:
    tk.Button(inputContainer, text=text, command=Run(text,function)).grid(row=row, column=column, sticky=tk.W+tk.E)

root.mainloop()
``` solved
acoustic pine
#

yep that works now

#

another bug, after pressing equals button and then doing another operation

neon oriole
#

i was tought that a class is like a factory for objects of the same "sort", and that if there is only gonna be 1 object made of that sort , it probably doesnt need to be a class...

acoustic pine
neon oriole
#

and about the bug do you mean that it is possible to do another operation , and you dont want it to , because doing another operation after equals seems to work here

acoustic pine
#

i press equal i get result

#

intended: i press another input, it clears display

#

i press equal i get result

#

bug: i type 9 and then plus and it becomes this

neon oriole
#

ah i see what you mean

acoustic pine
#

though this part is godsend
i can make use of this

#

gonna make it there be less if-else shit

nocturne galleon
#

does anyone know to change to the second demision after i input my first demisional value, ping with any answer please

nocturne galleon
#

dumper and bypass is the same thing?

solemn solar
#

Idk what that software is but I would assume double clicking would allow you to

mental panther
#

that's fusion 360

mental panther
vernal marsh
#

Hi, so I am trying to store multiple numeric datatypes in a single uint_8 array... something like this

// ....
  std::array<std::span<uint8_t>, G.graph_data_size> data_spans;
  std::array<manifold::d_type, G.graph_data_size> data_types;

private:
  std::vector<uint8_t> data;
  manifold::CompactStaticGraph<__COMPACT_TEMP_PARAMS> _graph;

Where data is stored in data vector which is almost never used directly, all it does is to store the data. data_spans contains the spans for each array of type in data_types in the graph.

This is probably not the best way to store them. Spans can be replaced by c style pointers which are easier to typecast not requiring bunch of reinterpret casts of ref. But Is there a better way to store this kind of structure not using hash maps.

PS. I do want to note that I know all the datatypes arrays being used during costexpr time, I was considering doing an array for each data type by using std conditional but that seemed overly complicated.

blazing sundial
#

Queue<Float> nums = new PriorityQueue<Float>();

nums.offer(97.79f);
nums.offer(86.00f);
nums.offer(99.93f);
nums.offer(45.40f);

for (float i : nums) System.out.println(i);

Why am I getting the output:
45.4
86.0
99.93
97.79

#

ain no way 99.93 is greater than 97.79

rotund zinc
#

I have an idea

solemn solar
#

I forget who doesn't like divs here but I'm gonna give them a heart attack.
It's all divs.
Enjoy

rotund zinc
# rotund zinc I have an idea

Here is some context, I will be making a web app + free API that archives every single drop. It will be open-source and made in the Sweet Laravel stack (Splade, Laravel, Vue, Tailwind CSS). If you would like to help out, development, suggestion or help filling the archive, feel free to ping me here or DM me. I am working on making an email (something like linusisveryshortandhedropsstuff@dropdb.tech). I'm gonna try to finish it all by christmas, development starts today linusSmirk

#

It has begun.

fading osprey
#

Congratulations, you've joined the group of us archiving all the things

solemn solar
#

What's it gonna be archiving exactly

mental panther
#

going to guess clips of linus dropping things

solemn solar
#

Lmao I'm down to help

rotund zinc
#

I'm thinking it's like a YouTube embed with a timestamp, I'm not sure how to handle stuff on FP Exclusives, maybe an uploaded clip on yt. I'll email something at LMG to make sure my ass isn't gonna be grass

#

It'll have filtering which is gonna be essential (host, date, channel, etc)

#

I'm even down for a ranking system, but then I'd probably need a login/account system, it's easy but idk if people would be comfortable with logging using Discord

#

One more note to myself, "Impact Rating", like how hard was it dropped. Maybe the lowest option could be "Linus-sized Impact"

#

also just so were all clear im not intending to make $ on this, just a fun project, because i dont think lmg would be ok with a "donate" button

fading osprey
solemn solar
#

It would also just be very unethical to reupload FP Exclusives

rotund zinc
#

Yep agreed, cheers on the reply

#

Does FP have a way to link to a timestamp?

fading osprey
#

Additionally, I am allowed a donate button, and I have some other stuff I've cleared with LMG, but donations are not a thing they generally take issue with

fading osprey
rotund zinc
#

Oh my God I am slow as balls, you're the guy that made WanDB?

fading osprey
#

Lol, yeah that's me, it's a work in progress and very broken, but that's me

rotund zinc
fading osprey
#

But yeah, if you've got any questions, feel free to DM me, I'm on holiday this weekend but I'll reply as and when I check my phone/have an answer 🙂

rotund zinc
#

Thanks for your help GeoWarmSmile

solemn solar
#

I can theoretically help with the most baseline code possible but I suck at anything other than basic CSS and HTML

rotund zinc
#

Also I'll add a suggestion box so taht anyone can suggest a "drop", bcs going through a lot of videos is gonna be cbt

rotund zinc
fading osprey
rotund zinc
#

I'll self host it in my own room

solemn solar
#

I'm down to do whatever since it's a cool project

#

Oh yea regarding hosting I don't know if it's any good but I heard good stuff about Vercel and all it needs is a gitlab/github account and a domain

fading osprey
rotund zinc
#

I'm kinda doing this to take a break from all the "serious" projects and more to do something on the side. I've been working on a "facebook marketplace" sort-of project for the 🇧🇦 bosnian market, since our (defo not monopolistic) only website has shat itself OMEGALUL

fading osprey
#

@harsh kindle will also sing the praise of Cloudflare until the cows come home

rotund zinc
fading osprey
rotund zinc
#

Hey if it pays the bills I ain't complaining

#

It's getting me thru cooleg + new pc soon

fading osprey
#

For WanDB
Svelte, Postgres, Node, Bun, hell, even Rust on some modules

rotund zinc
#

Svelte my beloved

fading osprey
#

Anyway, my trainll be here soon, later folks, remember my dms are open if you have any questions, good luck and godspeed

rotund zinc
#

Thanks for the help man frankpog

solemn solar
#

I'm here to help if you need coding and no one else can

rotund zinc
#

I'm gonna die but it'll be a fun challenge, functional version by thursday next week darkThumbsUp

solemn solar
#

Nice, that sounds like a very hard deadline, you got a team already?

rotund zinc
#

solo

#

I'll be doing development solo but everyone is welcome to give ideas, comments or to work on the project, it'll be open sauce

solemn solar
#

You know coding well enough for a site?

rotund zinc
#

Yep, I've got 2.5+ years of experience

solemn solar
#

Okay good, I'm no longer concerned

rotund zinc
#

LaylaHeart_Drunqyas dw

rotund zinc
#

:p experimenting

solemn solar
#

Damn looks sick

rotund zinc
#

update

solemn solar
#

I love the UI

rotund zinc
#

the logo needs more flare, rather than just being a typography logo

solemn solar
#

Idk I like it

rotund zinc
#

oke now that we have a baseline design

#

time to start work on the backend darkThumbsUp

harsh kindle
#

They’re really only started their hosting stuff the past few years and there has definitely been some growing pains 😄
But most of the few nitpicks I have are about the dashboard. The actual service is great

rotund zinc
#

(futureproofing) but should i make it so that only one person can theoretically be counted as "having dropped the thing" or it is possible for more people to have dropped it?

#

frick it i am gonna add list of additional people in the clip

harsh kindle
#

I didnt know this channel existed until @fading osprey pinged me here 😄

solemn solar
#

I need some advice, should I use em, px, or dv(w/h) for my font sizes and other layout stuff?
Also, how would I go about making a site that actually looks right not just on 16:9 displays but also on vertical and stuff like that

rotund zinc
#

Make your own "design system". I use Tailwind CSS and 95% of the measurements are in rem and I'd recommend you look at their documentation so you can get the general idea.

solemn solar
#

I see.
Also I've heard good stuff about alternatives of CSS like Tailwind or SCSS, is there anything they do better?

fading osprey
#

SCSS is a "superset" of CSS, eg it adds new syntax, tailwind is just thousands of regular css classes that are generated at build time based on your code

solemn solar
#

Is there any point in using them if I already know CSS to some extent?

fading osprey
#

Any point? That's entirely down to you and your use case

#

Tailwind is a helpful library for experimenting, but I personally dislike it quite a lot and am actively moving away from it in my projects where I can easily do so.

SCSS has some really cool features which are still lacking from the CSS spec as far as I know, but I couldn't tell you what they are since I don't use it

#

Also SCSS is CSS Syntax but with extra functionality and some additional syntax to make it work, if you know CSS you know SCSS, sort of

solemn solar
#

I see. Thanks for the info, I'll stick to basic for now

round trail
#

is anyone good with inventor? I need some help.

peak acorn
#

tailwind is godlike compared to writing regular css

#

much faster and readable (usually)

fading osprey
#

Tailwind is godlike if you don't care about reading your code ever again. Too much granularity with not enough actual ability to control things leads to an inevitable waste of bytes, and failure of efficiency

#

It is a great way to avoid actually learning how to use CSS, but when you really need fine control, it loses the ease it claims and becomes a hindrance over a help

peak acorn
#

flex-col flex-shrink-0 w-full overflow-hidden text-sm grow-0
beats

  flex-direction: column;
  flex-shrink: 0;
  width: 100%;
  overflow: hidden;
  font-size: 0.875rem;
  line-height: 1.25rem;
  flex-grow: 0;

any day

solemn solar
#

I'd say it depends

#

Like I perfectly understand everything with the code line outside of flex shrink and flex grow, but I understand absolutely nothing with the tailwind (I assume?) line

peak acorn
#

Lets just call it preference then

#

fyi you can always hover over a classname in vscode and it tells you the css

fading osprey
#

It is very much just preferences though love it or hate it it seems to be a preference bell curve of "hate it" -> "love it" -> "hate it" again

peak acorn
#

Damn i can NOT get this 'pibaker' software working

#

trying to use it to create an image that i can deploy onto RPIs without actually booting onto them to make the configurations

woeful rapids
#

oh god the patch i sent to ffmpeg has a spelling mistake

#

im so embarassing

midnight wind
harsh kindle
#

Don’t ask to ask, just ask 🙂

woeful rapids
#

finally its in!!!! im an ffmpeg contributor now!

#

feels really good for a 6 like patch

peak acorn
#

Does anyone have a solution for my goal?
To create an image which I can burn onto an SD card (via a .img file and etcher?) which a raspberry pi can boot off of. I need to be able to completely customize this image with packages and scripts from my computer without the hardware.

#

PiBaker is failing me becuase it automatically creates a 2gb virtual hard drive, which is not enough to install a desktop environment onto for the image

nocturne galleon
#

get a big sd card, and change the settings in pibaker to let it use the whole thing

peak acorn
#

cant just virtualize the sd card as well?

rotund zinc
#

I'm here to drop an update, filters have been added, date range as well as search.

#

Next up:

  • View individual drop
  • Drop submission form
  • Floatplane links
#

I'm gonna add a couple of drops in the database just so we can have something to show it off.

fading osprey
#

very nice! looks like its coming along quite well

solemn solar
#

That looks awesome

rotund zinc
#

i kinda wish lina and lucy linus and luke could see this maybe on the wan show

#

I also have to make a dashboard so that I can add and manage drops and other stuff, hell I'll even make a moderator role if anyone wants to help out

rotund zinc
#

eta for deployment should be tomorrow, it'll be around this time if not later, cooleg take much time very sad

#

ill publish the code to Github later today

solemn solar
#

Yeah this is awesome

woeful rapids
#

what is it written in

rotund zinc
#

"Sweet Laravel", a tech-stack I made. It consists of Laravel, Tailwind CSS, Splade and Vue

woeful rapids
#

oh okay, better than node

rotund zinc
#

hang on i need to generate a pet emoji

rotund zinc
#

and self-hosted on my servers

rotund zinc
#

Node is also good, don't underestimate it

#

nuxt is cool imo

fading osprey
#

Nuxt is cool, but I personally am partial to Svelte since revisiting it again

rotund zinc
#

I've tried SvelteKit when it wasn't fully released and it was cool, I will give it a try soon

fading osprey
#

I see you lurking @harsh kindle

harsh kindle
rotund zinc
#

im crushing cookies and energy drinks working on this

woeful rapids
fading osprey
#

meanwhile im reconfiguring my server to run truenas scale, because I cba waiting for LieNAS to be announced

rotund zinc
#

don't worry i will cache with Cloudflare plus Redis and other stuff

fading osprey
#

Cloudflare is GOATed

woeful rapids
#

a well configured haproxy + varnish and redis should do the trick if you dont wanna use CF

rotund zinc
#

im using traefik which should be good

woeful rapids
#

my server is not behind CF and has been doing fine

solemn solar
#

How long have yall been coding stuff for

woeful rapids
#

about 6 years give or take

solemn solar
#

Okay good I've got time

rotund zinc
#

~3

#

holy crap oxygenOS is spazzing out again

fading osprey
rotund zinc
solemn solar
#

Oneplus user spotted, which phone?
Also nice monitor setup

rotund zinc
# rotund zinc

this is what i bought for myself after a year of working

#

ignore the mess :p

woeful rapids
woeful rapids
fading osprey
# rotund zinc

this is sweet, I'm currently running a small TV as a second monitor lol, the paychecks cannot come fast enough

solemn solar
#

More in the "I know approximately what's going on but no real clue and now feel very basic" way

woeful rapids
#

mine are just old 5:4 displays

#

because im broke

mental panther
rotund zinc
#

i bought these second hand, 2xSamsung G5s for 150 euros each, all three are 144Hz 1440p 27" and my 1050ti is like a toaster

woeful rapids
solemn solar
#

I just took all my monitors from relatives

woeful rapids
#

been running for the past few years with few issues

fading osprey
solemn solar
#

Vertical one found in my grandma's soviet era apartment's basement room

woeful rapids
rotund zinc
#

lucky, i invested hard into myself, both for work and homelab stuff

woeful rapids
#

any monitor overdrivers here

rotund zinc
#

my bloody bill is 60 euros and i live alone OMEGALUL

fading osprey
#

we have solar to offset my electricity consumption
thats about all it offsets though

solemn solar
rotund zinc
solemn solar
#

Left one's a samsung syncmaster 2343 vertical that doesnt even support hdmi so i have to adapt a dp from my gpu cause that one doesnt support dvi

#

For a few weeks I used a horizontal monitor made vertical with books, which was quite fun

rotund zinc
#

but im happy that my work got me somewhere after years of not knowing what i wanted to do

solemn solar
#

That's quite nice to see, good job

rotund zinc
#

yes the joke about petPHP is stale but it pays the bills and i'm happy

mental panther
#

there really isn't anything wrong with php when done properly

#

laravel is great

rotund zinc
#

i mean you can make both bad and good code in any language

#

but laravel is a great AIO language without having to mess around with sessions, db, frontend etc

mental panther
#

wordpress's existence is probably part of the reason people dislike it KEKW

rotund zinc
#

yeah

#

plus the splade Splade package is a great because it combines PHP/Blade with Vue and introduces interopability and two-way communication

#

but im happy you guys and gals are accepting of my stupid and wacky ideas

fading osprey
#

PHP bad, all hail COBOL /s

rotund zinc
#

nah i'd rather do binary than COBOL

mental panther
#

every time I see cobol mentioned it reminds me of that post

fading osprey
#

this is a new meme to me but by golly is it hilarious

rotund zinc
#

experimenting darkDevil

solemn solar
#

That's quite cool

harsh kindle
#

fake linus

woeful rapids
# solemn solar

my pixel 7a got stolen recently so i had to improvise with a random crappy old phone

solemn solar
#

Oh god

woeful rapids
#

yes thats a kinect

rotund zinc
#

the kinect is watching

solemn solar
#

First of all, that sucks, hope you can recover from that, second, those monitors look like they are fresh from the year 2000

woeful rapids
solemn solar
#

Damn thats amazing

woeful rapids
#

and for compiling rust code, or to read a java stack trace

#

they still don't fit in 3 monitors

#

the total resolution is 3840x1024, or about half of 4K

unreal ether
#

also love the stickers on your laptop

woeful rapids
#

there are more out of view

rotund zinc
solemn solar
#

Mine's very bare but I never look at the back so I don't really mind

woeful rapids
solemn solar
#

Lmao nice

rotund zinc
#

Boom!

#

Gonna spice up the README game brb

rotund zinc
#

I see you @fading osprey you stargazer ❤️

fading osprey
#

me? what? never! CB_catto_blush

rotund zinc
#

I hate the fact that I have to look at this and cannot use this because SAS drives are not compatible in my server, basically rendering it useless

#

And it takes 2.5"/SFF disks

#

meanwhile my other 2 servers are pinned at nearly 90% ram usage

#

im gonna go vaccum until i find a damn hard drive

harsh kindle
#

not sure if i missed it or not, is it hosted yet? or just publishing the source first

rotund zinc
#

Just publishing the sauce

#

I'll get to hosting once I find a hard drive I can use in my R620

#

Probably online tmrw

rotund zinc
#

Took the old hard drive from my Macbook Pro 2010, it's 250GB and 5400RPM but it'll do the job.

#

For security, I'll be running the database on another machine just in case of data loss.

rotund zinc
#

Update I think my R420 has a compatible RAID card, gonna test it in the R620 and do a full migration, my R420 has only SATA drives so let's hope this works

rotund zinc
#

This is "fun"

rotund zinc
#

No luck, going back to the single 250GB hard drive

vague parrot
#

hey, i'm trying some things in js and wonder, what's the least complex between those 2:

let i = 0
for (let enemy of enemies){
i++; 
//function
}

//or


for (let i = 0; i < enemies.length; i++){
let enemy = enemies[i];
//function
}```
#

knowing that i need the i index anyway

rotund zinc
rotund zinc
harsh kindle
#

not that with forEach, there is also an index parameter passed to the callback function so you dont need to track it yourself

rotund zinc
#

a test version of dropdb is "live" on https://dropdb.tech so if you wanna see something that's really basic check it out

#

i need to add more drops on it :p

neon oriole
rotund zinc
#

caused my pain trying to figure out what it is :/

#

Todo:

  • Add a ton of drops and all the hosts
  • Leaderboard and Credits page
  • Submission box
  • Floatplane / Image support
#

Also I hate to be that kind of an arse but if we can get this on WAN show, would you guys like to stress test the living hell out of this website, now it seems super snappy but I want to make sure we can handle the wan

#

Also is there a possibility they will see this?

#

cuz im down to stay awake after midnight to watch the wan show and see a fire get started KEK

harsh kindle
#

good to be prepared, but dont get your hopes up 😄

fading osprey
#

Yup, Linus commented on WanDB stating that it was an amazing project, it still hasn't even seen a single utterance on the show, nevermind a showcase lol, those days are long over, and that's ok

neon oriole
fading osprey
#

Lol

neon oriole
#

ps on the <3 stuff , if your charset is set to utf8 ( <meta charset="UTF-8">) you can just drop in ```html
<p>💗</p> <!-- is 💗 -->

instead of `&lt3;`
solemn solar
solemn solar
#

Big issue with VSCode that I have is this preview thing. I want to tab once to complete my .Content div, but it gives me a suggestion for something I do not need and do not want. Any way of fixing this?

rotund zinc
rotund zinc
solemn solar
#

Lmao nice, same

#

Coding in class is just better tbh

simple canopy
simple canopy
#

Looks really nice, I might join in if I find the time and help out with some things that still need work

solemn solar
peak acorn
#

Is it normal for error handling to be like half of backend code

#

In our current setup any time you have a function that possibly returns an error we need like 8 lines of boilerplate copy pasted error handling stuff for the apis

fading osprey
#

If you are handling errors in an identical manner, you could always just have a standard function you call whenever you have an error, and make it return the request body

#

It's how I do it for WanDB, I have a callback method that processes the data and behind the actual function I just have a try-catch loop with some standard error handling logic. Optionally it also takes a customer "error processor" method, which is called only if present to provide granular processing of errors where it is required (on like, two endpoints)

frozen flame
#

Make use of middlewares

#

eg in my current project,

@router.route(openapi.Route(...))
@BasePermissionRestrictor()
async def get_full_calendar(request: Request, user: User) -> Response:
    resp = await request.app.db.get_calendar_items(user.workplaceId, user.id)
    return Response(resp)

thats what my entire route code looks like (with the openapi spec cut out).
error handling, ratelimits, and authorization is all already handled by the time the endpoint itself is run, so i dont have to worry about it when programming endpoints

peak acorn
#

Thanks for the input

#

Gonna research how I can reduce all of my error handling:)

frozen flame
#

depends on the lang/lib but generally you can do it in a middleware

#

if you use sentry they seem to have integrations for everything under the sun

peak acorn
#

It's a fatty Golang backend implementing some graphqpl apis but yeah the error handling stuff is kinda universal throughout

rotund zinc
#

Fixed a buncha stuff, rating system is in and the leaderboard & credits pages are available, now I justn eed to add data to it

#

hypeeeeeee dance

fading osprey
#

woot woot!

rotund zinc
#

everyone feel free to dm me your favorite drops

#

im going ham on teh db

peak acorn
#

Bro what

#

did i trash my leetcode by semi deliberately solving problems with really poor speeds

#

my thing is like "beats 35%" on easy problems 😵 thats so embarassing!

spring cradle
#

someone has to be last

peak acorn
#

😔

#

some of these problems cant even be solved faster lol

#

print "Hello World" and run it a few times until rng gives you a >50% score lmao

harsh kindle
next igloo
#

I compiled a program that runs on Windows 10 (Using SDL2 and OpenCL). I’ve tested it on the 3 computers I have in my house and they run fine.
What are some things I can do to make sure my program will run on any Windows 10 machine?

fading osprey
#

if it runs on all the computers in youre house, theres a solid chance itll run on them all, so long as they match the architecture you compiled for, and have enough power to actually run that code

rotund zinc
shy flame
#

does anyone recommend gms2 as a first engine to learn in?

neon oriole
# next igloo I compiled a program that runs on Windows 10 (Using SDL2 and OpenCL). I’ve teste...

you cat, since not even windows runs stable on every machine... however you can reduce the chance of it not working by, either using no libraries that don't ship with every windows version by default, or you can include the required ones with your program if the licence allows for it. (think all the c, vb and .net redistributables). lastly you can test yoiur program against wine on linux, if it runs fine with wine , your pretty safe it will also run on almost any windows out there ....

rotund zinc
#

Working on a project, thoughts on the design? Don't worry I am working on a dark mode :D

solemn solar
#

hmmmmm

bitter mantle
#

Yo guys I have a question about java

#

Can I ask it here or ?

bitter mantle
#

If that makes sense

rotund zinc
#

Like you want to be able to have a custom background?

#

Or are you talking about a banner per employee

bitter mantle
bitter mantle
rotund zinc
#

Are you referring to the red or blue section?

bitter mantle
#

The blue

bitter mantle
#

Because if you can then I mean try to do it and see the response it should be good
I think cause PPL would more like a custom background which they can put on certain areas of the website
Such as the blue one in this example

rotund zinc
#

Yeah I think that can be added, but I'm thinking that I need to figure out how it would integrate with dark mode, ty for the suggestion

solemn solar
#

This does look a bit out of place imo

rotund zinc
#

That's probably a bug from ShareX

solemn solar
#

Could be

#

But yea, I love it. I like the fact that there's an actual design style for it and you stick with it, the consistency is nice

solemn solar
# rotund zinc

Just checked this and I'm sure it's probably just a bug, but if you open up the navbar, the entirety of the elements on the right shift a little. I suggest making that differently so that it never leaves the screen

#

Alternatively, if the contents aren't a priority, what about a soft blur to the right side and the navbar being positioned absolutely?

rotund zinc
solemn solar
#

Yeah that part, the issue is that things like the profile move off the screen

empty pier
#

How to annoy a developer 101 🤣

mellow solstice
#

question can you use else in a while loop

fading osprey
#

Like, "while (condition) else"?

Not in any language I'm aware of

tight valley
spring cradle
peak acorn
#

Oh oops guy above me already said, I hasn't scrolled down

mild urchin
#

not me looking through my own code and saying "who wrote this shit"

solemn solar
#

Here's a fun css property in case any of you weren't aware of it
inverts colours, just found it out, I'm sure all of you know it though

fading osprey
peak acorn
#

Anyone know a thing about running large LLMs?

#

Asking in this chat because i think its the best chance of getting a quality response. And the purpose is to build a llm server for software development

main condor
#

I'm going mad, i add a object to a list on java and somehow it appears on the other list at the same time (i've looked at the debugger, right when I add to list a (a.add(object)) it appears on list b, i'm going mad

peak acorn
#

This sounds very very likely

main condor
#

editedDealership.addVehicle(createdCar);

// --- Elsewhere --- //

public void addVehicle(Vehicle vehicle) {
        System.out.println("-- Current ---");
        System.out.println(this.vehicles);
        System.out.println(this.soldVehicles);
        this.vehicles.add(vehicle); // Here ? (Nope)
        System.out.println("-- New ---");
        System.out.println(this.vehicles);
        System.out.println(this.soldVehicles);
}
main condor
#

All I know is in that exact step when I do either add(vehicle) or even add(new Vehicle(...)) somehow gets on both lists, I don't think there is one list referencing the old one

#

Yeah, it was related to that in some way

I was creating a dealership (in a seperate window) and save it to a serialized file, and there where other references there, so after loading it in the other window the references where kept as well, so yeah. I was truly going mad

neon oriole
#

python im sure of so prolly also mojo

#

i tought zig also , but ... that one i seem to have had mixed up with switch - else

frozen flame
#

Pythons else thing is wicked stuff

neon oriole
#

🙂 both for , and try also have an optional else clause in python 🙂

solemn solar
#

I don't think my brain is functional

bitter mantle
solemn solar
#

HTML

grim wind
solemn solar
#

What

peak acorn
#

I did not realize you could do word followed by a word in English when a word starts with a word but not finishing with words somehow (?)

solemn solar
#

I should consider taking a break

neon oriole
solemn solar
#

What's even the point of all the h1 p1 tags if div does the job just fine and has less overlap and is also more descriptive

fading osprey
#

page rankings

#

SEO likes you to follow usage specs for things

#

alos huge boost for accessibility, since most screen readers figure out what order to read things in based off of the page layout, not the processed css layout

solemn solar
#

And they go on endlessly? Like h50 is possible?

fading osprey
#

no, h1-h6

solemn solar
#

Any limits on paragraphs?

fading osprey
#

generally no, but just dont make them too absurdly long

solemn solar
#

Yeah I meant like p50 or something like that

fading osprey
#

and also, keep it text only, put buttons in a container div

#

also paragraphs are just <p>, no numbers

solemn solar
#

Issue for me is I have too much fontsize changing to only live with a limit so I'd have to change up the design, but ig if it helps accessibility I'm fine with it

fading osprey
#

yeah. font size changing can be done with <span>s, inside of a <p>, thats generally the standard practice

solemn solar
#

Ah I see, thanks for the info, gonna go through and fix up the thing then

fading osprey
#

no worries, @ me if you have more questions, im happy to help between "pwning noobs" (jk im bad at games)

solemn solar
#

Is there harm in only using headings since my paragraphs also vary in their fontsize so I'd rather just set up a heading for every one of these

fading osprey
#

it comes down to SEO and Accessibility, there's nothing stopping you from doing it, but does that mean that you should do it?

solemn solar
#

Fair point, any way of making it so I don't have to use a thousand span classes for my font weights?
Theoretically could I just reuse my divs as span classes in the h1 and p tags?

#

Also I got this but my application is approved, are those two separate processes and I just need to wait a few more hours for the benefits to actually get to me?

fading osprey
#

if you already have classes for divs configured for the font weights, thats fine, use those classes in the spans, css isnt locked to specific tag types unless you force a tag type on it

fading osprey
#

hence "your benefits will be available to you soon"

solemn solar
#

Ah nice, kinda worried since I've seen it for like two days now, but good to know
Also the existing classes will make it so much easier for me, good to know

I appreciate the help!

fading osprey
#

if it hasnt been granted after the new year, reach out to support, someone will sort it out for you 🙂

solemn solar
#

One final thing regarding VSCode, any way to quickly mass-tab an entire section?

Converting this, for example, I would need to manually tab everything if I were to add an h1 cause I like the readability of it better, but that's a massive pain

fading osprey
#

try variations of ctrl, alt, and shift, whilst dragging the cursor, I cant remember which one does what you need, but im sure its one of them

solemn solar
#

Ight I'll see

#

Ah found it, I just select the content, even if it's the paragraphs, and press tab

fading osprey
#

that also works too I suppose haha

jovial garden
#

I'm making a calendar app, should I sort months the Gregorian way, with January at the beginning, the Roman way, with March at the beginning, with January and February being at the end, or alphabetically?

fading osprey
#

Make it a switch

jovial garden
fading osprey
#

give users the option

jovial garden
#

Ok

solemn solar
#

I would say either what Altrius said, or, if a switch isn't possible, either do region based where it checks what region the person set their device to, or, make it based on your userbase, so if you exclusively run it in one country, you just use whatever that country uses

#

Though the check might be considered invasive by some

I wouldn't mind it, but I'm sure some data privacy law would spontaneously appear and ruin everything

fading osprey
#

you can generally check based on system region settings

#

if you create a list of the "defaults" per region code, then its easy enough to compare

solemn solar
#

Yeah that would generally be the most convenient approach for the end user

#

Actually, if you have the effort for it, make the switch an override so they can forcibly set it if they'd like, that would be perfect for both convenience and functionality

peak acorn
#

Are you making a historical calendar or something

jovial garden
#

yes

fading osprey
peak acorn
#

Not if you only use it for future events

solemn solar
#

Technically if you use a calendar to check what yesterday was, that is now history

hybrid anvil
#

does anyone here know about some good apps for a new windows PC?

#

very appreciated

solemn solar
#
  • WizTree
  • Everything (The app)
  • Powertoys

These are my favourite more obscure ones

hybrid anvil
#

ok thanks

neon oriole
# hybrid anvil does anyone here know about some good apps for a new windows PC?

spacesniffer (much better than wiztree i feel),tabby,link shell_externtion, windows terminal, 7zip, freecommander,ProcessHacker2 (or SystemExplorer),Dism++,notepad++ or sublime text,winbtrfs,chocolatey, you can install most of them form (administrator) powershell by doing: pwsh winget install chocolatey after wich you can use ```pwsh
winget search [program name]
winget install [program id]
--or
choco search [program name]
choco install [program name]

#

ow and RWEverything 🙂

carmine kite
#

hello

nocturne galleon
#

hi

solemn solar
#

So I've got an issue with the h1 and p setups, if I use span inside h1 or p it looks different than if I just used a div, which is a nightmare because I would have to manually convert everything and remake EVERY text in my site. Any way I could get around this and make h1 + span and p + span look the same as div?

solemn solar
#

Also, first it was coding css in html, now it's coding html in css

stoic dove
#

hello

solemn solar
#

I love how rewarding it is to successfully do something like this with the help of Github Copilot and my own brain
Github copilot only helped with the gradient setup btw, since I still struggle a little with pseudo elements and background linear gradient formatting

neon oriole
solemn solar
#

What I ended up doing was this and it works quite well to me

fickle fox
#

Hey, i want to build an e-comm store to sell electronics online, and i wanted to ask which is the best programming language to use for back-end and the best database?

solemn solar
#

How do yall find the motivation to make multiple layouts for everything so that mobile works?
I made it work on 16:9 displays and now can't any energy in me to make it work literally anywhere else

harsh kindle
solemn solar
#

Ah damn, I'm screwed then

inland nexus
midnight wind
#

like shopify, no point in developing your own

solemn solar
#

So I have a site where I'll have phone recommendations based on what the user wants and one part is a brief paragraph about each phone alongside an image and some links. I'm wondering if it's easier to swap those by hand or if it's easier to link 4 things:

  1. The phone image
  2. Name and price of the phone
  3. The author of who wrote the paragaph + the paragraph itself
  4. The links to three sites with the phone

I've never done anything with databases so I'm not sure what the complexity of this would be and if it's even worth it long term.

Any advice?

midnight wind
#

with another table called something like authors, where you can have name, picture, etc.

solemn solar
#

I've never done anything with databases before, how would that work and how difficult is it to set up?
What kind of database would it be? Etc?

oak flint
#

So, I just found something interesting. I have a Sofabaton X1 Universal Remote, and I found that on https://<remote-ip>:8102/ there is a web server. All I get is This URI does not exist when i connect, but I wonder if there is something there, just not shown right away. Any ideas on what to check?
I'm hoping it might have an API.

#

I'm thinking to set it up with something like Home Assistant

sage hinge
#

i'm trying to make a perl script that generates metrics from service logs and i dont actually know perl so i'm having some issues
so i'm parsing the logs with my (a bunch of other variables... ,$rtt) = split /:/; , and depending on some factors the rtt field might actually not exist in the log lines so i added this stuff:

    if ( ! defined $rtt || ! $rtt) {  $rtt = 0; } else { $rtt = int($rtt); }
    if ( ! defined $rtt || ! $rtt) { print STDERR "undef var rtt: ". $_ ."\n"; }
#

now for some reason the $rtt variable is not getting the 0 value, so the 2nd if just prints out every line that's missing the field

#

any idea how i can get it to just have a 0 value if the field is not in the logs? hmm

#

nevermind, i'm stupid and the ! $rtt bit was interpreting it as a boolean

elfin dove
#

Ive recently started making a personal website, but recently random parts of it has begun flashing white repeatedly and its quite uncomfortable to look at, noone else ive sent the website to has had this problem, does anyone have any idea as to what might be going on?

fading osprey
#

It could be any number of things, browser, GPU, screen

solemn solar
#

Best idea is to just check console and see if the colours do it there

solemn solar
#

Oh that's one of the sites I'll be linking, but mine will be oriented for people who have no clue what anything means

#

Like old people or parents, for example

neon oriole
solemn solar
#

I think I cn understand that one, in there I'd just make a table and use that for stuff?

elfin dove
solemn solar
#

No clue

cloud knot
elfin dove
#

uhh no I dont believe so

#

tho this is cool to look at lol

#

I did borrow this CRT effect css code and modified it, maybe that has to do with it?

midnight wind
#

very basic intro

solemn solar
#

Will check that out, thanks

midnight wind
# solemn solar Will check that out, thanks

This database tutorial will help beginners understand the basics of database management systems. We use helpful analogies to explain a high-level overview of spreadsheets, tables, and database management systems. The logic and concepts in this tutorial will make it easier to understand the more technical aspects of database architecture and Enti...

▶ Play video
#

this seems good too

solemn solar
#

Oh awesome, I appreciate it

frozen flame
solemn solar
#

Oh sick, thanks

cinder wharf
#

For folks curious about the lttlabs site I made a twitter thread going over the technology that I can tell it's using - mainly NextJS / T3

https://fxtwitter.com/RhysSullivan/status/1741963314207551549?s=20

#

no tRPC though which is interesting - app router means server actions are supported but imo if you're using server actions you may as well use tRPC

gusty girder
frozen flame
#

wtf why

#

I have yet to encounter anything that can't be handled by sql or plpgsql

elfin dove
warm anchor
#

this is my first attempt at a long format youtube video

oak thunder
fading osprey
#

Y'all know we've had JS, TS, CoffeeScript, etc plugins for Postgres for years at this point? MySQL adding JS support for DB functions isnt exactly a new thing in the db space, it is just new for MySQL

#

you fancy writing DB methods using LOLSPEAK?

HAI 1.2
CAN HAS STDIO?
VISIBLE "HAI WORLD!"
KTHXBYE
frozen flame
#

like yknow, fixing their stupid connection drops angerycat

fading osprey
#

oh without a doubt

#

but people getting mad at the fact that JS is the language they chose to add, is pretty stupid, when you look at the primary competitor

frozen flame
#

also whos the fucker responsible for putting lolcode into postgres

fading osprey
#

uncertain

#

cannot find the original link, and the link on the page is a deadlink

neon oriole
#

😦 when you remove half your program and it still just throws the same error 😦

neon oriole
tender hedge
#

anyone here know anything about rust, and could help me figure out why a counter isn't working? I'm just starting out with rust

fading osprey
#

I know enough to about Rust to know I suck at it, but shoot I'm happy to take a look

tender hedge
#

lol, fair, here's the code

fading osprey
#

and what is it doing?

tender hedge
#

endlessly printing "again" to a command line

#

I have to ctrl c it every time

fading osprey
#

take a look at line 6

#

you are redeclaring count by adding let in front of it, when you've already declared it on line 3

if you remove let from line 6 it should work

tender hedge
#

alright, just a sec

#

totally worked, thank you!

fading osprey
#

👍 happy to help!

I've never seen a for loop done like this in Rust, I'll have to look into it for my own projects lol

tender hedge
#

I am just going through the book in order of chapter honestly. I don't think I've gotten to for loops yet, just started working on basic loops. I just wanted to see if I understood what I was doing well enough, and clearly I didn't, lol

fading osprey
#

nah, variable reassignment is a pretty easy mistake to make, and awkward to find as well

tender hedge
#

yeah, being able to bounce code off of people helps me a lot with the things I normally miss, cause I don't really know what I'm doing, lmao

#

anyway, back to the lovely and not at all brain breaking process that is learning rust

fading osprey
#

yes, it takes a long time, and is really funky at times lol

neon oriole
#

hehe , if it was c , it would be like break would become goto, and the if condition inverted , and the again a label 🙂

unsigned int count;
AGAIN:
  count=count+1;
  printf("again!");  
  if (count =< 10) {
    goto AGAIN;
  }
printf("that was 10 times")
``` hehe tought it was funny
neon oriole
tender hedge
#

honestly valid, I'll probably be back here soon, the activity at the end of this chapter is to build a program without the book to guide you

#

as far as best practice goes, if I know i'm going to have twelve things that I want to list off, should I use an array? or should I just call them seperately

#

I also need the output to build on the previous output

#

like, twelve days of christmas style

fading osprey
#

sounds to me like youve got countless hours of MANDATORY FUN ahead of you

tender hedge
#

oh gods, lmao

wicked oriole
#

hey im new to html/css and using github pages to host my site. i have this code to detect for mobile usage using detection of portrait mode

      .centered-content {
        
      }
      body {
        font-size:80%;
      }
}```
but when i view it in my phones browser from its oublic domain it just displays the desktop page. Displays how i want it to in Acode's preview browser in the inapp version and even when i view it in firefox via localhost. Basically, it ignores this scriot when its on the github pages public domain but when i view it locally on my phone it works. Any idea why?
visual sand
#

I'm gonna try making a custom Ventoy theme with another Ventoy theme
if u wanna follow the same project i'm doing, here's the stuff

Not required but cool

How to change your Ventory theme fast and easy using Windows.


CHAPTERS

00:00 Introduction
00:16 Creating ventoy.json file
01:22 Downloading a Theme
03:24 Editing ventoy.json file

Thank you for watching.

▶ Play video
visual sand
solemn solar
#

VSCode hasn't been giving me CSS intellisense support with this extension, anyone else having issues?

modest grove
#

This took 72 seconds when I was debugging... VS code's terminal is one hell of a bottleneck

#

gives me a dumb idea

visual sand
indigo dragon
#

anybody here know a good hash library for Rust?

#

need something like SHA-256 or bcrypt

fading osprey
#

Take a look at the rust crypto project, they've done a bunch of different algorithms including various hashing algorithms like (from memory) sha256 sha3-256, and blake2

indigo dragon
#

nice. would all of these work with the WebAssembly target?

frozen flame
#

I wonder what the advantage of these instead of just binding to the C libraries is

indigo dragon
#

for me it's portability into WebAssembly

#

also conflicting versions in Rust are handled automatically by default with namespacing

#

you can't have two conflicting versions of a C bound library because of symbol name conflicts

#

at least that's been my experience

fading osprey
indigo dragon
#

yea that sounds about right

fading osprey
frozen flame
#

Except for missing on the safety that comes from using widely used libraries with decades of patches and the mainstream focus of security researchers

indigo dragon
#

since both can target LLVM you can throw formal verification stuff at it to verify that they're behaviorally identical in the ways that matter, but i'm not sure whether these projects do that

indigo dragon
fading osprey
frozen flame
#

Peanuts compared to its C counterpart?

fading osprey
#

Yes, C libraries have the advantage of age, and a wider install base, but the rust libraries are by no means less safe, and painting them as such because they don't bind to C libraries is a silly argument

indigo dragon
#

Rust does have substantial corporate investment from people like Cloudflare and a bunch of other people

#

i'd look for skin in the game where it's used as a good litmus test here

frozen flame
#

Does that investment reach these guys?

#

I can't actually tell

fading osprey
#

The investment is into the Devs who contribute on behalf of the corporate entity, so in a way yes

indigo dragon
#

honestly i'm not sure for this project, but Rust generally yes. my point wasn't that Cloudflare's investment in Rust is an investment in the whole ecosystem

#

but like Cloudflare runs a blog and makes it known what they use internally for a lot of these things

fading osprey
#

That's the beauty of open source, you can either donate, or you can invest into your dev team contributing effort to the project

indigo dragon
#

or pass through some feature flags to force one to not use openssl-sys and use one of the Rust-native ones instead

frozen flame
indigo dragon
#

yea my point isn't that investment in Rust = investment in the project

#

but more generally that they advertise their investment in Rust, so you can look around to see who is advertising their investment in a project

fading osprey
indigo dragon
#

you can look at the commit history for corporate email addresses and whatnot

fading osprey
#

Cloudflare especially has reason to be cautious about that sort of stuff given their prominent position as the internet people

indigo dragon
indigo dragon
#

ORM = wrapper around databases to make them type-safe in the language and handle things like migrations

frozen flame
#

I despise ORMs

indigo dragon
#

what do you not like about them?

frozen flame
#

Query builders

#

Type safety is cool but shoddy sql builders that make it more annoying to write manipulative queries are a plague

indigo dragon
#

yea i can see that. i'm using diesel and the issue i had was i can't include a backdoor to just run raw SQL and return responses

frozen flame
#

(Also formatters making a 300 line monstrosity with what could've been a 30 line sql query angers me but that's just formatting)

indigo dragon
#

it needs to know either the total number of elements or the names of the columns at compile time

#

granted i'm only doing this for admin tasks through a HTTP endpoint, so nothing performance critical

#

i just closed the ORM, forked off sqlite3 and sent the raw output back over HTTP

#

using an HTML form and HTTP GET/POST

harsh kindle
#

The best feeling ive ever had in development is when I optimized a task that used to take 30 seconds down to ~500 milliseconds

indigo dragon
#

What does it do?

harsh kindle
#

aggregates some stats from a ton of db rows

#

i dont remember the exact number of db rows, but its somewhere between 100,000 and 1,000,000

indigo dragon
#

oh lol very topical

#

what database are you using?

harsh kindle
#

the query wasnt the part that was taking a while, it was the actual processing once I got the rows

indigo dragon
#

what sort of stats?

#

i worked with the cybersecurity club while at university and one of the CTF challenges i thought about doing was a remote-code execution with Postgres stored procedures

#

postgres is such a modular ecosystem it’s wonderful

frozen flame
#

postgres is great

indigo dragon
#

yea in a previous life i developed for postgres at [large cloud provider]

#

working on their query optimization stuff

frozen flame
#

in recent times ive moved so much data processing onto postgres instead of the api

#

so much faster lol

indigo dragon
#

yea

#

currently i’m using sqlite because of deployment simplicity for my project stuff but might move to postgres if i need more speed

#

rust has this feature called “artifact dependencies” where i can build a target for another platform and refer to the output in rust through compile-time environment variables

frozen flame
#

RETURNING has spoiled me, i hate dealing with sqlite now

indigo dragon
#

SQLite has RETURNING in later versions AFAICT

frozen flame
#

not whatever the hell python compiles with blobseensomeshit

indigo dragon
indigo dragon
frozen flame
#

sqlite comes with python by default

#

ive no clue what version it uses cuz i just default to postgres for everything nowadays

indigo dragon
#

huh. had no idea

indigo dragon
frozen flame
#

the async drivers for postgres are fantastic

indigo dragon
#

so you can compile a stored procedure and run it as either binary or LLVM-IR

#

which is great, but fundamentally there are two phases: the query planning phase and the query execution phase

#

the [large cloud provider] version of postgres was designed as a distributed system so the query planner can compile down into a set of commands to run on each postgres node in the cluster

#

LLVM (through its attributes) can describe the functionality of functions through attributes

#

one attribute (i forgot the postgres name) effectively says “this function is commutative”)

#

LLVM should be able to produce an attribute to the postgres stored procedure during compile time and emit that somehow (with some patch, perhaps)

#

our approach was to always ignore this value if specified because we don’t want a configuration error causing data loss

#

but the compiler is a much stronger source-of-truth here

#

the end goal was to ship something like postgres-cc that exposed these properties

#

the process is a bit jank and there’s the more fundamental problem of selling to people who solve problems with money

#

which is completely valid, but it means that the ability to scale matters a lot more than the speed of an individual node

indigo dragon
frozen flame
indigo dragon
#

very cool

frozen flame
#

it uses a lot of cython for speed

indigo dragon
#

yea that makes sense

indigo dragon
#

i don’t think i’ll hit that point any time soon (and even if i do, embedded databases simplify deployment for me a lot)

frozen flame
#

thats some wild stuff

#

i just write procedures into my schema

indigo dragon
#

that could legitimately be a powerful addition to something like diesel (the rust orm)

#

i’m using the artifact binary pattern to attach a WebAssembly target to a web server

#

it might make it marginally faster but again my rationale was ease of deployment

indigo dragon
#

I’ve crashed cargo and wasm-pack three different ways in the past 10 minutes

#

Maybe I should go to bed

solemn solar
#

I'm loving using Github Copilot, I pressed tab 4 times to get this. I only wrote the name of the top div, the rest it just gave as autocomplete hints. Consistent with the rest of my site design style and no typing necessary. I love it.

vague parrot
#

smoll memory leak

solemn solar
#

I didn't know firefox became chrome

modest grove
#

I gotta convert a single threaded benchmark to a multi-threaded benchmark

modest grove
vague parrot
#

Well, I noticed I forgot to close a loop lmfao

modest grove
#

It's only dual threaded rn

vague parrot
solemn solar
#

Christ

#

You ran effecitvely an entire game purely on ram

#

Btw is coding a site purely on HTML and CSS without any flavour, no tailwind or anything, weird?

modest grove
#

ima disable the print statement to see if that adds performance

#

oof... yeah this aint... this aint great chief

#

either it was on par or worse

#

I'ma try a quad threaded test

#

that made it even worse

#

deep breath AAAAAAAAA

#

ima leave it in anyways

#

maybe phenoms arent great at multitreading... or maybe python isnt who knows

indigo dragon
#

The GIL might be killing performance here

frozen flame
#

yeah youd have to use multiprocessing in python

#

threading or async are good for i/o bound stuff, not pure number crunching

indigo dragon
#

rewrite it in rust

fading osprey
#

the only true solution

modest grove
#

It's gonna have more performance and less interpreter lag since its compiled, not interpreted

indigo dragon
#

Yea. Also I find it more ergonomic for one off projects

solemn solar
#

Any solution?

#

Trying to use Five server to live host an HTML file, but can't seem to make it work

indigo dragon
#

What exactly is Five server?

oak thunder
#

I mean all my development stuff that I do is through ssh anyways

indigo dragon
#

Yea VScode with SSH is what I use at work

#

It works pretty well but I’ve had reliability issues with the vscode server side daemon

#

That’s probably a corporate infrastructure issue tbh so i won’t hold it against it

solemn solar
#

Also fun bit of info to anyone who uses the Better Comments extension on VSCode, if you make a new profile and make the colour code invalid, it will make the entire line transparent and hide the comment mark
So something like this is now possible

I use * for the green colour btw, that's not just the syntax highlighting, all of that is wrapped in a comment

indigo dragon
#

That’s neat

solemn solar
#

I found it by messing around too much and breaking one of the colour codes, quite proud of finding that one

indigo dragon
#

Incredible

rotund zinc
#

ladies, gentlemen and everything inbetween, i present you this

#

this has to be the greatest to email ever.

junior birch
#

I hope someone can help me here.
I have a project where I need to send a UDP packet from my raspberry pi pico w to my laptop but the sending code that works on my laptop gives me a [Errno 107] ENOTCONN on the pico.

indigo dragon
#

Uhh can you post some source

#

UDP is a connectionless protocol but some places have a convention where there “connection” is just setting a reusable value for the destination

junior birch
#

weirdly enough by writing the code I had inside of a class directly into the repl it worked

plush grotto
#

I just got assigned a new project on Crystal Reports. I am not enjoying it so far.

earnest birch
#

I find it annoying how it's harder for me to replicate a site on Wordpress that is done only in html

#

Like I dunno if I should just write the site in html like the site actually is or use wordpress stuff to try and make the work easier

plush grotto
#

Man, I really hate Crystal Reports. No Python support to make shit easier for me, which would have been nice because of cursor.next_set().

midnight wind
midnight wind
#

especially a pi pico, the pico is more similar to a arduino uno

junior birch
earnest birch
#

Now I see why everyone hates wordpress

solemn solar
#

I learned HTML and CSS over 2 months and now it's just learning the minor features of it and learning all the insanity of cross compatibility and media queries for layout sizing
Also gotta learn SQLite

earnest birch
#

For assignment, I need to copy someone's website, I chose develop.games. Site itself is written all in HTML and nothing else but getting the HTML to work with wordpress while maintaining that site would look like original doesn't seem to work

earnest birch
#

Ah, figured it out.

#

Issue was that I couldn't figure out where I had to put the css code but found the place, which was quite hidden

neon oriole
neon oriole
earnest birch
neon oriole
#

that comment was not a positive one towards wordpress :p

indigo dragon
#

aight i'm working on that SSH TUN/TAP bootstrapping utility

#

reading up the Linux netlink APIs since I'd rather use those directly than assume the ip or ifconfig commands exist

indigo dragon
solemn solar
#

Yeah I'm in the process of learning it. Only issue now is how on earth do I make it work with my code, I think I have the database creation basics understood

#

On the topic of that, how DO I make it work? How would I link SQLite with JS and make it so that it adds the elements?

grim citrus
#

i think the sqlite one is just called sqlite

fading osprey
#

sqlite3 is what you want in nodejs

grim citrus
#

yup thats the one

solemn solar
#

From there, how would I connect it? How do I get NodeJS?
Sorry, I haven't really found a comprehensive guide and am a complete beginner to this stuff

fading osprey
#

right, uhh, you currently just have a html file with some JS attached dont you?

solemn solar
#

Yep

fading osprey
#

Your next foray into coding, will be learning the renowned art of the REST API, and Server Side programming....

This is a long winding road that leads to many rabbit holes.

A good place to start for someone with JS knowledge is Node.JS which is a desktop runtime for Javascript, which is "the standard" for JS backend development. You will want to look into an api framework like Express, and you will need to learn how to make use of the fetch api

Here's a relatively quick video explaining what all of the above means, I'd say @ me if you have any issues, but I'll be asleep long before that point, so good luck, have fun, if you run into any issues pop your issue (and a screenshot, prefereably) in this chat, and someone will help you at some point 🙂

https://www.youtube.com/watch?v=cr3pX6fSUpc

MDN Web Docs

The Fetch API provides an interface for fetching resources (including across the network). It is a more powerful and flexible replacement for XMLHttpRequest.

Get 1 on 1 mentorship with me! ▶▶▶https://calendly.com/codingwithchaim/60min

In this video I demonstrate how to build a node js rest api using express and sqlite. I also cover some fundamental concepts about node in general. I talk about the purpose of the package.json, what the require function call does and I explain what npm is.

Express mid...

▶ Play video
solemn solar
#

Ight awesome, thanks!
I appreciate this

fading osprey
#

(forgot to add the video lmfao)