« first day (3420 days earlier)      last day (1526 days later) » 

3:00 PM
@CaptainObvious what if you remotely debugged the second visual studio
from a different machine
OH MY GOD
THEN DEBUG THAT REMOTE SESSION WITH THE FIRST VISUAL STUDIO
somehow i have 4 hours left in my day and i don't know how
im really confused
 
Plenty of time to try your remote debugging game, clearly your fate was ordained.
 
why do I want Arby's?? it's only 10am here
 
If you initialize an object's properties with curly braces, is there any way to have a constructor run after everything is assigned?
Or if not a constructor, something else?
 
When is the query in the following code executed? In the first statement or the second statement?
 // ***Create a query that, when executed, returns a collection of tasks.
            IEnumerable<Task<int>> downloadTasksQuery =
                from url in urlList select ProcessURL(url, client, ct);

            // ***Use ToList to execute the query and start the tasks.
            List<Task<int>> downloadTasks = downloadTasksQuery.ToList();
 
3:11 PM
second
> // Use ToList to execute the query and start the tasks.
 
the knife in that statue's hand in the article looks hella fake
 
@Wietlol How does that work? I mean how is the query executed in the second statement when the query is assigned to the variable in the first statement
 
because of how it works
in (extremely) simple terms, the implementation of ToList() executes the query
building the IEnumerable only defines how the query must be executed
 
@CaptainSquirrel that just soudns painful
 
hey how can i create sln file for existing dotnet core project
 
3:16 PM
Create solution, add project, done
 
i am using vs code and i want to run the project in visual studio
 
1, create empty solution
2, add existing project
3, ???
4, profit
 
You can straight up load a project in vs
 
@Wietlol doesn't IEnumerbale<Task<int>> tasksList = from t in tasks select GiveMeAnInteger(1) mean that tasksList is a collectionm of Task objects, just like how you declare and initialize a List<T>?
 
Lists are in-memory collections
some IEnumerable implementations are not in-memory
the IEnumerable interface is so small that you can easily implement them with lazy loading
 
you define where you load the information from
 
Actually it really just means you can enumerate on demand
And then things liek EF use lazy loading to implement that
 
and then, when you do a foreach or ToList or whatever, then they load the information from their source
 
@CaptainObvious at no point did i say it wouldn't be painful
remote debugging always is painful
always
 
the source can be an in-memory List, but can also be some SqlResultSet (or whatever the heck it is called)
 
3:21 PM
IEnumerable is a contract to a stream of things. So when you have your downloadTasksQuery , you didn't enumerated on it yet. In fact you can pipe the stream toward with downloadTasksQuery.Where(...) and still getting an IEnumerable
 
Nhah
That sounds more like IQueryable
 
^ than I don't get the "EF use lazy loading to implement that", because that's the IQueryable part
 
still looks fake lol
like the knife isn't supposed to be there, so soemonea dded it in later
 
Ryan Donovan on February 26, 2020
Blazor is a new client-side UI framework from the ASP.NET team. Its big selling point is the ability to write rich web UI experiences using HTML, CSS, and C# instead of JavaScript—something a lot of developers have been dreaming of.
 
3:25 PM
like bro it's not the same material as the statue is what Im' getting at
it also looks like I could take it out of his hand
 
@Wietlol in that case is IEnumerable<Task<int>> = from t in tasks select GiveMeAnInteger(1); actually IEnumerable<out collection> = from t in tasks select GiveMeAnInteger(1);, meaning that the result of the query is output to a collection (when ToList() is called) just like int number; int32.TryParse(input, out number); outputs an int value to the variable number if int32.TryParse is true (i.e. parsing the input to an int was successful)?
 
3:41 PM
sort of
the difference is that with the IEnumerable, you can separate the two statements
which is impossible in a TryParse
 
There was hype for Blazor?
 
Yes
I was a hypee
 
mr5
Yeah
My colleagues too
Me also I think
somewhat
 
not having to use Javascript is a excellent thing for backend devs
who don't like js
 
@MyWrathAcademia what you should be careful for is code like this
 
mr5
3:44 PM
cause we can finally share the same ViewModel from Xamarin App to Web Apps
 
