« first day (3386 days earlier)      last day (1548 days later) » 

4:00 PM
@BlackSquirrel Badische Anilin und Soda Fabrik
 
Backend As Serverless Functions
 
but why?
 
Because bleeding to death on the edge is our religion.
 
12 mins ago, by Captain Squirrel
I've been on the exercise bike a few times
I wanna get on the real bike soon...
I want it to be spring so I can ride it wherever the hell I want
 
are you in the states?
 
4:04 PM
So, seems I can create a tuple. But not a named one with Tuple.Create(), so it gives me a conversion error.
https://gist.github.com/tarrzan33/f250dce197c9245aff179c6853b4a7fd
 
@CupOfJava yea and it cold here
I really don't feel like struggling to go over a hill, gasping for air, but the air I'm getting is cold and stinging my lungs from the inside-out
cause there's a helluva lotta hills where I live
 
@AlRey I use a … what are they called? it's a elastic material tube, can have it over half face, covers mouth and nose, so it reduces effect of the cold air.
 
A mask?
 
you mean a CT cold mask?
 
Balaclava?
 
4:11 PM
hm maybe I will get one
it's like I already got the pants and sweatshirt to bike in the cold, but not the mask
 
Face tube ?
 
found a sponsored mask on Amazon
only $10.55
now I can bike safely and join antifa
 
And look like a ninja
 
fuckin' antifa
Antifa: Fuck the cops!
 
Float up the hill like feather on the wind
 
4:14 PM
Also Antifa: Cops help! I'm being assaulted
 
if only Antifa existed
 
Welp, I think I got it. Seems a bit complicated still but matches how I had to do it in linq. With Select.AsEnum().Select(into Tuple)
https://gist.github.com/tarrzan33/f250dce197c9245aff179c6853b4a7fd
 
Getting up hills is easier when you use your mind as well as your legs
And a lighter bike helps too :)
Pump helium into your tyres
Get reeaaaaalllly big tyres
 
I remember getting my bike for like $300 after the POS I got from Walmart broke from 2 weeks of use
and it's not like I expected the Walmart one to last very long, either
 
Hey I have a question on best way to call a method that should have optional parameters or how to set it up properly
E.g. CreatePDF(CreateContractCommand request, OrderDto orderDto, CalculateInfoCommandResult info) {} <--- is the method signature of my current method that I want to call
and I'm calling it in two different classes like
CreatePDF(request, null, info) in class A and CreatePDF(null, orderDto, null) in class B
Is there a cleaner way to call it than to pass in null for those objects?
the ones i want optional?
 
4:25 PM
public int Sum(int p1, int p2 = 0){if(p2 != 0){return p1;} return p1 + p2;}
var r = Sum(1);
var r2 = Sum(1, 1);
 
should I should assign those objects as null as part of the argument
that would read better right?
and just check for null
 
For reference types you can do = null yes or some default instance that represents an empty object.
 
OMG I've been congratulated yet again. I've been congratulated more times for my job in 4 months that I was the previous 3 years combined.
6
 
I gave you a star since we can't add emoji reactions to your comment.
Congrats!
 
Cuz you got us now
 
4:30 PM
Is it preferable to use null or empty object for reference types?
E.g. for my Dto object
Nevermind but similar follow up question. I made the changes above and looks like because i'm using an interface, I have to define the method differently in the interface as well... is that right?
Actually, no then I would need to implement the methods in that interface.
So basically this design was stupid
LOL
 
So I double-clicked a .sln file, visual studio opens, and...
 
@HéctorÁlvarez your prev job was major toxic
 
I did not click devenv.sln
 
change that VS hard
 
what the hell did VS have open before I even started it?
 
4:41 PM
devenv is VS
 
that's devenv.exe not devenv.sln
 
Exactly. Where the hell did it get the sln?
So I clicked 'Cancel' and..
 
VS is like a marriage, she's … complicated and does batshit random things when you least expect it
 
