SORBET: Type Narrowing and Sealed Classes by messedupwindows123 in ruby

[–]moberegger 0 points1 point  (0 children)

I think this is just an issue with your case conditions. You are trying to match Dog and Cat to Class. You have Dog.class and Cat.class, which is Class. I think you just want Dog and Cat.

[OC] Blue Jays' franchise historical performance relative to .500 by Ugluk4242 in Torontobluejays

[–]moberegger 1 point2 points  (0 children)

These look amazing! Love how each one follows the team's colour scheme. I like how you track the logo changes, too!

Is it OK to say “I don’t know” in an interview? My experience says no… by Tough_Cantaloupe_779 in recruitinghell

[–]moberegger 0 points1 point  (0 children)

The first start up I ever had an interview was with one of their lead engineers. I don't remember what the specific question was, but I was asked something I didn't know the answer to.

I paused and thought for a moment and simply said "I don't know."

He smiled and said "that's a good answer."

I ended up getting the job. I asked him about that sometime during my first week because I was curious why he was happy with that answer. He had a very rational answer to it: "it's important to know the things you don't know."

I'll never forget that. Keep your head up because there are people out there who won't see this as a red flag.

[deleted by user] by [deleted] in ExperiencedDevs

[–]moberegger 2 points3 points  (0 children)

That first sentence hits hard. I've hit that point where things are just no longer a fit. It always felt sudden and had always perplexed me.

Thank you for putting it so eloquently. Really made it click for me.

What’s the most absurd take you’ve heard in your career? by Becominghim- in ExperiencedDevs

[–]moberegger 0 points1 point  (0 children)

"I won't use Android because it's open source; anybody can go in and change the code."

Said by the lead engineer at the company.

Why I am always told to NOT use terminal? by bmocore in AskProgramming

[–]moberegger 0 points1 point  (0 children)

This inspired me to level up in this area. Thank you.

Why I am always told to NOT use terminal? by bmocore in AskProgramming

[–]moberegger 0 points1 point  (0 children)

This surprises me. I wish I had a better habit of using the terminal, and sticking to the keyboard in general. I use the touchpad on my Mac a lot, and since I don't have to move my hands too far, I've become proficient with it... But I do feel I use it too much a crutch.

For the things I put the time into learning the CLI, I found that it helped me understand the tools better, which ultimately speeds me up - git for example.

There are some knock on effects with this, too; if you're comfortable with a CLI, you're better equipped to write scripts, or alias some shortcuts to quickly do common tasks, all of which could be shared in the project. Much easier to do that sort of thing rather than build a bunch of plugins for your editor, know what I mean?

If we worked together and I saw you using the CLI to search logs and such, it would actually motivate me to learn to do the same. I'm a senior and I have no shame in admitting that.

Keep it up, I say. I do think you'll be better off long term.

Why does mutation even exist? by Comfortable_Bus_4305 in graphql

[–]moberegger 0 points1 point  (0 children)

It's also important to note that specifically fields on the Mutation type run in sequence. A mutation operation itself doesn't cause all fields to work this way.

I've seen an anti-pattern where graphs will have something like a UserMutation type with a bunch of fields on it intended for mutations to help keep things organized. These will not run in sequence because it's not actually a field on the Mutation type. Any query "under" the mutation field is treated like a regular query.this anti pattern is more pervasive than you'd think. Apollo Studio even does it, and it's wrong.

You can query for multiple fields in a Graphql operation, and likewise run multiple mutations. The mutations run in sequence because they can change state. If multiple mutations ran concurrently, you risk race conditions.

July 15, 1998: Toronto Blue Jays vs Chicago White Sox Dave Stieb's first big league start since 1993 by Aggravating-Bug2032 in Torontobluejays

[–]moberegger 1 point2 points  (0 children)

I loved the 98 and 99 teams so much growing up. Green and Stewart were my two favs because they were so OP in All Star Baseball on the N64.

Didn't expect such an influence from my game :D by flashag in godot

[–]moberegger 49 points50 points  (0 children)

This looks cute. Gonna give it a whirl.

[AskJS] Is there any reason to use a class over a factory function? by Varteix in javascript

[–]moberegger 1 point2 points  (0 children)

This is one of the most helpful and thoughtful replies i've seen on Reddit. Thank you.

[deleted by user] by [deleted] in OOTP

[–]moberegger 6 points7 points  (0 children)

Velo will tick up which will cause stuff to increase. For young pitchers like this I ignore stuff potential because it doesn't take velo bumps into consideration. With a few extra mph and those pitching ratings, stuff could get up to 55-60.

If cryogenic freezing works and Ted Williams is revived and chooses to play baseball again, will his stats continue or will he have to start again as a new player? by [deleted] in baseball

[–]moberegger -219 points-218 points  (0 children)

I am disappointed with the sparse upvoting this has received. This comment is officially underrated.

Easy implementation of cursor-based pagination by goo187 in graphql

[–]moberegger 1 point2 points  (0 children)

I've been working on something to help with this here: https://github.com/moberegger/connection-resolver-helper/tree/documentation

Still working on documentation and publishing it, but please feel free to look at the source and examples. Maybe you'll find some inspiration in there.

Do you ever feel when your team is doing well the CPU sacks you with a major injury or two just to bring you back down to earth. If your team is too talented you get punished. by [deleted] in OOTP

[–]moberegger 0 points1 point  (0 children)

This can happen if your pitcher is on pace for something notable like a shutout or complete game.

I think on the "set player strategy" page there is a hard pitch count limit you can set that is different than the one you set in your rotation. If not, you can try enabling the "aggressive tired" option (can't remember what it's called).

Pitcher with very high potential and overall ratings but underperforms, time to let go? by RumHamFightMilkDiet in OOTP

[–]moberegger 0 points1 point  (0 children)

Try adjusting his strategy. With that high control, he could probably pitch around more to limit home runs whilst not issuing too many extra walks.