var limit = 5;
IEnumerable<Int32> items = ListOf(1, 2, 3, 4, 5, 6, 7, 8, 9, 10)
    .Where(it => it <= limit);

items.ForAll(Console.WriteLine);
this will print "1 2 3 4 5"
but what will this print?
var limit = 5;
IEnumerable<Int32> items = ListOf(1, 2, 3, 4, 5, 6, 7, 8, 9, 10)
    .Where(it => it <= limit);

limit = 3;
items.ForAll(Console.WriteLine);
 
mr5
Console.WrteLine("1 2 3 4 5");
this will also print "1 2 3 4 5"
 
that is true
 
wow guys, I managed to successfully run my own site grubber. It's terrible, I guess, but it almost works
 
I like TypeScript. That might be why I have absolutely no hype for Blazor.
 
3:45 PM
I hate JS or TS, but I still love React
 
mr5
There's new version of TS right
 
Jack, shrug
 
¯\_(ツ)_/¯
 
mr5
Jack, joke
 
....Come Again?
 
3:45 PM
C# isn't even a great language to do front-end in, IMO. Unless they do support the null checks.
@mr5 What's new?
 
null checks?
 
mr5
Haven't checked
 
null awareness?
 
mr5
I just saw it in the VS installer
@Hozuki yeah agree
C# sucks at nulls
 
kotlin should be the new UI language
 
3:47 PM
@Wietlol Compiler guards against accessing values that could be null. I think the default would be everyhing is non-null, unless you use a ?. For example, Person? person could be null but Person person could not be.
 
I mean i probably won't use blazor for front-end stuff for a while
 
and if not kotlin, then at least Wietlang
 
I do want to do more with react tho
 
Until then, C# remains inferior for front-end web ui
 
C#8 "has" it
 
3:47 PM
And we all know how bad it is.
 
but it is unusable until at least C# 12 (I predict)
 
Meanwhile, TypeScript has perfect null guards.
So does Kotlin I guess.
 
mr5
I thought they would include the nullable reference types in C# 8?
 
Any of those is far better.
 
kotlin has amazing compile time knowledge of runtime values actually
@mr5 they did
 
3:50 PM
I bet. Kotlin surely isn't designed around making nulls default either.
 
How in the bloody fuck does it know about runtime values at compile time
What utter shit are they peddling
 
like null stuff, smart casts, etc
 
TypeScript is code-flow aware. If you have a value that is string | undefined and you do an if (value), then the entire code block knows that the value is string and not undefined. That kind of feature is very nice and you really miss it when it's not there.
 
Or you could jsut use a language which doesnt have undefined
 
string | null for you then.
Having in C# a value that is string value doesn't even warn you when you pass in null so there's that.
 
mr5
3:53 PM
@Wietlol hmm weird. it's not on by default?
I can assign null to string though
 
public void Foo(Object item)
{
	item switch
	{
		Int32 intItem -> Print(intItem + 42)
		Boolean boolItem -> Print(!boolItem)
		String strItem -> Print(strItem.Substring(0, 5))
	}
}
@CaptainObvious like this in C#
is this in Kotlin
fun foo(item: Any)
{
	when (item)
	{
		is Int -> print(item + 42)
		is Boolean -> print(!item)
		is String -> print(item.substring(0, 5))
	}
}
 
mr5
 
the compiler understands that when you do type checks, such as is Int, the value of item IS IN FACT AN integer
 
mr5
 
Yeah, TypeScript understands that too.
 
3:55 PM
wat
 
in C#, the compiler will only look at the declaration and see an Object
 
mr5
which one should I pick for creating web services?
 
even tho you just checked for the type being an Int32
 
Not the F# one
 
3:55 PM
@mr5 oh, you still can when you turned it on tho
its literally that bad
 
That's why C# introduced if (value is Person person) so you could access person.Name then. Even though it should be fully aware that value.Name is valid after the check. But nooo. It's not aware.
 
I mean go nuts with the F# one if you like, but I'd got for the C# one @mr5
 
\o
 
@Hozuki kotlin imo is a bit more mature with boilerplate and such than TS is
also, it has some more interesting support for threading and stuff that JS (previously) didnt have
 
I don't know about that. Didn't use Kotlin that much. I do appreciate the context-aware compiler tho!
 
