Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Locked thread
Jabor
Jul 16, 2010

#1 Loser at SpaceChem
more like hell world

Adbot
ADBOT LOVES YOU

VikingofRock
Aug 24, 2008




oh no blimp issue posted:

why is the hello world rust example 3.2mb? why isn't lto turned on by default? why is over 2mb of that binary strings?

rust statically links its binaries by default

pre:
➜ cat test.rs
fn main() {
    println!("hello world!");
}
➜ rustc test.rs -o test
➜ du -h test
508K	test
➜ rustc -O -C prefer-dynamic test.rs -o test
➜ du -h test
 12K	test
If you want to do the same thing with cargo, it's

pre:
cargo rustc --release -- -C prefer-dynamic

Luigi Thirty
Apr 30, 2006

Emergency confection port.

I think I found the problem with my program: the CPU and GPU are both trying to use the blitter at the same time, loving up the registers and crashing the system

time for a crash course in semaphores i guess?

cinci zoo sniper
Mar 15, 2013




luigi is like that primitive technology guy on youtube, only computer

Wheany
Mar 17, 2006

Spinyahahahahahahahahahahahaha!

Doctor Rope

cinci zoo sniper posted:

luigi is like that primitive technology guy on youtube, only computer

:aaaaa:

my new dog
May 7, 2007

by Nyc_Tattoo

Shinku ABOOKEN posted:

terrible programmer checking in :wave:

same

Ralith
Jan 12, 2011

I see a ship in the harbor
I can and shall obey
But if it wasn't for your misfortune
I'd be a heavenly person today

oh no blimp issue posted:

why is the hello world rust example 3.2mb? why isn't lto turned on by default? why is over 2mb of that binary strings?
for comparison, all of glibc is something like 8.3MB, so for statically linking your stdlib this isn't half bad.

Chalks
Sep 30, 2009

Oh my god why is NPM default behaviour to get the latest version of packages and/or why is nobody capable of doing semantic versioning correctly?

Vue 2.5 released 5 hours ago, not backwards compatible with 2.4, rip all our builds.

Mr SuperAwesome
Apr 6, 2011

im from the bad post police, and i'm afraid i have bad news

HoboMan posted:

also i prefer basic auth because don't know how to revoke token auth

just delete the tokens from your store

if you're using JWT then this becomes slightly more complicated because the access tokens are in theory stateless (thus not in a store)

im gonna figure this out soon and i think just keeping a list of revoked access tokens in memory up until the time they would have expired should be enough

Mr SuperAwesome fucked around with this message at 10:26 on Oct 13, 2017

Mr SuperAwesome
Apr 6, 2011

im from the bad post police, and i'm afraid i have bad news
i spent 2 weeks working (not very hard) on making OAuth2 provider using a provider as a component-service-thing that you ran yourself and it did the heavy lifting for you re: token generation, you just had to wrtie a consent app. then the pig fuckers who made it totally changed their entire flow like 2 days ago, rendering my work uselss :mad:

so anyway we abandoned that POS and started using python + oauthlib + pyramid-oauthlib, and got the whole thing done in 2 days, it was quite nice

the terrible programmer part is that i really should have noticed that the first solution was actually bad, but i got sucked in by their documentation that made it look easy

Pollyzoid
Nov 2, 2010

GRUUAGH you say?

cinci zoo sniper posted:

luigi is like that primitive technology guy on youtube, only computer

luigi make the video

for real, it's really cool to see your progress, i wish i had that kinda drive. i need to start a project or something

my new dog
May 7, 2007

by Nyc_Tattoo

Chalks posted:

Oh my god why is NPM default behaviour to get the latest version of packages and/or why is nobody capable of doing semantic versioning correctly?

Vue 2.5 released 5 hours ago, not backwards compatible with 2.4, rip all our builds.

lmao

my new dog
May 7, 2007

by Nyc_Tattoo
doing all the fun tasks first - a terrible programmer (me)

Sapozhnik
Jan 2, 2005