It made the exe a solution
What should I do how should I hack VS
Oh shit I pressed F5 and it started to debug a new VS instance
 
4:44 PM
You need the "Just open the solution with no funny business" plugin
 
@DKDhilip How do you even find out something like this?
 
I stopped double clicking solution files around VS version 2008, due to the outcome being completely unpredictable.
 
I stopped clicking them when they started showing the last solutions in the context menu
 
Just google "devenv.sln" lol
 
I still wince every time I see a colleague do it.
 
4:52 PM
how do I update the text in a textarea (asp.net razor page)
 
Client or server-side?
 
client, I'm using speech to text and I want to dictate into the text area
just trying to update the text area with the result
from the boilerplate project I'm working on the index page

@page
@model IndexModel
@{
    ViewData["Title"] = "Home page";
}

    <div class="text-center">
        <h1 class="display-4">Welcome</h1>
        <p>Learn about <a href="https://docs.microsoft.com/aspnet/core">building Web apps with ASP.NET Core</a>.</p>
        <textarea asp-for="Speech" readonly class="form-control" style="height:300px;" ></textarea>
    </div>
I tried doing this in my indexModel and then setting the Speech variable but it didn't work

    public class IndexModel : PageModel
    {
        private readonly ILogger<IndexModel> _logger;

        public string Speech { get; set; }
 
<script>assumed_txt2Speeach_JS_API.OnResult = function(result){ document.getElementById('Speech').value = result;</script>
^ Very sketchy on the details and full of assumptions as I have no idea how your text to speech lib works
 
is it just me or are leetcode questions really hard?
 
leetcode?
 
you mean 733t?
 
Haven't seen this site before. Is it new?
 
no
 
For a minute I thought you meant LOLCODE
You should solve leetcode problems in lolcode
downloads lolcode
 
I just did the first one, Two Sum. It's interesting but not that hard. I did it in (technically) two lines.
 
5:16 PM
@ntohl Both were
 
I'm rather happy now
 
In a functional pattern you can do it in technically one line
 
also 3sum is much harder
 
@AlRey 1337
not 733t
 
5:31 PM
It annoys me that the droid in the Solo movie was called 1337
 
headcanon: her alter ego is called 1488
 
medium.com is blocked in Egypt for months now (no one knows why), but today I discovered a hack that unblock it, just putting a dot . after com: "medium.com."
What is this?! anyone knows?
 
5:46 PM
@mshwf no way! That's crazy! I wonder why it's been blocked. Are you from Egypt?
 
Yup
 
very cool. is it hot there at this time of year?
 
Are you planning for a trip? if so, Aswan is warm but the upper Egypt is cold
 
No, was just curious. If I were to venture to that side of the world, I would go to Israel. I've been learning Hebrew off and on for nearly a year now.
So I'd be ecstatic to put my Hebrew to use.
 
Have a nice trip anyway ^_^
 
6:06 PM
thanks!
 
that's way cheaper than using a VPN
 
Yes, this is part of why this is a great hack
I tried it with some working websites, twitter doesn't work, but goodreads worked, but with no cached data like it's my first visit!
 
twitter is banned in Egypt too?
 
no both twitter and goodreads working
I was trying to understand what the dot does in the website domain
 
I know an alumnus from my school was the pm of Egypt
for like 5 months
 
6:48 PM
I just read the Queen signed the law managing and finalizing Brexit, taking effect from 31st January after the EU will sign it on 29. Bye @CaptainObvious, nice knowing you.
 
7:01 PM
Has anyone encountered problems in ASP.NET using view models with an inheritance tree in relation to Entity Framework? I have a web application that I am working on with a UserDashboardViewModel and an AdminDashboardViewModel that inherits from it. These used to be two separate VMs, and they were working.
I changed it so that Admin now derives from User viewmodel and when I call the base class constructor (UserDashboardViewModel) exception is thrown saying the ObjectContext instance has been disposed.
I am not using using blocks.
 
7:14 PM
anyone want to take a stab at solving my problem: stackoverflow.com/questions/59885630/…
its regarding entity framework and inheritance
 
When you say " relationships between objects in the same table can not be illustrated via a foreign key." do you mean like in the context of a self-referencing FK?
Also, I note that you have an implied relationship between Project and Customer, but nothing denoting the CustomerId property as a foreign key. Are you doing model building in a config somewhere?
 
in the base class
all of my classes inherit from a base class that has the key
as to self-referencing, not referencing its own record, but a record in the same table
so customer, and project both show in a table called "claims"
project has a fk to customer, but they are in the same table
if i make the customerId nullable it will work
public int? CustomerId { get; set; }
but then I am losing some benefits of a foreign key
but with out making it nullable, it won't compile
 
I cant say that I have used Table-Per-Hierarchy much in the last 10 years, so I am not the one to ask. Maybe someone else?
 
how would you approach it instead?
my logic, was to put anything that someone could subscribe too in the same table, so I could leverage one set of Ids
so i could test if you were in any form of a claim, albeit customer, office, project, region, etc
 
I havent had an occasion to require polymorphism in my models. So far just about everything that I have worked on has been done through Table-Per-Type. Each domain class has its own table (and sometimes I have domain-ified intersection tables).
 
7:29 PM
so my software handles shared but separate data for a large company that has over 100 offices, and many different roles
initially i created a table per
like Roles and then UserRoleSubscriptions
but it became far to slow, and cumbersome to handle permissions
so im desperate to find a way to simplify my API permissions
this approach changes my permission testing to must have claims(1,2,3,4) to:
sorry not to, FROM:
use must have office(1), role(1), usertype(1), and so on
user must have**
 
Ahh. Personally I would have likely started with Table-Per-Type and done some stored proc for when things got complicated. That is my go-to when it comes to minimizing calls to the database. if it is a complex query that otherwise would require lots of round trips, just pass a single set of params to a stored proc and let SqlServer handle it.
 
Huh. So we've actually finished all our tasks for the month.
 
Have you guys heard about the corona virus?
 
Yeah. We have a couple of cases here in the US now from what Ive read
 
No way! We do? Where at?
 
7:44 PM
Washington (state) I think. Looking for verification.
 
Oh wow. That's intense.
 
no, whats that
 
Slate.com is reporting that it doesn't respond to antibiotics. No fucking kidding. It's a viral infection.
 
New viral disease coming out of China.
Crossed over from birds I think?
 
7:45 PM
Hasn't it only killed like 300 people across all of China?
 
theres always a new disease they say will kill us all
 
I think bats carry it.
 
ill worry when death toll exceeds 10,000 us
 
And isn't most of China rural?
 
An outbreak of the novel coronavirus 2019-nCoV was initially identified during mid-December 2019 in the city of Wuhan in central China, as an emerging cluster of people with pneumonia with no clear cause, which was linked primarily to stallholders who worked at the Huanan Seafood Market, which also sold live animals. Chinese scientists subsequently isolated a new strain of the coronavirus – given the initial designation of 2019-nCoV – which has been found to be at least 70 percent similar in genome sequence to SARS-CoV. With the development of a specific diagnostic PCR test for detecting th...
 
7:47 PM
According to this: 365news.com/2020/01/… it has spread to South Korea as well.
Confirmed cases for China is 639 deaths. Yikes!
 
It has killed a larger portion of people who have gotten it than disease experts like. And most in a city in Central Eastern China
 
that's what they get for Hong Kong B-)
 
oh whoops, not deaths. cases! sorry
 
nah srsly I'm not sure why this isn't more heavily covered
also my dad's in SK, so um...whoops
 
I think news outlets are sometimes squeamish about reporting things like this to avoid causing panic.
 
7:48 PM
Could be.
 
that didn't stop "swine flu"
 
Disease is one thing that people are scared shitless of.
No, there were a LOT of doomsayers for that one.
 
this video shows how it can literally just make a person fall over: twitter.com/belgon9090/status/1220415814324629504
 
I don't know a single person who got h1n1, man
that profile description makes me cringe
leftists bad
 
Ever watched CGPGreys video on why there were not diseases on the American continents when the Europeans came over?
Leftists?
 
7:51 PM
"avoid Left turns especially hard Left turns"
 
didn't pay attention to the profile descriptions - it was to show affects of corona virus.
 
umm what?
>why there were not diseases on the American continents when the Europeans came over?
there were....wtf is this guy on?
Europeans brought disease to the west and caused a worse outbreak than the bubonic plague
 
I know. I am saying that there were not diseases there already that the Europeans were not immune to.
 
I guess that's what happens when one part of the world is constantly trading via ship and the other part isn't
well now I actually wanna see this vid lol
 
He made a pretty interesting case that it was mostly because there were no particularly good animals here for domestication. There were the llamas and alpacas in South America but that was really about it. In Europe and Asia, there were cattle, sheep, chickens, pigs, horses, etc. More edible and usable animals mean people start gathering into cities, which means more animals in a smaller area, couple that with poor waste management and you have a breeding ground for diseases.
Found it:
 
8:06 PM
yo yo yo
wasn't there a confirmed case in the US
 
Yup. Washington state somehwere
 
it's a good thing that I'm just a cup of coffee
 
Mmm. Coffeee.
I actually have coffee trees growing on our property.
 
wow, I got a peach tree
 
Still a couple months away from fruiting again.
Lets see, we also have Avocado, Cherimoya, Pomelo, Lemon, Rambutan, Lychee, Mango, Figs.
 
8:13 PM
why is it that most developers in chat are also farmers
 
Hmm I didnt know that was a thing.
/shrug
Also we have bees
 
any developers here support Trump?
 
when I was in the javascript room almost all of them owned livestock
 
I am not a Trump supporter. Was just curious.
 
Also not a supporter. I don't identify with either party, but I really don't identify with him.
 
8:16 PM
@TomCrosman I'm not sure what you're looking to get out of that
 
pure curiousity
 
@CupOfJava We really dont have enough land for livestock, except chickens I guess.
Only 1/2 acre
 
I don't think supports would actually say
 
i think they would
and im not here to bash, but i've only met one programmer who openly supports trump
and he's very proud of it
 
ok
 
8:19 PM
Yeah, I do my best not to talk about politics. I am burnt out on it. Every election cycle just bleeds into the next one. It is exhausting.
 
yeah i wasnt gonna go further than a poll
 
This is the beast we have made for ourselves.
 
im liberal when it makes sense, and conservative when it makes sense
i don't pick a side and say its right
but i'll end it there
 
Why in the name of all that is holy are we unable to get a usable VPN? The technology has been around for a while now.
 
wym?
 
8:23 PM
I have 75 ms ping to the office VPN server, and I drop like 20 times per day. And the VPN client REFUSES to cache my danged credentials so I have to type type type log in every fricken time.
NERD RAGE!!!
Boss has a much lower ping to the office and he also drops often, so it is not a latency thing. The VPN server just vomits users off of it I guess.
 
@CupOfJava wait, is them owning livestock supposed to mean they support Trump? xD
cause my ex's parents owned livestock and they didn't like Trump at all
mostly cause they knew Trump's plans to eradicate the ACA would make it way harder to take care of their daughter's medical needs -- and they were already having trouble as it was
 
@AlRey I think you're reading the chat backwards
 
damn it your icons are extremely similar
all you greens look the sameeee
 
my green is better
 
I sometimes I feel like I"m the most right-leaning person in the chat (except for J.Doe), yet tests classify me as a socialist
 
8:35 PM
@CodeWarrior have you had problems with the lemon trees?
 
8:57 PM
@CupOfJava They were on the property when we bought it, and we havent done anything with it. It only has one or two lemons at a time on it, and they are hella sour.
We have to use one heck of a lot of sugar to make lemonade out of them.
@CupOfJava are you a telecommuter?
Just wondering if the developers who get on SO Chat are often remote and dont have other devs close at hand to bounce questions off of. if they are, then it is more likely that they would have the availability of have land enough for farming or some kind.
 
@CodeWarrior sometimes, other times I work on site. I work contract so it changes.
 
@AlRey Maybe that's good?
 
Gotcha. Personally I live on the Big Island of Hawaii so pretty danged rural (and remote).
 
gtg long day tomorrow, bye
 
see ya
 
9:06 PM
Hawaii? wow
we have close to the same weather
I'm in Florida
 
@Squirrelkiller if what I say is true, wouldn't that put most people here on anitfa levels of left? xD
anyway gnite amigo
 
Pretty close I imagine. We stay between about 60 and 80 degrees throughout the year. Which means we get fruit off of trees almost all year.
And the bees produce honey continuously.
I get something like 15lbs of honey every two weeks.
Well, I did. Both of our hives collapsed a few months back.
 
just do ctrl+r
 
I wish it was that easy. Those two hives started as a swarm that we caught a couple of years ago. We built it up, and split it into two hives, about this time last year. Small Hive Beetles and Varoa mites did them in. We were inspecting every week, and doing everything we could to manage it, but the damned beetles would not be defeated.
Gonna drop off. See you guys
 
9:36 PM
posted on January 23, 2020 by Phil Haack

Today’s my birthday so naturally the topic of burnout comes to mind. For the past couple years, I’ve been coping with varying degrees of burnout. This is not to be confused with being a Burner which is something else entirely.

 
user8729657
9:53 PM
I'm at work and boss wants me to deploy a mobile/desktop app to devices that join the network with ease, no need for install messages is this possible?
 
isn't this what you'd use something like Intune and group policies for
you can't just push software onto anyone who connects to your wifi, that's, uh, malware
 
user8729657
But, it's the companies private network, only company devices will be connected at any point.
 
that's still malware
I mean yeah it's possible but I'm not sure I feel comfortable explaining
 
user8729657
If it's possible then, I guess i'll find a way.
 
If it's only company devices, surely you can just ask or make people join the domain
or if the company controls all the devices, you can flash them all with the same image
I don't know if this is a BYOD scenario (in which case you can have people domain join and get stuff pushed to their device) or if the company is handing out laptops (in which case you can flash them all from the same hard drive image and hand 'em out)
 
user8729657
10:17 PM
Thanks @Grace, it's just I'm new to the .NET Framework. I was looking at different approaches to this problem too.
 
to reply from a post from yesterday, @Squirrelintraining I like LaTeX a lot, it's my go-to document typesetting system and I like it a lot better than something like word.
and back to Ovie: It's not really a .NET problem, is the thing

like, this isn't something people typically write code to do. there's products out there that do exactly this
like, there's tools to do this built into Windows
 
user8729657
I mean there are articles like this that tackle the problem. docs.microsoft.com/en-us/powershell/module/…
 
user8729657
0
Q: Copying files remotely with PowerShell

ToshiI am working from Windows Server 2012 R2 from that server I am connected to a internal network, to which there are numerous computers that I have access to. What I want to do is based on a specific users IP address in that network I want to pull 3 specific files out of that computer and make a co...

 
Do you just want to copy files onto a new machine?
Like, if you want to write a powershell script that installs the right software for 'em, go nuts
 
user8729657
Yea, it wouldn't be a big task. Like I said I'm just starting to get to know more about the .NET framework and I'm lacking a bit in C#
 
10:25 PM
I would argue that writing yourself a c# program to do this might be the wrong way to go about it, but follow your dreams
 
10:40 PM
I agree with Grace, don't write a program for a company if you don't know the language. You might do more harm then good.
 

« first day (3386 days earlier)      last day (1548 days later) »