mr5
3:57 PM
@CaptainObvious those two images are different
 
not sure if Nodejs has threading atm
 
mr5
I'm not asking which language lol
 
It does, but JS is notoriously bad for CPU-intensive stuff even if you can do threading.
 
@mr5 Yes, because one of them is the C# version and one is the F# version. Otherwise theu#re thje sa,e
 
mr5
oh wait
 
3:57 PM
JS is brilliant when you're doing mostly IO-bound work.
 
mr5
it's different language
 
Maths? Not so much.
 
JS is terrible for everything
 
mr5
@CaptainObvious why the fuck VS suggest me to do F#?
 
Because some people use F# for some reason
They also used to have J#
 
3:58 PM
@CaptainObvious It's pretty darn good for cross-platform support eh.
Gotcha.gif
 
mr5
it's even the first item in the list
 
What, JS? I'd rather use Java for xplat
 
Java doesn't run on iOS.
JS does.
 
mr5
what no
it's not. wtf
Should I go for web app or API only?
But why are controllers not included in API though?
I thought that is the main access point of every web services?
 
They are
I don't understand the seperation
Just go web app anyway
You can add as many controllers as you like without views so it's good
As long as you do MVC App
 
4:04 PM
How many here are working in Cloud environments?
 
not me hahahah
ON PREM RULES
In servers on the rack behind @Wietlol's favourite upside down clock
 
we support On Prem, Private Cloud, and Cloud
we got bought out by a larger company, so this is my new crib
got a lot to learn to get up to speed in Cloud.
very different.
 
Prepare for a very long process
 
you mean personally, or CI/CD for the company?
 
4:07 PM
they are fast, near instant deploys.
 
We were bought 17 months ago and we're still sorting stuff out
 
yep... we got swallowed fast, and will be starting a new iteration, in Jira / GCP end of the week or early next.
 
mr5
@JoJo when a company is bought by another company, do old employees gets terminated?
@CaptainObvious ha! you've been bought!
 
yes they shed about 30-40% of our company. 2 out of 6 devs on our team were let go.
 
mr5
that sucks
force termination?
 
4:10 PM
you gotta have a heart to keep up and roll with the changes. way more now, than 20 years ago.
 
Oh nobody from our place got sacked
 
anyway back to my Pluralsight vid on App Engine
 
no one that i'm aware of from this company got sacked when we got aquired
but then again, i joined after the sale
There was the receptionist that was "let go" and immediately re-hired to a different position
but only because her job didn't specifically exist at new place
 
mr5
what does it mean of "let go"?
 
4:12 PM
not fired. laid off with severance in most professional cases.
 
well that's the thing
they weren't "fired" per say
 
@JoJo So fired
 
no, asked to leave with pay for many months. :p
 
Exactly, fired
 
mr5
Are the let gos getting cash after they are force fired?
oh
it has already answered
 
4:14 PM
Generally (here at least) being fired is paid unless stated otherwise
 
Fired is a term used when a worker as violated a company policy and is terminated.
Laid off is for employess that are no longer needed, these types of employees are eligible for Unemployment compensation, whereas a "Fired" employee is not.

Very differnt.
 
no. Fired is not necessarily violates the company policy. It should not be
but I see the term is controversional
 
@Hozuki kotlin does tho :D
@CaptainObvious is it still upside down tho?
 
Yes
@Jojo what you're describing is redundancy
 
@Hozuki I dont think JS is brilliant... in any way whatsoever
 
4:31 PM
@CaptainObvious can we get a pick of the server rack
and by we i mean me
 
nonono
We need it all
We've got new shit arriving next week
23TB of all flash storage
 
hah, I can almost fit that in the ram of one of my servers
 
Sounds unlikely
 
@CaptainObvious is this part of PrOjEcT ReSiLiAnCe
 
it has 8TB of internal memory
the unlikely part is that I would have it tho
I have it available, but it will drain my wallet dry if I choose to use it
 
4:33 PM
@CaptainSquirrel You guessed it
Except this will actually solve the problems by getting rid of the shitty old storage
 
Any ideas why my ViewData is null/empty from one of my controllers. From the other controller, it is fine. All I'm doing is
ViewData["MetaTitle"] = entity.Metadata.Title;
return View(entity);
 