Nap Ghost
isn't there some package-lock thing now

also aren't a lot of problems caused by people cargo culting "^1.2.3" dependency specs instead of "1.2.3"

HoboMan
Nov 4, 2010

Sapozhnik posted:

isn't there some package-lock thing now

also aren't a lot of problems caused by people cargo culting "^1.2.3" dependency specs instead of "1.2.3"

but when you add a package with npm it automatically enters "^1.2.3" and you have to manually change it to "1.2.3"
seeing as jabascript seems to attract a lot of inexperienced people and the reasonable thing to assume is your tools have sane defaults i will still blame npm for people cargo culting this

HoboMan
Nov 4, 2010

there is also this little gem from npms docs:

List of reasons your NPM build may get hosed up posted:

A dependency of one of your dependencies may have published a new version, which will update even if you used pinned dependency specifiers (1.2.3 instead of ^1.2.3)

bob dobbs is dead
Oct 8, 2017

I love peeps
Nap Ghost

cinci zoo sniper posted:

luigi is like that primitive technology guy on youtube, only computer

Luigi Thirty
Apr 30, 2006

Emergency confection port.

today we’re going to learn how to make plutonium from common household materials

cinci zoo sniper
Mar 15, 2013




*monitor degaussing noise*

AggressivelyStupid
Jan 9, 2012

Luigi livestream the Jaguar coding

Ralith
Jan 12, 2011

I see a ship in the harbor
I can and shall obey
But if it wasn't for your misfortune
I'd be a heavenly person today

Sapozhnik posted:

isn't there some package-lock thing now

also aren't a lot of problems caused by people cargo culting "^1.2.3" dependency specs instead of "1.2.3"
yeah you should really be using locks to pin the versions of your entire dependency closure; this works great in rust where it's the default.

Sapozhnik
Jan 2, 2005

Nap Ghost
yeah it's also really good in java land where every maven package depends on exactly one version of each of its dependency packages instead of having a magical faith in ~*semantic versioning*~ i'm j/s

Sapozhnik
Jan 2, 2005

Nap Ghost
systemd has the right idea imo: it's just a single version number like "235". it jumped by 200ish early on when it took over the udev project, which used the same policy.

CRIP EATIN BREAD
Jun 24, 2002

Hey stop worrying bout my acting bitch, and worry about your WACK ass music. In the mean time... Eat a hot bowl of Dicks! Ice T



Soiled Meat

Ralith posted:

yeah you should really be using locks to pin the versions of your entire dependency closure; this works great in rust where it's the default.

npm lets people overwrite old versions so two people with version 1.2.3 pinned can actually have different packages depending on when they downloaded it.

so google and some folks stepped in with yarn that hashes the contents of the package, stores a copy on the yarn servers by proxy, and stores that in a lockfile, to avoid npm bullshit

CRIP EATIN BREAD
Jun 24, 2002

Hey stop worrying bout my acting bitch, and worry about your WACK ass music. In the mean time... Eat a hot bowl of Dicks! Ice T



Soiled Meat
javascript is a failure because the people it attracts are loving morons and dont understand that tooling is important.

also the language is bad.

cinci zoo sniper
Mar 15, 2013




Sapozhnik posted:

systemd has the right idea imo: it's just a single version number like "235". it jumped by 200ish early on when it took over the udev project, which used the same policy.

imho, if i were to make things, i would probably make like

XXX-YYYY-ZZZZ

where X is a version that breaks compatibility, Y is a sub-version that doesnt break compatibility, and Z is a bugfix for current X-Y combination

Shaggar
Apr 26, 2006

CRIP EATIN BREAD posted:

javascript is a failure because the people it attracts are loving morons and dont understand that tooling is important.

also the language is bad.

yeah theres that subset who doesn't know any better, but then theres also the group that doesn't want to learn good tools, so they seek out bad ones that let them do dumb poo poo. javascript, npm, gradle, etc....

Sapozhnik
Jan 2, 2005

Nap Ghost

cinci zoo sniper posted:

imho, if i were to make things, i would probably make like

XXX-YYYY-ZZZZ

where X is a version that breaks compatibility, Y is a sub-version that doesnt break compatibility, and Z is a bugfix for current X-Y combination

congratulations, you re-invented semantic versioning, verbatim.

however, there is no way to formally enforce those semantics, so it turns out it doesn't actually work in practice.

CRIP EATIN BREAD
Jun 24, 2002

Hey stop worrying bout my acting bitch, and worry about your WACK ass music. In the mean time... Eat a hot bowl of Dicks! Ice T



Soiled Meat

Mr SuperAwesome posted:

if you're using JWT then this becomes slightly more complicated because the access tokens are in theory stateless (thus not in a store)

you can store the token in the DB still to check if it should be revoked, but JWT allows you to save yourself a call to the database by checking the expiration date before hand.

cinci zoo sniper
Mar 15, 2013




Sapozhnik posted:

congratulations, you re-invented semantic versioning, verbatim.

however, there is no way to formally enforce those semantics, so it turns out it doesn't actually work in practice.

sounds pretty terrible, yay

HoboMan
Nov 4, 2010

i usually have a semantic version number mostly because it's what users expect, but i also include build number that is just an int that gets incremented. i was under the impression this was the standard

AggressivelyStupid
Jan 9, 2012

Babies first Java work project update

Maven still good, Intellij good. I could almost get used to this.

jesus WEP
Oct 17, 2004


my favourite thing about maven is that it’s laughably easy to set up your ci

“here’s my project, here’s the pom, go hog wild”

AggressivelyStupid
Jan 9, 2012

yeah i want to kiss it on the mouth

NihilCredo
Jun 6, 2011

iram omni possibili modo preme:
plus una illa te diffamabit, quam multæ virtutes commendabunt

Sapozhnik posted:

congratulations, you re-invented semantic versioning, verbatim.

however, there is no way to formally enforce those semantics, so it turns out it doesn't actually work in practice.

the elm package manager actually does enforce it as far as is reasonably feasible: you can't upload a minor version update that changes the existing APIs, and you can't upload a bugfix update that adds new ones

it's not perfect because of course it can't detect whether you changed the actual behavior of those apis as long as the function signatures remain the same, but still it's ahead of 99% of the stuff out there

and it makes me wonder since in principle every single statically-typed package manager could easily do the same

Mr SuperAwesome
Apr 6, 2011

im from the bad post police, and i'm afraid i have bad news

CRIP EATIN BREAD posted:

you can store the token in the DB still to check if it should be revoked, but JWT allows you to save yourself a call to the database by checking the expiration date before hand.

yeah but in practice if you're doing:

1) check if expired (no DB call)
2) check DB to see if revoked

... then 99% of real world calls (i.e people arent trying to own you) will still end up hitting the DB because the clients can check if the token isn't revoked

well, if your clients are lazy and just send it themselves then maybe a bit less than 99% of calls but still the vast majority of calls will be made with non-expired tokens

so you dont really gain that much unless you either a) dont let people revoke access tokens (just refresh tokens) or b) do some clever poo poo on top of this

Luigi Thirty
Apr 30, 2006

Emergency confection port.

AggressivelyStupid posted:

Luigi livestream the Jaguar coding

it’s a lot of typing “make upload” and looking at the TV to see if the blitter is doing anything

AggressivelyStupid
Jan 9, 2012

yeah I'm down for that

jesus WEP
Oct 17, 2004


AggressivelyStupid posted:

yeah I'm down for that
unironically :yossame:

Adbot
ADBOT LOVES YOU

Luigi Thirty
Apr 30, 2006

Emergency confection port.

oh cool the 600XL I bought off atariage arrived too today

it’s upgraded to 64K RAM, the RF modulator replaced with RCA composite out jacks, and an SIO2PC installed in the case to let my computer pretend to be a hard drive

I’ve got a 1MB RAM mod I need to install in it and an SD card cartridge too

  • Locked thread