#programmers-off-topic

1 messages · Page 12 of 1

pliant snow
#

For good and bad

#

Its too bubbly

gaunt wadi
#

yeah, it's too into you

#

all to disguise the fact that it's a large language model and not actually a person and will be wildly incorrect

pliant snow
#

Yeah, they think that having it speak in casual language will help, and its probably true

cinder karma
#

Because of my near perfect memory I almost never get lost

#

I may not be able to find my destination but I can always find my way back to my starting point

#

Also, I recall like, road closures and pot holes

#

Driving with anyone else is fun because I'll be like "don't take the left lane, it has potholes."

cinder karma
lethal walrus
#

Does it work as a key

ivory shadow
#

I want to assemble an entire keyboard of big punchable pillows

tropic anchor
cinder karma
modest steppe
#

he slemp

worn remnant
safe dragon
#

everything bound to alt and ctrl like a true emacs user

dapper sinew
#

I've heard of emac being sometime people who hate themselves use... What is it so I can learn it for no reason than I wanna learn something to meme about

safe dragon
#

ok so this is already going to be considered incorrect by some people but

#

in its essence emacs is a text editor

#

a very configurable text editor

dapper sinew
#

Ooooo

#

I like configurability

safe dragon
#

the defaults are absolutely miserable

#

and don't follow any standards you'd be used to

dapper sinew
#

Lol

safe dragon
#

most people who use emacs opt to use doom emacs or something like it

dapper sinew
#

Why do people say it's not a text editor

safe dragon
#

because it's so configurable that it can essentially do anything

#

some people call it an operating system, usually as a joke

#

I've never met an emacs user

crystal wren
#

I do really, really want to get to grips with vi-style controls, though.

pliant snow
#

i had a college professor who was a contributor to one of the mac emacs GUIs

crystal wren
#

Also, my joke was going to be that emacs is a mispronunciation of iMacs.

pliant snow
#

there was an Apple eMac

#

my school had a bunch of them

safe dragon
#

I can recommend learning vim controls. Not actually vim itself I'm fairly neutral on that

pliant snow
#

besides, everyone knows emacs stands for escape-meta-alt-control-shift

crystal wren
#

Yeah, I like my creature comforts too much to actually use vim. But the control style... I want that.

safe dragon
#

it's very very nice once you're used to it

#

and every editor under the sun has a vim plugin

pliant snow
#

I like vim, but yeah it takes some plugins to get it nice

#

not too many tho, i think some people go a bit overboard

#

to the point where you might as well use something else

safe dragon
#

me

#

I've stopped using vim for anything other than tweaking configs now though

#

zero plugins

pliant snow
#

gasp

#

hes a kate user now

safe dragon
#

of course

#

despite not even being on kde

pliant snow
#

i think they support it on everything

#

its one of those they want people to use

safe dragon
#

it's pretty good

lethal walrus
#

Kate is nice to be fair

dapper sinew
#

Vim sucks (the terminal editor) nano is better... I only say this cause I don't know vim controls

cinder karma
#

Vim great

strange copper
#

vim is good for what it does but i only use it when i HAVE to

strange copper
#