@Wietlol Unless you're actively paying for it you cant say you have it
 
thats true
 
@neildt Maybe entity.metadata.title is null?
 
On _Layout I have
<title>@ViewData["MetaTitle"].ToString()</title>
@CaptainObvious I checked and at the point of return View(entity); it contains the data
Pretty much both controllers have the same code
 
4:36 PM
Why not just do <title>@Model.Metadata.Title</title>
 
Because the layout is used by other controllers that currently do not have Metadata.Title as a property
 
Oh fair enough
 
I just can't understand why one controller it works and the other it doesn't
 
Have you got anything setting MetaTitle at the top of your cshtml?
 
In the view for example I have
@model UrlRouter.Domain.Entity
@{
    Layout = "~/Views/Shared/_Layout.cshtml";
}
but nothing else
If I step through in _Layout and inspect ViewData
 
4:41 PM
@Wietlol I don't understand this code becais I have not learned LINQ, IEnumerable or even lambdas. Please what are you trying to show?
 
Under Results View I see
Entry point was not found.
 
order of evaluation
 
Here i am
 
Here i go
 
at least 2 minutes after asking Lee for pictures of his rack..........
of servers
 
4:49 PM
obye
 
with no pictures of servers
am offend
 
Oh fuck
I wans't paying attention
Oh you said pick
I thought you were trying to steal some
 
i did
i meant pic
 
Don;t laugh, we're only small
 
I Mean, your cable management is immediately better than my last job lol
 
5:02 PM
It's not great though
Around back there's the leased lines and firewalls
 
what's the color coding here?
 
hey the java chatroom is pretty dead wanted to ask a question here. about virutal methods
 
Yellow = storage/ISCSI, orange= Hyper-v live migration, red = main network. Blue is management and green is ILO.
Color coding doesn't apply to the top switch because that's older and han't been repatched properly yet
Anyway bye kids, it's home o clock
 
@SamuelWakeman go for it, we've got some unfortunate souls in here that use java too
Like that one wiet guy
Warning: he does bite sometimes
 
5:08 PM
@Wietlol Are you saying that List<string> list = new List<string>(); defines that you load information from memory where as the Enumerable IEnumerable<Task<int>> tasks = from t in tasks select GiveMeAnInteger(1);defines that you load the information from the query from t in tasks select GiveMeAnInteger(1). So `IEnumerable<Task<int>> tasks = <source>. Then IEnumerable.forEach or IEnumerable.ToList load the information from the source which is why the query is executed when you use ToList?
 
so i have a class that inherits from another both have the same function name. As far as i know from google every nonstatic method is virtual in java.
but when i debug it goes to the parent classes method when i call it and not the child objects that i passed to it.
let me know if you want exact code
in base Page i have
public Page beginAddfile(){
		// here to be a virutual method dont use this. use on children
		return this;
	}
	public Page finishAddFile(){
		// here to be a virutual method dont use this. use on children
		return this;
	}
 
Yet another reason that Java is garbage
 
in child i have
public BranchOfficePage beginAddFile() {
clickElement(addFileButton);
return this;
}

public BranchOfficePage finishAddFile() {
selectOption(fileTypeSelect, fileTypes[fileIndex]);
this.fileIndex+=1;
inputText(fileDescriptionTextArea, dummyText);
clickElement(saveFileButton);
WebDriverWait wait = new WebDriverWait(getDriver(), 10);
wait.until(ExpectedConditions.presenceOfElementLocated(fileSuccess));
return this;
}
 
@CaptainObvious Why?
 
then in test
 
5:10 PM
The child version should override the parent one
 
then in separate page file upload i do
public void addFiles(int numberOfFiles, Page page) throws InterruptedException {
        for (int i=0;i<numberOfFiles;i+=1){
            page.beginAddfile();
            this.addFile();
            page.finishAddFile();
        }
    }
 
V.7
@CaptainObvious Okay ... so some serious question ... why pink though?
 
and the full thing is completed with test
call
fileUploadPage().addFiles(2, pages.BranchOfficePage());
Anyone know why the parent is being overrridden
 
@Wietlol can an IEnumerable only define information to be loaded from a query.
 
5:25 PM
@V.7 the only colour I could find at the time which wasn't in use elsewhere
Purple, light blue and grey were all in use, as we're black and white
 
i figured it out i add a noncapital letter in a methodic declaration and camel case in child
 
Although now we sell patch cables in lengths 0.3m to 30m in all of the colours so I can just colour code whenever
 
V.7
 
@Wietlol In the following code what's the point of awaiting the completed task assigned to the variable firstFinishedTask when it has already been completed and returned by the method Task.WhenAny() (i.e. there is no Task to wait for because the Task is done)? Why not just use the statement Task<int> result = firstFinishedTask.Result;?
// Identify the first task that completes.
                    Task<int> firstFinishedTask = await Task.WhenAny(downloadTasks);

                    // ***Remove the selected task from the list so that you don't
                    // process it more than once.
                    downloadTasks.Remove(firstFinishedTask);

                    // Await the completed task.
                    int length = await firstFinishedTask;
                    resultsTextBox.Text += $"\r\nLength of the download:  {length}";
 
6:03 PM
where can i find out more info on what this is called, its like shorthand for calling an active element?
((MainWindow)Application.Current.MainWindow).MessagingLabel.Content = message;
 
V.7
This is just an element's Content change
Although, why cast?
 
what do you call the (MainWindow) reference used in this manner, (code as example)
thakns
 
anyone agree this should be reopened and I can post my answer there? I had written it and it closed just as I was about to click the button
0
Q: C# difference between declaring a variable and using the code directly

Marc RousselI have these 2 simple lines of Windows Form application in C#. I always wondered if it's better to avoid the variable and use the code directly if of course you don't need it anywhere else. What would be the best one between them as not being an opinion since I need to know what would be my cor...

 
No, the reason for closure makes sense
There's no tangible difference between the two, it will compile to the same thing
 
6:19 PM
did you see my comment where I explore the subties here?
 
I personally prefer to use variables if it's not entirely obvious what the value is meant to represent
 
6:30 PM
ok, i'm finally going home guys
byeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee
 
o/
anyone here use codeproject?
 
6:48 PM
I've gotten some results from it when googling problems, but otherwise, no.
 
just wanting to know if anyone's been getting emailed about that C++ ebook
 
I believe I have answered my question: chat.stackoverflow.com/transcript/message/48697298#48697298
questionahttps://chat.stackoverflow.com/transcript/message/48697304#48697304
Answer:
The statement int length = await firstFinishedTask; means that we are awaiting the promise to produce an integer when the task is complete (i.e. we are awaiting what remains in the suspended async method ProcessURL (when its await statement is executed) to be complete before the int that was promised is returned to the variable length).
Question code:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;

// Add a using directive and a reference for System.Net.Http.
using System.Net.Http;

// Add the following using directive.
@Wietlol I have answered my own question chat.stackoverflow.com/transcript/message/48697974#48697974
 
7:14 PM
Back
Jeez that was a fun trip to A&E
 
V.7
7:29 PM
 
 
1 hour later…
8:39 PM
 
8:49 PM
Fucking epic games store
"There's an update to download"
>Update is downlaoded and installed
"There's another update to download"
>Okay, install that one too
"There's another one
>Fucking hell, isntall that one too
"Done"
>Blank screen
 
I didn't realize Epic was designed by the same people who made the PS3's filesystem
 
I mean it's a fucking web page
There is literally no valid reason for electron apps to need to do a million updates
 
omfg I just found out this problem I've been dealing with for almost 2 hours was a "divide by zero" error x-x
woulda helped if the error handler was working as intended
 
V.7
9:26 PM
@mr5 You might want to try out a uMatrix ... it's better
 
9:46 PM
Hello C# friends, I know this is not related to C#, but people from C++ aren't here for a help...
Can anyone point me to right dirrection, where am I missing something?
0
Q: C++ RtlDecompression or RtlDepression?

CastielI used RtlCompressBuffer to compress a png image. My problem is when I try to unpack it using RtlDecompressBuffer I get the following output (the image is incomplete). What is wrong on this side? Function: DWORD FinalUncompressedBufferSize; PBYTE OutputBuffer = PBYTE(LocalAlloc(LPTR, 4096)); ...

 

« first day (3420 days earlier)      last day (1526 days later) »