Unhinged question (c#) time! If I have a string type name, can I attempt to cast a generic object to that type

#

Completely theoretical I am not building anything cursed trust me I would never do that

#

(Runtime cast, not compile time if that wasn't clear)

marble jewel
#

There are explicit and implicit cast operators you can override, but I'm not sure if it can be done with any generic object

strange copper
#

I'll have to mess around with it

sand frost
#

If you have a string being type "StardewValley.Object", can you cast something to that?

#

(something generic)

#

That was my understanding, anyways

thin estuary
#

Casting isn’t real, in a way

sand frost
#

The string could also be StardewValley.Character or anything else I'm assuming

strange copper
#

Or it could be string

#

Or int

sand frost
#

this seems like something you'd needed to entirely error-check

thin estuary
#

Yeah but… that makes no sense

sand frost
#

what if it's not a valid type?

tranquil grove
#

you can apparently convert objects between types (with object and Type at runtime, tbc), but I have no idea where it'd make sense to do so SDVpuffermlem

strange copper
sand frost
#

hmmMmmMMmm

#

(usually I try-catch stuff)

thin estuary
#

I don’t even know how to explain it, but what you’re asking for doesn’t make sense

sand frost
#

What I'm wondering is why you'd be doing this

thin estuary
#

What would you do that for yeah

sand frost
#

But of course, you said that definitely wasn't for cursed reasons 😛

strange copper
#

Saving data and it's type information together

#

So you know what to deserialize it to

#

If there's a less cursed way please inform

tranquil grove
#

success, if this counts SDVjunimowhite

object thingToCast = 12345;
string typeName = "System.Int32, System.Private.CoreLib";
Type type = Type.GetType(typeName);
object convertedThing = Convert.ChangeType(thingToCast, type);

if (convertedThing is int intThing)
  Monitor.Log($"converted to this integer: {intThing}", LogLevel.Info);```
#

but in practice you'd probably want to know what type a given serialized field* is by some other means

thin estuary
#

Your code literally did nothing

tranquil grove
#

true, I should've made it some other compatible class, since it's int before and after

thin estuary
#

thingToCast is int intThing would do the same thing

#

and this seems to me like something else completely

#

anyway, that's already what Newtonsoft does for non-sealed types, pretty sure? maybe it has to be configured, can't remember

#

it serializes any object, and also serializes its' GetType().FullName or whatever, in a $type field

sand frost
strange copper
#

Shhhh this is offtopic

tranquil grove
#

(version that technically does something)

object thingToCast = 12345.6789f;
string typeName = "System.Int32, System.Private.CoreLib";
Type type = Type.GetType(typeName);
object convertedThing = Convert.ChangeType(thingToCast, type);
Monitor.Log($"convertedThing.GetType(): {convertedThing.GetType()}", LogLevel.Info);```
`[TestMod2] convertedThing.GetType(): System.Int32`
thin estuary
#

that would do something, yes, but isn't what is being asked for

strange copper
#

People are gonna specify types for serialization to json and for reading specific keys but I thought it'd be neat to be able to iterate over keys of different types. But the user is gonna need to know what type to cast values to if they could be anything

tranquil grove
#

my response was to the much more vague initial question SDVpuffersquint

thin estuary
#

sorry sorry Esca

tranquil grove
#

more to the point, yeah, you can do some slightly more helpful tricks with Newtonsoft types if you need a single field to accept multiple types, but it's still pretty necessary to know something about what's coming in

strange copper
#

When it is originally serialized it's gonna know the type if that helps

thin estuary
tranquil grove
#

e.g. FTM has a nonsense list of object spawn info* that can be an object, string, or integer, which it just tests for ahead of use

thin estuary
#

when working with values of unknown runtime types, the notion of "casting" doesn't make sense

strange copper
#

I've never messed with newtonsoft or serialization before so sorry if I'm not super clear

tranquil grove
#

no worries, but yeah, I'm not entirely clear on the intended format SDVpufferdizzy

strange copper
#

i mean i've serialized stuff to json but like i'm not a c# type system or newtonsoft knower

#

ok here:

  1. person A serializes an object of type MyTypeA to json under the key "key1"
  2. person A serializes an object of type MyTypeB to json under the key "key2"
  3. person B wants to iterate through the dict containing "key1" and "key2", and get the key-value pairs. But person B would like to be able to treat the deserialized values as their respective types of MyTypeA and MyTypeB (through a cast of some kind?)
thin estuary
#

basically:

  1. on serialization, you want to store whatever properties your unknown object has, along with the type name in a field like $type
  2. on deserialization, you need to read the $type, find that type in some way (check all assemblies etc), find a constructor you can use, invoke the constructor to get a correct instance of that type. then, fill the remaining properties of the newly created objects with whatever else was serialized
#

and none of this involves casting

#

well, there will be casting, the moment the user wants to iterate over that dictionary and actually use the correct types

#

because keys will have to be a common type

strange copper
#

tone is hard over the internet so i want to preface this by saying i'm not trying to argue at all, just understand. But in this method how is person B going to know what type the value is after deserialization? how is that information communicated?

thin estuary
#

and their common type is object, most likely

tranquil grove
#
  • if person B is doing something that can accept objects of any type at all, they can just leave each one as an object; the data is technically still there, even if their code doesn't know what it is
  • if they can only handle certain types, or need to do something based on the type, you can test for that
    (it may help to think of them in terms of inheritance, like if (objectA is Item item){} else if (objectA is Character char){} etc)
#

newtonsoft types may also help because you can interact with them directly as things like JObject for any random {} class

#

(iirc, anyway, it's been a while since I dove into that)

strange copper
#

so newtonsoft can give back an object that by polymorphism is actually of type MyTypeA at runtime and you can pattern match for it with is?

thin estuary
#

it has to

strange copper
#

and it remembers what you serialized it as originally and handles the deserialization type?

thin estuary
#

if you're serializing a known sealed type, it doesn't have to store that info, because you're giving it the type on both serialization and deserialization

tranquil grove
#

I guess what it loads into depends on the context where it's deserialized, unless you give it type definitions* like Shockah mentioned above SDVpufferthinkblob
in my context I did some parsing to see whether each object could be certain types, basically

thin estuary
#

if it's a type that involves polymorphism, $type is used

strange copper
#

thank you all for your explanations and examples

thin estuary
#

otherwise it would be impossible to deserialize, other than maybe into a generic Dictionary<string, object>

strange copper
#

that is true lol

#

I figured it came back as just an object or something

thin estuary
#

i guess in theory it could give you anonymous objects...

gilded hound
#

It would come back as an object, you have to enable TypeNameHandling

strange copper
#

the newtonsoft docs sure are something

thin estuary
#

i'm not sure TypeNameHandling is a required option if it can tell polymorphism is involved

gilded hound
#

OH I see, yeah since both MyTypeA and MyTypeB are available in the same context, newtonsoft should auto serialize the TypeNames

supple ether
scarlet hollow
#

Update: both lexical-vscode and elixir-tools.vscode (next-ls) crash on load. Back to elixir-ls, I guess 😕

safe dragon
#

not ideal

scarlet hollow
#

Yeah...........

tranquil grove
#

numbers can be checked with is long, lists with JArray, etc, in cases like that

#

(better to actually have known types for fields or serialize them, though)

gilded hound
#

yup. Without the context during serialization (Or in the case of FTM which is user generated), its just pattern matching. Could also write your own JsonConverter but its not worth the effort unless you really want clean code, since it just moves the code to a converter.

tranquil grove
#

yeah, I think the only jsonconverter I used was in something else for formatting's sake SDVpufferthinkblob

ivory shadow
#

I've got a few custom JsonConverters, one for doing discriminated types without the glaring vulnerability of accepting a type name.

supple ether
#

ah, JToken. I have a love/hate relationship with them

tranquil grove
#

(actually nevermind, it was for a stardew time class, either predating the one built into SMAPI or just because it made deserializing times easier)

strange copper
gilded hound
#
    internal class ReadonlyContractResolver : DefaultContractResolver
    {
        internal ReadonlyContractResolver()
        {
            SerializeCompilerGeneratedMembers = true;
        }

        protected override JsonProperty CreateProperty(MemberInfo member, MemberSerialization memberSerialization)
        {
            var prop = base.CreateProperty(member, memberSerialization);
            prop.Writable = true;
            return prop;
        }
    }

This is my favorite thing. Deserializing read-only properties.

tranquil grove
supple ether
#

one of many reasons I'm glad to have retired aerocore is the absolutely terrible thing I tried to do with the particle system

thin estuary
#

@ocean wolf what are you using Pintail for, and why .NET Framework 4.7.2?

supple ether
ocean wolf
#

I know SMAPI can do that but I also want to learn if I can use pintail directly

thin estuary
#

you're saying mods. so why Framework 4.7.2?

ocean wolf
thin estuary
#

i mean, sure

#

but it's written in .NET 5

ocean wolf
#

I can get it to work by bumping c# version but those would also require consumer ends to also bump c# lang version

thin estuary
#

if you're still using .NET Framework 4.x in 2024, then you're either a maniac or using Unity - either way, it sucks

ocean wolf
#

Anyways thanks for the awesome lib, it works like butter except I don't have the knife :))

thin estuary
#

i'm not sure if i'm using anything that is specifically .NET 5+, honestly

#

and ehh, personally i hate a lot of how it works

#

i'm glad it's helping people

#

but man

#

it really needs a rewrite and a better approach to some things

gilded hound
#

It's possible to compile for 4.7.2, there's a few changes necessary but I did compile it last year.

ocean wolf
#

It's working correctly if I bump consumer assembly's c# version to 9+, with polysharp which I have already been using

#

but always wondered if I can do without

rain lotus
#

So I'm trying out vss for the first time and I get this cute lil lightbulb on a lot of my code suggesting that I sort properties

Doing the thing makes my whole json laid out in reverse to what it should. Am I just gonna ignore these kind little lightbulbs forever or is there a way to set it to the format jsons should be for stardew

#

Posted in off topic bc its just a software question

pliant snow
#

I have never once found vscodes lightbulb suggestions useful

rain lotus
#

Okay good to know, lightbulbs are on but there's no thought behind them

gilded hound
#

I automatically tune them out. Forgot they were ever there 🤣

rain lotus
#

They're very cutely drawn! I wanted to trust them! /lh

safe dragon
#

what do you mean in that it's laid out in reverse?

#

does it start at Z?

#

quick actions (the lightbulb) can be pretty useful at times

#

just depends on the language server you're using

#

most just as a way to save some typing here and there sometimes

rain lotus
safe dragon
#

as far as I know the quick action for sorting properties just looks at the alphabet and doesn't look at anything else

#

I mean json doesn't have a whole lot more to base it on

strange copper
#

off topic so it's here but relevant to captcha convo in #making-mods-general : this was part of a captcha i had to do once

supple ether
#

triceratops crab?

sand frost
#

Triceracrab

strange copper
#

it was a spider

#

i failed it like 12 times before i realized twitter just really didn't want me to make an account

sand frost
#

That’s not at all a spider wtf!

#

Clearly Twitter firing most of their staff has had consequences lol

strange copper
#

oh the triceratops spider is the one you are supposed to click

#

it said click the one with the mismatched head and body

sand frost
#

It also has the wrong number of legs for a spider

strange copper
#

it's to fool the AI

#

trust

scarlet hollow
#

Really clever use of filter and blend mode on the Google Labs website to add a glow to the beaker animation

#

/srs btw. I don't think I'd have ever thought about reusing the video with mix-blend-mode: screen to accomplish that.

rain lotus
#

So I'm experimenting with VS for writing up game code and someone here suggested I try ilspy or another program with basically the same name to sort through the decompiled game to see when certain things are used and such. But uh.... ilspy is not for the 2022 edition of vs. Is there a program people are using on this edition that does what ilspy does?

cinder karma
#

IlSpy is independent software?

safe dragon
#

yeah ILSpy isn't a plugin/extension like resharper

#

it's a standalone application

thin estuary
#

it exists in the form of an extension too, but yeah, the people most likely meant the standalone app

gilded hound
#

(Also ilspy 2022 exists) But its really just a shortcut to open something in ilspy

rain lotus
#

I swear I spent an hour looking for that 😐

#

Oh I see how I messed it up

#

For whatever reason when I sort to show things tagged decompiler the only version of ilspy that shows up is the 2019 edition

gilded hound
#

Yeah the 2022 version literally just opens stuff up in the ilspy app

#

because visual studio 2022 already ships with ilspy decompiling

#

If you right click on something, there's a little option for Go To Definition. That's done using the ilspy decompilation engine

#

(The app comes with features like analyze so I still recommend it)

rain lotus
#

Okay so now I go find the actual ilspy program and begin messing around in it got it thank you all so much

cinder karma
#

I also feel like I get less confused

#

When it is separated

#

And I'm not digging through nine million VS tabs

rain lotus
#

That makes a lot of sense too

bronze idol
#

(typescript enjoyers appreciation post, that is all)

#

i didn't realize 2022 ships with ilspy decomp, TIL.

#

i have used it and dotpeek for tweaking binaries, i think they're vaguely almost the same thing.
if it weren't for the tweaking/saving of modified dlls directly it sounds like i could get away from needing the app.

flint frigate
#

@bronze idol My problem with JS is that its too dynamic for me, C++ is static. There's one way to do a thing and it reads up to down in order

Javascript throws all that out the window and lets you put things ANYWHERE

#

And it bothers me

#

It makes me cry

bronze idol
#

yeah, you just kinda do what you want. it isn't really about type safety.

strange copper
#

C++ will let you read 13 random bytes from somewhere in dynamic memory even if it's not set

bronze idol
#

mmmm blown pointers

strange copper
#

C++ will give you control to do MORE cursed stuff

bronze idol
#

that's why typescript is widely enjoyed; you can always strap type safety on.

safe dragon
#

not its enums though

bronze idol
#

personally been enjoying learning about blazor, but that's weapons grade koolaid

flint frigate
#

So I didn't really UNDERSTAND ya know?

bronze idol
#

look, i have to use mongo at work (not for long hahahahaha) and i'm sort of forced to use js in shells

strange copper
#

As in mongodb?

bronze idol
#

ye

strange copper
#

I want to like mongodb

bronze idol
#

but i do secretly love being able to do stuff like db.facility.find({}).toArray().map(f => f.StaffAssignments).reduce((a, b) => a.concat.b, []);

#

don't it's a trap.

strange copper
bronze idol
#

it's not the silver bullet people make it out to be.

safe dragon
#

We use mongodb at work, we use the c# package for it though so no javascript

bronze idol
#

aye, we use the mongo driver but most native admin shells are js

safe dragon
#

right

bronze idol
#

having said that, we were hamstrung by a sql-hating architect into using mongo

#

we're a very relational data "thing"

#

it was a mistake to avoid sql

safe dragon
#

our mongodb is only used for fairly unstructured state we essentially need to dump somewhere for reloading state it's very simple in nature

bronze idol
#

oh you mean WHAT IT WAS INTENDED TO DO?! lmao

safe dragon
#

no query more complex than just a key

#

yes!

strange copper
#

What do we think of neo4j. Are there any neo4j enjoyers here

bronze idol
#

you're so lucky to actually be using the correct tech stack for your problem scope!

safe dragon
#

idk anything about neo4j tbh

bronze idol
#

same

strange copper
#

Dang

#

I like the pretty colors and lines lol

safe dragon
#

for the most part we just use a gigantic overgrown MSSQL database

strange copper
#

I've never worked anywhere that's used a graph db but I think they're very cool

safe dragon
#

I've read about them but never used em

#

I always just go for a regular relational database

#

it's simple and more than good enough

bronze idol
#

same. it's all i know, really. i mean i know mongo now but we use it relationally so it's optimized relationally and it's a misuse of mongo

safe dragon
#

using a document store like a relational database

#

it's a choice

bronze idol
#

we're converting back to sql, it is long awaited

#

we fired that arch last year

#

we're having to pay his many debts

strange copper
#

Graph dbs are fun for networks and similarity and clustering and stuff

safe dragon
#

we looked into using Atlas for search but our relational database is so complex that atlas literally just does not support doing that

bronze idol
#

mssql full text indexing an option?

safe dragon
#

for some situations, yeah

#

elastic search has become our go to

#

for more complex needs

bronze idol
#

search is a problem we don't have much. our needs are very simple at a user level.

#

i reckon we could come up with more complex problems to solve but we haven't yet

safe dragon
#

search is a fundamental part of much of our software and especially the webshops

bronze idol
#

yeah. we're medtech. as we get more into ML and analytics stuff we'll likely have to deal with something tangential to search, broadly, but not literally search

#

more like.. correlative querying or how to objectively relate domains that are classically not related

#

if that makes sense

safe dragon
#

yeah

bronze idol
#

it doesn't to me, trying to think of a better way to articulate that. but the only things we have to search for are like.. patient name and social really

#

a better example would be like.. taking freeform data and objectifying it to a machine state. like detecting the words "patient on oxygen" and all its variations to objectify the boolean: IsPatientOnOxygen

#

et al

#

so it's search adjacent, if you think about it

#

if you squint lol

safe dragon
#

i remember some software thing being presented to me somewhere about being able take natural written doctor's notes and turning them into more concrete data automatically

#

no idea if it was any good

bronze idol
#

yeah. that's honestly a space where AI can do some good. dictation or writing transcription, up to and including digitization.

#

it's one of the few places i'd consider allowing AI to get a foothold, as long as the information was promised to be consumed ethically

#

if at all

#

we recently interviewed a team doing AI transcription for something, up to the point that it integrated with your EMR, did data entry in very specific ways

#

conceptually cool, but i'm skeptical of anything AI. it's usually 3 LLMs in a trenchcoat

safe dragon
#

same

#

we've had management talk about AI since that hype started but we haven't done anything with it so far

#

tbh management isn't even sure what it'd do

#

they just want AI

bronze idol
#

find something contrived to procedurally predict and then you get to say your app has predictive analytics (???) profit

#

buzzword city. like ajax

safe dragon
#

I think the one thing they've said where I can see the use in theory of an AI model is our module that automatically tries to figure out how much you should restock of every item in your warehouses

#

but on the other hand clients seem to have very specific niche demands for that and you can't really finetune an AI like that usually

bronze idol
#

you know what we figured we could use AI for? chatbot for support and conveyance of knowledgebase topics that have existing documentation. like train an LLM on our company protocols and helpful FAQ stuff, do something for the user that is a win-win. 24/7 support with some way to bucket the unresolved requests so we can satisfy them. there's lots of reasonable applications outside the increasingly popular plagiarism engine.

#

i think it's not that people lack the creativity to use it responsibly; we just have to get over the hurdle of immoral loss leaders using it irresponsibly.

#

it gives the whole thing a stigma

#

but we still have to give it crap and stay vigilant

safe dragon
#

I think we considered something like that too

bronze idol
#

the important stipulation at our corp is just that it can't replace a person

#

it makes our people's lives easier, less phone calls. but you still need a human in that seat. someone's gotta train the bot and field the unresolved stuff.

#

too many companies are seeing it as some kind of bold cost cutting initiative rather than being a quality of life improvement for their people

safe dragon
#

I mean they'll just reduce the number of support people they hire to the breaking point where support is constantly handling the unresolved requests

bronze idol
#

you're likely not wrong. it makes things redundant by nature. i think philosophically it's a dilemma. do you make a person do tedious, robot things because it's the right thing to do for them financially

#

it stands to reason there's a finite number of novel problems, in a situation like support, over any length of time. so yes, someone's getting fired if the robot is taking the majority of the easy ones.

#

this all assumes the robot doesn't just fail to deliver good outcomes

#

our support team, anecdotally, is small, and overworked by their own reports. the amount of good the AI will do is dubious at best

#

and "fire" is a mischaracterization. "made redundant" does really mean what it's supposed to here

#

the place i work is prone to moving you to a different position rather than cutting you loose, but companies are inherently worker hostile so this isn't something i say gladly. not really fond of boot

eager dune
#

I am moving tomorrow

low dome
#

Am trying 2 make farming game just like stardew but I can't figure out tilemaps

potent jay
#

im losing my mind, im getting a null exception thrown from the try section of my try/catch block. what is the handler for the catch, you might ask? why, a NullReferenceException, of course. im gonna go watch tv and think about life

safe dragon
#

is it async code

pliant snow
#

Time to actually finish this project I'm going to start, I swear

safe dragon
#

good luck

pliant snow
#

an important function

safe dragon
#

a deserializer for cats

#

back in pico8

#

Godot weeps

pliant snow
#

I actually have an idea for a godot project, but I wanted to do this first

#

gotta wait long enough until I've forgotten all my godot, as is tradition

safe dragon
#

"tf is a node"

cinder karma
#

What is that font

#

My eyes

#

7 segment is more readavle

safe dragon
#

pico8 font

#

it's got its charm

pliant snow
#

it's really caught on as a 3x5 font, I see it in a lot of random places

safe dragon
#

can't imagine you could make a font smaller than that and still be remotely usable

#

3x4...

pliant snow
safe dragon
#

s has become segmented

#

not ideal

#

but I suppose it's usable

pliant snow
#

consessions had to be made

tropic jungle
#

i mean

#

it is readable

#

i don't understand how i can read it

pliant snow
#

✨ magic ✨

ivory shadow
#

Your brain brains good

scarlet hollow
pliant snow
#

Me: Hey new guy, this commit is doing a lot of different things, it might be best to split it up if you can
New guy: No problem, I've split it up into seven different commits, here you go

safe dragon
#

he did what was asked of him

pliant snow
#

that he did

low dome
#

I ought to learn godot if I'm ever gonna make a stardew copy

eager yoke
#

During my time developing a mod for Minecraft, it got REALLY frustrating finding a mod I wanted to use as reference but its Fabric/Quilt and I'm using Forge

#

On the one hand I'm glad the community finally has more choice and the forge team isn't being mistreated by the lead dev anymore. On the other, it makes learning to mod a freaking nightmare
But I digress, my worldgen mod finally FULLY works
Now I'm dealing with getting the Warden to swim

scarlet hollow
safe dragon
#

lmao

#

our pr process is simple
open pr -> get approval from 1 dev and 1 tester -> it's merged gratz

scarlet hollow
#

Yeah the problem I have is basically that someone decided to split out a separate “UI” “component” “library” for our front-end team. So most changes require two PRs, one to modify the UI components (or build a new one! We have like 10 different modal dialogs! It’s great!!!!) and another to pull them into the actual front-end project

#

Except we don’t import into the front-end project from a GitHub link or something; we import from Artifactory. Guess what the CI/CD pipeline does?

It doesn’t deploy to Artifactory, that’s for sure! You have to do that manually before you PR, so the PR process for the UI library is literally just SVN, since everyone makes changes on different things simultaneously, and then we end up with package version 1.5.230 which has Dev A’s changes, and 1.5.231 which has Dev B’s changes but not Dev A’s changes

#

I hate it here

safe dragon
#

I don't even understand what is going on there

scarlet hollow
#

YO SAMEEEEEE

#

I’ll make a diagram later omegaLUL

safe dragon
#

even if you want a separated component library, if it's only used by 1 project you might as well just put it in the same repository tbh

#

can always move it out later if necessary

scarlet hollow
#

The original ambition was to make it reusable for multiple projects, and on paper it is, but in practice all but one of the projects just uses the basic UI primitives, and then people have built on top of them inside of the UI repo because “this is where the UI stuff goes”

safe dragon
#

I think you need more dialog box components

strange copper
#

what about another card

scarlet hollow
safe dragon
#

have a completely separate component for each possible combinations of buttons on the dialog instead of being able to configure those in one

scarlet hollow
#

But of course we still have to type the component to accept arbitrary strings and localization

safe dragon
#

ah yes I too bundle my business logic with my components so it's nicely separated for when we need this specific exact usecase again

safe dragon
#

prs yes

safe dragon
#

we have 3 testers at work they have long lost all joy in life

#

much like the developers

scarlet hollow
#

The company fired all of our testers Happie

#

“The engineers can do that”

safe dragon
#

no they can't

scarlet hollow
#

What the FUCK IS AN SDET ANYWAY?! LETSFUCKINGGO

safe dragon
#

we don't have enough testers so product owners end up testing a bunch of stuff

#

but they don't know how to automate tests and are generally just not as good at it

scarlet hollow
#

When I joined last year I found some UI test code that was testing the MFA pin code boxes by going, basically

document.querySelectorAll(“.pin-code-box”).forEach((v, i) => v.value = i+1)
#

In order to type out 123456

#

Instead of, you know, focusing the first box and the typing the full code, like a user would do???

#

Like, it passes, but you’ve completely missed the point

safe dragon
#

the fuck

#

I'm not sure id call that a test

scarlet hollow
#

It was e2e and the company hasn’t built a method for us to automate getting an auth token in our tests Happie

#

So we log in manually ✨

safe dragon
#

have you considered like... selenium

pliant snow
#

cant use third party libaries, that requires legal approval

scarlet hollow
# safe dragon have you considered like... selenium

Oh, nah, what I mean is like, at prior companies I’ve had a testing harness that exposes, like

const token = API._unsafeGetSessionToken(process.env.TEST_USERNAME, process.env.TEST_PASSWORD)
document.setCookie(‘sessionAuth’, token)
safe dragon
#

seems reasonable

scarlet hollow
#

But my current company doesn’t have that, so we have to go

$$(“.login-button”).click()
Await waitForLoad()
$$(“.username-field”).type(process.env.TEST_USERNAME)
// repeat for password
// click the button
// conditionally handle MFA prompt
// oops, the login team added an interstitial for passkeys, gotta dismiss that 
safe dragon
#

is the endpoint where tokens are requested not available to the testing application?

scarlet hollow
#

Nope, not really, because from our perspective, the code underpinning the login flow is a black box. We don’t own it, and it may change without warning

#

The login flow is SSR as well

#

Could we try to scrape our own company’s login page and fake a request? Yeah. But that’s basically what we have now, just with extra steps and way more brittle

safe dragon
#

i mean yeah you'd want something actually intended

scarlet hollow
#

Right. But try getting that on the agenda at a F500 company

safe dragon
#

formula 500 hc_pensive

#

very slow cars

scarlet hollow
#

Or very very fast

#

😔

safe dragon
#

I write for both the front end and the back end so when I need endpoints for something I can just add em

#

we have a generalized login endpoint. The implementation behind the scene changes but the api is consistent

#

kinda the point of apis I suppose

scarlet hollow
#

Because we have backend engineers on our team, but none of us have the ability to bypass the login flow

#

And creating an automation endpoint would probably have to go through multiple phases of review to ensure it couldn’t be misused to bypass MFA outside of the very specific e2e cases it’s designed for

#

And at that point the cost-benefit analysis turns into “fuck it, whatever”, and every team writes their own e2e automation to navigate the login flow

safe dragon
#

efficient

scarlet hollow
#

I wish I had even a tiny amount of influence over it

safe dragon
#

I'm not sure there's any application at my company that I haven't worked on at this point

#

the webshops I suppose

scarlet hollow
#

What’s the size of your company if you don’t mind me asking?

safe dragon
#

130 ish people + 3 outsourced teams of like 5 ish people each

scarlet hollow
#

Okay that makes sense. Most of the positive experiences I’ve had in this industry are at companies that size

#

My current company’s total engineering headcount is north of 10,000

safe dragon
#

wild to me

pliant snow
#

I think mine is about at that size

#

but only a fraction work in my department

safe dragon
#

I always wonder what's even going on at businesses that big. Like there's so many companies that essentially make like 1 product and then somehow have over 100 engineers

#

and I'm just like... what are they even doing?

#

tbh with the sheer number of people that got fired when the investors got scared I think a lot of companies were actually employing more people than makes sense

#

I wonder what percentage of the employees of a company like netflix are support

#

13,000 employees. As far as I can tell the actual product hasn't meaningfully changed in a lot of years with pretty much no new functionality added

#

you'd need a bunch of people to manage the server infrastructure and a few devs are definitely necessary

#

but

pliant snow
#

we have like five different departments in different sectors which all work more or less independently. We're a hardware company tho, so we make a whole bunch of different actual products plus all the software that runs on them, not to mention all the support, sales, IT, security, etc

safe dragon
#

yeah that's why I wonder how many of the employees at tech companies are actually developers, it's gotta be a small percentage

pliant snow
#

I get the impression most of the people in my actual department are engineering, but I dont see much of the support departments at all

safe dragon
#

I'd guess around 60% of the company I work for is support and consultants

#

maybe even 70%

#

there's only 3 people at sales which I find amusing

pliant snow
#

ew consultants

safe dragon
#

consultant in this context is essentially dedicated support for specific clients. Like the clients that are like multimillion euro business get their own dedicated consultant they can contact instead of dealing with support

#

those consultants are experts on that specific client's needs and in theory the one we also go to if we need to know something about their workflow or what they want

#

one of em recently got fired for fraud so that was fun

cinder karma
#

Nice

safe dragon
#

we used to have a security adviser or something but I had no idea what she did and when she quit they never actually got a replacement and nothing changed as far as I could tell

pliant snow
#

oh somethings changing, you'll only find out once its too late

safe dragon
#

she didn't even know how to share her screen during a meeting

#

had zero technical knowledge

#

she mostly just sent emails every once sending us news articles about how some company got hacked and that we need to stay alert

pliant snow
#

okay maybe she wasnt doing much

safe dragon
#

actual security vulnerabilities are reported by IT

#

she's also the wife of my manager

#

so

#

some strings were pulled I imagine

pliant snow
#

whattt nooo

safe dragon
#

kinda impressive that I work for a tech company but most of management is seemingly completely computer illiterate

pliant snow
#

or as theyre more commonly known, "management"

modest jewel
#

101110010101

pliant snow
#

gasp

dapper sinew
#

i require this i guess

#

since i have 3 GPUs

safe dragon
#

have you considered 40 gpus

dapper sinew
#

LOL

#

i got mine for free basically

#

(i might even be getting a fourth soon)

pliant snow
#

but why

safe dragon
#

to look at on a shelf

dapper sinew
#

extra on my PC

#

AI takes a lot of GPU and RAM

safe dragon
#

none of these pages say anything about whether they support amd gpus or not

#

considering they keep mentioning cuda I'm guessing no

#

I suppose I can give it a shot

dapper sinew
#

tell us how it goes!

#

i like seeing things grow for people wigglecat

pliant snow
#

what do you even do with the AI

candid pilot
#

i dont like ai

safe dragon
#

I don't dislike ai itself but I dislike a bunch of recent ai trends

dapper sinew
#

i wanna have it eventually be able to control my pc via voice commands

pliant snow
#

I dont know how to tell you this but you can do that now without AI

dapper sinew
safe dragon
dapper sinew
pliant snow
#

those are some weird ass benchmarks

dapper sinew
#

but its also the only thing ive found that can use all 3 GPUs and 128 GB of ram

#

(i like testing my PC :3 )

pliant snow
#

you can set up SLI (does SLI still exist)

safe dragon
#

not really

dapper sinew
#

windows only sadly

#

and im on Linux

pliant snow
#

SLI is windows only?

dapper sinew
#

the program is to my knowledge

safe dragon
#

sli has been discontinued as far as I know

#

nvlink took its place

dapper sinew
#

does NVlink take any card?

safe dragon
#

no

pliant snow
#

from the "NV" im guessing nvidia only

safe dragon
#

yes and even then only their enterprise gpus

dapper sinew
#

ahh rip

safe dragon
#

for consumer hardware sli type tech is essentially dead

#

just gotta be willing to spend several thousands on enterprise parts

dapper sinew
#

i sadly am not(yet)

#

id rather get a TPU first

#

the day QPUs come out is the day im gonna be happy

safe dragon
#

quantum stuff?

#

I wouldn't hold your breath if I were you

dapper sinew
#

i am not

#

i doubt itll come out in the next 30 years

#

but ohhhhhh boy if it does

pliant snow
#

it can do really small calculations really quickly

safe dragon
#

I mean, quantum processing tech is already commercially available through ibm but due to how it works I find it highly unlikely it'll ever be something one can actually buy instead of rent computing time

#

most people don't have liquid cooling and a vacuum chamber inside a faraday cage inside their homes

dapper sinew
#

i mean , im on Linux so there probably IS a way to have all GPUs being used by just... changing a setting lol

dapper sinew
pliant snow
safe dragon
#

it hasn't proven to be useful for anything yet so far

dapper sinew
#

oh cool!

dapper sinew
# safe dragon

how did you get that running btw? it says bend not found for me

safe dragon
#

idk

#

just installed it

dapper sinew
#

well dang

#

bug testing time

safe dragon
#

did you not run the second install command

candid pilot
safe dragon
#

even boss ai in a game

candid pilot
#

no thats fine. that's just logic yk

dapper sinew
candid pilot
#

yeah :(

dapper sinew
#

i truely only use it for fun and cause i like seeing things grow, its like seeing a child grow to me since its the closest thing i have to one right now... i know thats probably wierd but meh, probably the autism hyperfocusing on it

safe dragon
#

runescape is my child

dapper sinew
#

ive always wanted to play that

#

but idk if its past my time and dead :(

pliant snow
#

it is past your time but somehow not dead

dapper sinew
dapper sinew
#

any ideas why?

safe dragon
#

best guess is some incompatible version of gcc/clang

dapper sinew
#

i shall install and update them all then

dapper sinew
crystal wren
safe dragon
#

nice

candid pilot
#

yay

dapper sinew
safe dragon
#

and the most recent rust nightly compiler

dapper sinew
#

yep all the same

#

hmmm

#

wait i have rustup

#

is that different?

safe dragon
#

you should have rustup

#

it's how you install rust

#

or at least how you should install rust

dapper sinew
#

ok

safe dragon
dapper sinew
#

ahhh thats where its different

pliant snow
#

does it need to be nightly

safe dragon
#

yeah

pliant snow
#

your nightly is from january, it might be worth updating then trying again

dapper sinew
#

i did -Syu

#

but nothing changed

#

will try figureing out how to update brb

safe dragon
#

could run rustup update at least

#

running your arch package updates won't do much singe rustup is managing your rust versioning

pliant snow
#

-Syu will update the Rust installer program (rustup), but you need to tell rustup itself to update Rust

dapper sinew
#

ahhh ok

pliant snow
#

there probably is a rust nightly package i imagine

#

because why not

safe dragon
dapper sinew
#

ok its up to 1.80 now

#

or not?

safe dragon
#

I wonder where you're getting a strange january version of rust from

dapper sinew
#

Linux is wierd but so lovely

pliant snow
#

Try rustup update nightly

safe dragon
#

rustup update should update all toolchains

pliant snow
#

it looks like he has two tho

#

two nightly toolchains

safe dragon
#

yeah

dapper sinew
dapper sinew
#

(i dont know how i got two spooky )

safe dragon
#

probably messed around with it at some point

dapper sinew
#

maybe but i just installed it today, probably did it wrong honestly laugh

pliant snow
#

I have a nightly from 2022

safe dragon
#

rustup toolchain uninstall [toolchain-name] should work according to --help

pliant snow
#

Which is very interesting as this OS install is younger than 2022

safe dragon
#

lmao

candid pilot
dapper sinew
#

growing pains but its soooo lovely

candid pilot
#

what distro?

dapper sinew
#

ive been avoiding that laugh

safe dragon
#

why do you have some rust toolchain toml anyway in that folder?

dapper sinew
#

meme

candid pilot
#

mint cinnamon <--

dapper sinew
#

cinnamon is a nice desktop

candid pilot
#

i like it

dapper sinew
#

i prefer Hyprland

safe dragon
#

did you clone the bend project for some reason?

#

I too am on hyprland

#

and arch

#

as far as eliminating variables go we're doing well

safe dragon
#

you shouldn't need to

#

I mean I sure didn't

candid pilot
#

oh hyprland looks kind of cool as hell

dapper sinew
#

its so cool

#

a bit wonky at first

candid pilot
dapper sinew
#

but its super nice once you set it up

safe dragon
#

hyprland ain't my first tiling window manager bogaOwl

dapper sinew
pliant snow
#

I finally uninstalled hyprland lol

dapper sinew
safe dragon
#

damn aquo

#

having to share ur screen traumatized you hc_pensive

pliant snow
#

it did

#

im back on plasma

dapper sinew
pliant snow
#

its comfy

dapper sinew
#

i switch between em

safe dragon
#

you don't need the source project

#

think of cargo install as a package manager that finds the package online

dapper sinew
#

would you be willing to VC in here and watch me? so that i can be told when im doing something wrong

safe dragon
#

it's past midnight so I'd like to avoid vc

dapper sinew
#

alrighty!

#

so

cargo +nightly install bend-lang```
#

or install something else?

#

oh! they have a discord

safe dragon
#

should be all

#

and yeah they'd know better than me

dapper sinew
#

gonna ask them there, they probably know more

trim relic
#

I've never felt so called out.

dapper sinew
#

i can try and help

trim relic
dapper sinew
#

LOL you can build it like normal

#

dont need anything fancy

trim relic
#

I've never done anything with C# before. I'm used to Rust.

dapper sinew
#

i can give you the code block to make a new .net 6 lib if thats what you need

trim relic
dapper sinew
#

dotnet new classlib -f net6.0 -o <ModName>

#

then you go into it with vs Code (or cd) and do this
dotnet add package Pathoschild.Stardew.ModBuildConfig --version 4.1.1

#

VSCode i dont know how to use the inteface for so i do my coding in it but everything else from terminal

#

that includes compiling C# from terminal

#

which is apperently not normal? idk though multiple different responces there

#

cause this is stardew related

supple ether
#

TIL MethodImplOptions.Synchronized is a thing. Gonna have to remember that; could definitely be useful

ivory shadow
#

Decided to do performance testing for converting my GSQ delegates into native GSQ delegates tonight.

Pro: I learned more about IL and invoking methods.
Con: The experimental IL is literally the same speed as some C# I wrote in 20 seconds.

sonic mirage
#

Pro: You learned you weren't writing silly C#

ivory shadow
#

True, I'll take that.

tropic anchor
#

Thinks about making a minecraft mod once

cinder karma
#

Yes, LabVIEW, I don't want to know where in my fuckinf block diagram this control IS

#

(There should be something in the context menu but it doesn't seem to always work, it's greyed out for me rn.)

marble jewel
candid pilot
#

just immediately they reach out

tropic anchor
strange copper
#

"the program runs properly once every 10 times" is the worst bug when multiple threads are involved

pliant snow
#

the program only works if the user is within 500 miles

tropic anchor
#

The program only works on sundays between 4 and 6 on public networks

strange copper
#

for whatever reason i was not allowed to create one in the center nearest to me

cinder karma
#

What

strange copper
#

the organization that my subscription is under did not allow me to create a resource group in the server i'm closest to lol

#

I had to make it one region over

#

my null pointer is unfortunately not related to my location

cinder karma
#

What if it is?

strange copper
#

i think i would simply drop out

#

/j

cinder karma
#

Sorry you didn't put the data center next to a hospital

#

So the power can go out

strange copper
#

for some reason java thinks i can't get the next element out of a resultset even though I told it to check if it was before the first row in the result set and only try and read if so 💀

#

it probably has to do with me not knowing how this library works at all because we never discussed it until they said "ok haha big project"

ivory shadow
crystal wren
#

*name = story

pliant snow
#

someone got my reference

ivory shadow
#

I'd like to think I am on the Internet way too damn much.

crystal wren
#

Just prompted me to check the server for mentions of bash.org, and there are.. 18.

safe dragon
#

what is it referencing...

#

googling this doesn't work

#

I just get ads for air miles

cinder karma
#

Khloe linked the story

safe dragon
#

oh

cinder karma
#

It's a famous CS story

safe dragon
#

oh no I have to read

cinder karma
#

Next to trusting trusting, can't print on Tuesday

#

This file will jam the printer

ivory shadow
#

Oh man I hadn't seen that in ages either.

cinder karma
safe dragon
#

this is like creepypastas for programmers

crystal wren
#

Ah, it's our Ted the Caver Coder?

ivory shadow
#

The idea of trying to print something in Linux 14 years ago terrifies me on every level.

#

Of course it didn't print on Tuesday I'm shocked it printed on other days

crystal wren
#

The idea of trying to print something on anything 14 years ago terrifies me.

#

I found things more reliable there than on Windows!

cinder karma
#

A temperature limit of 0k turns this feature off

#

you don't say

ivory shadow
#

But I want the feature to keep working at 0k

#

I don't care if the atoms aren't moving make it work

cinder karma
#

The Worst Computer Bugs in History is a mini series to commemorate the discovery of the first computer bug seventy years ago. Although these stories are more extreme than most software bugs engineers will encounter during their careers, they are worth studying for the insights they can offer into software development and deployment. These comput...

safe dragon
#

we did actually have a bug once at work that caused something to break but only on mondays

lethal walrus
#

cant open it either

cinder karma
lethal walrus
#

.. the issue is that the file cannot start with T, but can t??

safe dragon
#

what the hell

#

at least when we had a bug that something didn't work on mondays it actually had to do with something that involved a days of the weeks selector

#

this is just wild

cinder karma
#

This manual is 200 pages lonf

#

And pauses to explain stuff like voltage dividers

#

Tbh

pliant snow
#

the AUR is down

#

everyone panic

cinder karma
#

I get they aren't marketed to EEs but I'm about to fall asleep on it

lethal walrus
pliant snow
#

the official packages are fine I think, the AUR are community submitted installation scripts

safe dragon
#

the arch user repository hc_pensive

pliant snow
#

its back, please cease panic

#

although my helper can't access it yet

crystal wren
#

Is yaourt still a thing?

#

That word is burned into my typing muscles.

pliant snow
#

i think it stopped being developed, others have taken its place

safe dragon
#

I've always just used yay

pliant snow
#

I use paru now, mostly so I dont have go installed just for yay lol

safe dragon
#

discriminating against go

#

golang is a fine language hc_pensive

#

I think it's ugly as sin but it's fine

pliant snow
#

go's worst feature is that it puts its config stuff in my home directory

#

Could i probably change it so it doesnt do this? maybe

safe dragon
#

sue google

pliant snow
#

that'll be plan B

safe dragon
#

my reason for thinking it's ugly is roughly just as serious of a problem

#

I just don't like that for an array type declaration its []type instead of type[]

#

I'm fine with rust's [type] cause it's different enough to just be different

#

but doing the same as I'm used to in C# but putting the brackets on the other side is just illegal

#

tbh it does get worse

#

map[keytype]valuetype

#

not a fan 0/10

#

the rest of the language seems really cool but this makes it essentially unusable!

cinder karma
#

🪭

safe dragon
#

I did absolutely love the simplicity of coroutines but alas, ugly syntax for types and thus will never use it

pliant snow
#

create your own transpiler that only modifies that one specific syntax

safe dragon
#

smart

#

has anyone ever created a language purely just to change the syntax in solely aesthetic ways

ivory shadow
#

I propose the following two dimensional array syntax for the sole purpose of driving Crumble crazy: []type[]

safe dragon
#

how do we do 3D arrays

#

and 4D

ivory shadow
#
   []
[]type[]
   []```
safe dragon
#

lmao

#

I approve

#

5D arrays are not supported

#

cannot be represented by the type system

pliant snow
#
    []
[]ty[]pe[]
    []
safe dragon
#

when you rename your type to a different number of characters and you to realign all your brackets

cinder karma
#

No more difficult than rebuying a bunch of bras because your redacted changes sizes

ivory shadow
#
  [][]
[]type[]
  [][]```
#

If you need more dimensions you need to make your type name longer

safe dragon
#

a well supported type

#

what do you do for odd character lengths for types

#

like int

#
  [ ]
[]int[]
  [ ]
pliant snow
#

#typedef iint int

safe dragon
#

it'd be a funny stupid restriction for a joke language that type definitions cannot have an odd number of characters

#

no int, no string, no float

ivory shadow
#

Identifiers must contain eight to twelve characters, and contain at least one each of numbers, symbols, and uppercase letters.

thin estuary
safe dragon
#

oh

#

you're right

thin estuary
#

rofl

safe dragon
#

counting has never been my strong suit

ivory shadow
#

clearly string is an exception

safe dragon
#

luckily exception has an even number of characters

#

wait no

#

it doesn't

#

jesus I should go to bed

ivory shadow
#

Instead of exception we have UhOh, which is a nice even number of characters

candid pilot
#

lol

lethal walrus
safe dragon
#

nah NullReferenceException will do

#

no other exceptions exist anyway

lethal walrus
#

YourProgramBrokeAgainGoodJobExclamationCharacter

candid pilot
#

ValueError is all you need

#

Exceptionn

safe dragon
#

exception!

pliant snow
#

AHHH

candid pilot
#

Exception but we add a different letter to the end depending on what type of exception it is

pliant snow
#

Exception but we captialize different number of letters to indicate how severe it is

candid pilot
#

syntax error? just catch a Exceptiona. forgot a bracket? Exceptionk

candid pilot
#

not me programming and getting 5 EXCEPTions

pliant snow
#

Bug Report: 2024-5-18
Severity: EXCEPTIONion (Critical)

candid pilot
#

sees EXCEPTION all caps and breaks down crying

safe dragon
candid pilot
#

why 😭

safe dragon
#

the real fun thing is that we didn't have any documentation for these so the only way to find out what it meant was to find it in code

candid pilot
#

what the fuckkk

safe dragon
#

and people would often copy paste the code from other functions having no idea what they meant

#

so you'd get like 6 results

#

but since we didn't rethrow the original exception we didn't actually have the original exception message

candid pilot
#

sounds like hell

safe dragon
#

it made no sense

#

it's not like we exposed error codes to the user

ivory shadow
#

I have somehow managed to allocate less bytes than string.split (in some situations)

#

Not as fast but I'm just confused about how I'm allocating less, lol. I'm just dumbly tossing things in a List<string>

void vortex
safe dragon
#

skill

safe dragon
#

wonder what the most memory efficient way is of splitting a string

#

my guess is using a span

ivory shadow
#

I'm using stackalloc to get a char array for building the working item, and just tossing the finished items in a list.

cinder karma
#

yeah, and I thought the string.split would do similar\

ivory shadow
#

Seems to work pretty well. I could in theory iterate the string twice to count how many slices there are... but that's chasing memory allocation a bit too hard

cinder karma
#

so part of string split's overhead is likely because it deals with multiple possible seperators

ivory shadow
#

Yeah. I on the other hand need to support quotes and escaping them.

#

I think I need to adjust my algorithm more too, to make it work identically to the game, because the game's method is fucked up lol

cinder karma
#

I'm incredibly, incredibly surprised, btw

#

string.split isn't in c/++

ivory shadow
#

My end goal is probably using harmony to replace the built in string parsing methods.

cinder karma
#

Yeah, I was building a quote aware string split at some point as well, but it wouldn't conform to the method signatures the game expects (ie, it's yielding ReadOnlySpan<char> fragments, it doesn't stick things into an array.)

ivory shadow
#

... how do you yield a ref struct lol

cinder karma
#

wrapping it in another ref struct!

ivory shadow
#

Oh right. That.

cinder karma
#

you can just define the GetEnumerator/Current and it Just Works

ivory shadow
#

I'm still waking up lol

cinder karma
#

no worries, I fell asleep at like 8PM yesterday

#

longggg week was longgggg

#

but yeah, I can't avoid some allocation overhead (mostly in the "removing the damn escape character") but I was trying to avoid it as best I could

ivory shadow
#

Anyway, I feel like this is important enough to write two versions of the function.

cinder karma
#

what

#

"Correct" and "fucked like the game?"

ivory shadow
#

Yes

cinder karma
#

lol

#

I just wanted quote-aware-stream-split for personal use, but seeing that I haven't gotten around to finishing it...

ivory shadow
#

Honestly I never intended on falling in this rabbit hole, but then the game offended me with how silly its code is. I know it needs to support ancient runtimes, but... yeah

dapper sinew
#

what are some good ways to start learning coding, i learn by doing but everytime i try to do i get so overwhelmed. i wanna learn JavaScript so that i can make a GUI with electron. if i try asking people who know coding they shoo me away cause i guess coding isnt noob friendly? but i know yall here are nicer lol

safe dragon
#

learn by doing is generally the way to do it for programming tbh. Just gotta start with something really simple with a tiny scope and work your way up

#

if programming as a whole is new to you just start with simple coding assignments like a program that prints out the prime numbers between 0 to some number n

#

and for the web side, start without any javascript at all. Just html and css to make something that doesnt do much but gets you used to creating a layout/styling

#

and then just work your way up

#

your initial versions are going to probably suck that's normal. It's not like you can only try it once

#

only once you've figured out the absolute basics I'd consider even looking at "web frameworks" aka react, vue, svelte, solid etc. When you know nothing yet they'll only make it more daunting to start

#

also just start in a browser, no electron

#

honestly my entire advice boiled down is "avoid trying to do too much at once and don't worry about whether you're doing it the right way yet"

dapper sinew
#

ok, ill try that

tropic anchor
wary sail
# dapper sinew what are some good ways to start learning coding, i learn by doing but everytime...

Haha coding is a big topic, some people love to gatekeep it or talk down to people asking "dumb/pointless" questions in my experience(some stack overflow nerds lol). I'd say figure out what you wanna do, in your case GUI w/ Javascript. And then learn the base basics of the language kinda like what Crumble said, do some practice problems, and work your way there

If you're deadset on javascript go for it, it's a great language to know if you want to expand into web dev stuff also like what crumble said with "react" and other frontend frameworks. I think python has some great libraries for a GUI as well if you're just interested in a GUI and not webdev I'd lean more towards something other than Javascript

#

That's my take on the matter. Feel free to reach out with any questions though! I LOVE teaching programming topics 🙂

tropic anchor
dapper sinew
pliant snow
#

coding focused chats can be rough, as they tend to hear the same questions over and over and often will dismiss valid questions because they're tired of answering it

dapper sinew
ivory shadow
tropic anchor
#

That's because the syntax is way different from others, no brackets, no ;, just tabs and pain

#

But it is easy to learn, and very beginner friendly

wary sail
dapper sinew
#

me wanting to learn assymbly just cause

safe dragon
#

definitely not the place to start 🙏

cinder karma
#

Python is great for AI tbh

dapper sinew
safe dragon
#

I wouldn't sweat the language you start out with too much. The basics transfer to almost all languages and certainly to every language mentioned here

tropic anchor
#

I've only used python for web scraping and Advent Of Code

cinder karma
#

We do a lot of python for automation

safe dragon
#

I've done advent of code in elixir, rust and haskell

ivory shadow
#

It's so weird to me that python is the big language for AI stuff

tropic anchor
#

It's easy and lightweight

safe dragon
#

I think it makes sense. It's often used by people who are more on the data science side, not programming

dapper sinew
#

can someone explain to me the need for the main() at the end of hello world codes?

ivory shadow
#

Yeah, I just look at it and think "python slow" but all python is really doing in the situation is gluing APIs together effectively

safe dragon
#

what language?

dapper sinew
ivory shadow
#

And there's something to be said for easily gluing APIs together

tropic anchor
#

Call the function

safe dragon
#

the first two define a function called main. The last line calls this function

#

you could remove everything except the print statement and it would in this case do the same thing

cinder karma
#

One day I need to show you my insane bitbashing BS in python

dapper sinew
#

someone i know is a good programmer and they make a decoder for AI Models

wary sail
#

this is side info you never asked for, a main method is not required in python. But it is required in other languages

safe dragon
#

basically in many languages a function call main shows the entry point of the program, aka where it needs to start

tropic anchor
#
def main(): #Create new function called main
    print("Hello World") #Print the text "Hello World" to the console
main() #Run the function called main
wary sail
dapper sinew
#

i meant for asking info about stuff i didnt talk about

#

unless you meant something else

tropic anchor
#

Lesson 1: Add comments (in python you can add one with #), this way you explain it to yourself as you go, and it helps with remembering what code does what later

dapper sinew
#

will do

safe dragon
#

damn python doesn't have block comments

cinder karma
#

It does (sorta)

#

Use a multi line string

safe dragon
#

I'm not counting """

#

those are docstrings really

#

which is still a comment in a way I suppose

dapper sinew
#

would reverse engineering be a good starting point as well? i have code that makes a GUI in python that i got from my friend(he does most of the coding for stuff i want since i cant just yet)

safe dragon
#

looking at how other people did things will be great eventually

tropic anchor
#

I'd say so, going through code and looking up what does what is how I learned python, and if it's well documented that's even better

safe dragon
#

it's very valuable to have something to look at as a reference

dapper sinew
#

ok, ill start with messing around with it then and coding from scratch while having that reference(ive never coded from scratch)

wary sail
#

It probably makes the most sense to learn the barebones of the language first. Learn how to make really simple things and solve simple problems, that way you have a foundation. While you can learn a lot from looking at the other code, if you don't understand the underlying concepts well enough you will be making assumptions and have gaps in knowledge.

So my recommendation is start simple, once you're confident start branching out and coding from scratch while comparing to your friend's code

#

IMO

dapper sinew
#

ahhh ok, that does make sense lol

tropic anchor
safe dragon
#

as long as you can mostly understand the code you're looking at it's fine. If you're just copy pasting lines in you should probably reconsider it

dapper sinew
#

thats the limbo im in, i can read and understand some code. but i cant do anything with it.

#

havent figured out a way past this current "wall"

pliant snow
#

To learn programming, submit fixes and features to bouncer that im too lazy to do

safe dragon
#

it's even in python

tropic anchor
#

Are there even any issue's right now?

lethal walrus
#

I'd also take fixes in farm computer

#

I really should merge that async PR

safe dragon
#

what does farm computer do

lethal walrus
safe dragon
#

damn

#

parsing a wiki hc_pensive

lethal walrus
#

it's not overly bad

dapper sinew
#

(using the python one)

safe dragon
#

the funky world of floating point numbers

dapper sinew
#

numbers are magic, they float now

wary sail
dapper sinew
safe dragon
#

tbh floating point numbers are funky enough to be considered arcane magic

#

the internals anyway, using them is simple

ivory shadow
#

Let's count to 1!

0!
0.100000001490116119384765625!
0.20000000298023223876953125!
0.300000011920928955078125!
0.4000000059604644775390625!
0.5!
0.60000002384185791015625!
0.699999988079071044921875!
0.800000011920928955078125!
0.89999997615814208984375!
1!

wary sail
#

haha

wary sail
dapper sinew
#

watching a vid on programming, person said it took 2 weeks to learn how to put in a png to a game, i now feel like i have not been as slow as i thought

ivory shadow
#

Bonus of learning Python if you want to do game development: Godot's GDScript is very close to Python

#

(Of course, that doesn't help with Stardew. Or if you want to use Unity. Or Unreal. But Godot is neato.)

dapper sinew
#

oddly enough modding stardew is easy for me

#

i dont know why though

wary sail
dapper sinew
#

How in the world laugh

wary sail
dapper sinew
#

is unity still going through with that change?

#

seems like itd kill them if they did

wary sail
#

As far as I know. I stopped paying attention

dapper sinew
#

oof

ivory shadow
#

They stopped, but they burned a lot of good will on that it even happened.

wary sail
#

ah

ivory shadow
#

Gave Godot a lot of momentum in the process.

dapper sinew
#

Have programming catTM

ivory shadow
#

Even with the threat that console ports would be harder, I think I'd use Godot over Unity or Unreal for making a game.

dapper sinew
#

Unreal is so pretty

ivory shadow
#

Unreal is a lot

#

If you're just makin a little game, you don't need all that.

pliant snow
#

oh i can make an ugly unreal game, dont you worry

ivory shadow
#

It can actively get in the way, in fact.

dapper sinew
#

OH OH, is there any way to make my code to run on all my GPUs?

ivory shadow
#

Anyone can make an ugly unreal game. Just look for YouTube videos of old Nintendo games "remade" in Unreal.

pliant snow
#

cuda i guess

ivory shadow
#

Bunch of absolute idiots who don't comprehend the phrase 'cohesive art style'

dapper sinew
ivory shadow
#

Unreal and Unity are both chasing movies and TV, also, which is kinda weird and leads to a bunch of features that aren't really for games

dapper sinew
#

ahh ok

#

i dont plan on making a game yet

#

but if i did id want it to be pretty

#

but id probably make my own lighting engine cause importing SUCKS(i dislike having to import stuff cause it feels unatural)

pliant snow
#

no important assets, everything must be done in code

dapper sinew
#

i want something that i made completly if that makes since, having imports of others work just feels off

#

i KNOW ill change my mind as i go though, cause some things i just wont know how to code

crystal wren
pliant snow
#

my game ships in its own pocket universe, ensuring the laws of physics are the way I want them

dapper sinew
#

code is like a child i can watch grow, so i wanna keep that feeling for as long as i can. if that makes sense

crystal wren
#

I get it entirely! But you need to figure out a certain stopping point.

Because if you don't... logically, it extends down to you engineering your own ICs with your own architecture, writing your own BIOS for it, your own graphics API for your self-designed processors and/or GPU, firmware for everything, an OS to run your own code, a compiler to compile things for it...

dapper sinew
#

oh fair spooky

#

didnt think of that

pliant snow
#

i knew a guy when i was in high school who went down that path. None of us knew how to make game or anything like that, so he was trying to learn the framebuffer API lol

crystal wren
#

I would look at, say, SDL? See if that's a low enough level for you maybe.

#

Going any lower than that, you're writing OpenGL/whatever graphics API code directly by hand... which might also be what you're after!

dapper sinew
#

i did start learning shaders for MC which uses OpenGL

#

not sure if its the API or not though, still gotta learn exactly what an API is

pliant snow
#

An API is the way developers want you to interface with their project. Usually it refers to the functions they make externally available that you can execute yourself when their project/library/engine whatever is set up

dapper sinew
#

ill learn what that means at somepoint lol, currently having this stuff explained to me like im a child laugh

pliant snow
#

What you need is a way to make excellent games using a comprehensive IDE environment

dapper sinew
dapper sinew
#

i dont know any actual IDEs

pliant snow
#

A game engine that gives you all the tools you need, but some limitations to make you really plan your games out...

dapper sinew
#

oh thats what you meant

safe dragon
pliant snow
#

An engine where you can make games like Celeste, and uh, others

crystal wren
#

Though Celeste was made using MonoGame like Stardew!