« first day (1132 days earlier)      last day (1963 days later) » 

1:00 PM
Hey Pimgd!
 
> Courtesy [Monica Cellio](http://meta.stackexchange.com/users/162102/monica-cellio).

Going to add a link from the topbar in the immediate future, but didn't see a reason to delay at least getting this out there.
 
oh hey Tim Stone is doing work on SEDE \o/
 
@Quill Yeah, I agree. However most users do not think that far, they just vote and leave.
 
Hey @Pimgd ! (Still get used to this chat haha)
 
@N3buchadnezzar If the poster has a really offensive username, he should be flagged instead of downvoted.
There aren't a lot of those around though.
Especially on CR.
 
1:05 PM
they're somewhat common tactics from new users on SO though -_-
 
@Quill We don't mention that alien planet here.
 
well that alien planet pays the bills that keeps a roof over our chat heads
2
 
Fair enough.
 
Zak
@Quill I don't consider them when voting, just when choosing a question to go and look at.
@Quill Though admittedly, not *quite* as large a share as it used to. IIRC, these days SO accounts for only 70% of all SE traffic.
 
@Mast I should start a user with the name "Comic_sans_is_alright_I_guess"
 
1:09 PM
only 70%
 
Mwahahah
I just disabled direct merge commits being pushed to master
rebase, pull request or sink
 
Zak
CR is a whole 00.36% of SE traffic ^^
 
woo
 
The one percenters
 
Less than one percenters*
 
Zak
1:12 PM
the 0.1 percenters ^^
 
We are not locked in here with SO, They are locked in here with US!
 
0
Q: Avl trees with ids

Theoktistiim a student in Greece at Aristotle Univercity of Thessaloniki in the first class and i have to do the same project with him Managing IDs using AVL trees m new in c++ and its very difficult for me to use it....is it possible for someone to tell me how to start and organize the project?

 
@CaptainObvious Burn
 
1:30 PM
@Zak source?
 
0
Q: C++ Wide string utility class

Alvaro CarneiroThis is my first time posting on codereview :-) (first time posting in SE actually). So, sorry if this post is incorrect. I created a class to add functionality to c++ std::string (std::basic_string actually), let's call it String. I would like to know, what changes to do to String to boost it ...

 
1:46 PM
Woops, I've been a bit of a twat and introduced a major bug related to transcations in my app :D
 
@N3buchadnezzar I understood that reference.
 
inadvertently created repositories with singleton lifecycles whereas other instances are transient, which led to an interesting scenario where one DbContext cached a value but another refused to admit it existed
 
None of the people over at SO seem to understand though.
 
@overactor I was thinking about posting the gif. But codereview seem to dislike videos, animation and fun.
 
@N3buchadnezzar we like videos animation and fun, wej ust dislike oneboxed videos/animations
 
1:48 PM
Yea, just put them behind a link.
 
container.RegisterType<A>(new InjectionConstructor(
  container.Resolve<B>()
));

// vs

container.RegisterType<A>(new InjectionFactory(_ => new A(container.resolve<B>())));
 
First example had a singleton B. Second one had a transient B. woops.
 
If you want to improve existing working code please post it on Code Review, that's exactly what it is for. — Gerald Schneider just now
 
It's only there because Unity makes it impossible to inject configuration values into a constructor
 
1:50 PM
@overactor We told you not to do that.
 
@overactor Because it's distracting
Please put that behind a link, don't onebox it.
 
I have a javascript question....
 
@Malachi :D
 
sorry :(
 
I feel useful :D
 
1:50 PM
I can't remember the terms for some of the things, otherwise I would google it
 
@DanPantry With great power comes great fun.
 
Sure.. just try your best to describe it @Malachi
 
vm.returnUndefinedIfEmpty = function(field) {
field = field === "" ? undefined : field;
}
 
Still no takers for this?
3
Q: Scraping the date of most recent post from various social media services

A_S00Task I have a large spreadsheet where each line should include: The URL of a social media account A field indicating whether the account is "active" A name and UID number for each account I have to find if the activity field is accurate for every account on the list, and fix any mismatches. ...

Welcome the new guy.
 
equivalent of an out in C#, I think
 
1:51 PM
@Malachi Okay, so what's the question
(Also, please don't ever return undefined - use null)
 
I want that field that is passed in to also be returned.
 
by reference ?
 
You can do field => field === "" ? null : field
 
^: return field || ""
 
though I think returning string | null is probably a bad idea..
what's your use case
 
1:53 PM
I guess I am going to be passing a model into the field parameter. does that mean it is okay the way it is?
 
I mean, it'll work
but you shouldn't ever return undefined to indicate the absence of a value
use null
I'm confused as to why you're doing that anyway - why can't you return true/false o.o
 
monking!
 
yo
 
I am combining like 6 functions that are essentially doing this, I just saw this and wanted to dry it....I am not sure what null will do to this code....
 
@Malachi if you're worried about null you should also be worried about undefined.
 
1:55 PM
I am going to go with the null and see what happens.
 
unless your code is exlpicitly checking if undefined === undefined...
@Malachi I hope you're not :P
 
I mean it's not like I am testing in production or anything
 
Wall? That's a new one.
 
This type of SE is for people who are experiencing specific problems with their code. For improvement suggestions, go to CodeReview as Selvin suggests. — Lexi 48 secs ago
 
1:57 PM
> I'm not sure if it is the right place to share such a wall of text
 
These types of questions are off-topic here but may be acceptable on Code Review. — PM 77-1 18 secs ago
 
still, derp to type "wall" based on that
 
@N3buchadnezzar that term has a whole different meaning to me, --> en.wikipedia.org/wiki/Outlaw_motorcycle_club
 
@Pimgd There are wildlings on the other side of that wall.
 
@N3buchadnezzar HOLD THE DOOR
 
1:58 PM
TEAR DOWN THE WALL!!
 
@Mast I may when I get home, but I'm working on things, and have been super tired lately, ):
 
Brodoor
 
no spoilers please I get my eps late
 
@DanPantry that's the last episode I saw, will be catching up this weekend - no spoilz plz! :)
 
1:59 PM
@Mat'sMug I'm not, dw
 
Morning everyone.
 
@Mat'sMug John Snow still does know nothing.
 
@N3buchadnezzar I know this is you trying to be funny but (and this is just my opinion) I think that you should try just not to when it comes to spoilers
 
nvm
 
spoiler: they play a game. and said game is about thrones
 
2:01 PM
@Pimgd But dan started it..
 
@N3buchadnezzar I said nothing that spoiled anything
 
hey there @rolfl
 
Is there a compendium of previous community challenges?
 
Let's just make a room rule to not mention anything from the current season of GoT.
 
2:02 PM
GoT is off-topic for the room anyway, if people really want to discuss it could simply make a room just for that.
 
@Legato Nth
 
@Legato We can discuss off-topic stuff as long as there's no site business going on. There wasn't initially, but now there is
 
@syb0rg Yup.
 
@syb0rg yup
 
The micromanagement in this room is getting intense
 
2:04 PM
@JoeWallis Yeah, I could do the latter, but I wondered if there was a post that actually has a list of what has been done already vs. going through everything.
 
@Legato Ooh, my bad
 
@JoeWallis No worries, I appreciate your input.
 
@DanPantry Has anyone made a GoT esolang yet?
 
oh god no
 
catch (JSONException ignored)
        {
            assert false;
        }
legacy coooode
 
2:06 PM
The lolcat langage is bad enough
 
so much for trying to "parse json and see if it fails or not"
 
@Quill Build a wall around it
 
Force-pushing in PRs to update them. Yes/no?
 
I'm voting to close this question as off-topic because to codereview site — Shubhank 16 secs ago
 
2:13 PM
I need to remove a commit from a PR. I could revert it but that leaves a commit being added and then removed for no reason with no residual changes, so I want to rebase it to remove it
 
@Duga Yes.
 
posted my first Code Review in a first months
 
got my first upvote on programmers :-)
4
 
@Pimgd I found this funny imgur.com/ViPiGJc. Long time since I had seen it.
 
I am at work
Whilst this is probably funny to most people
I would rather not read penis jokes at work
...
maybe I shouldn't be in this chatroom then...?
 
2:17 PM
Maybe. However it was about maths..
 
it's funny because it's about a penis, face it
 
It would be funny with other body parts as well
@Pimgd I would rather not face it.
 
going back to work...
 
1
Q: Populating a Fragment/Activity dynamically on Android gets ugly

JaythakingSo here is my ugliest fragment of my application, I tried to reformat as much as I could but it's still pretty ugly. Basically, what I'm trying to do is receiving through an API call a JSON who tell me what type of field to create dynamically (Edit text, checkbox, Multiple choice, single choice...

 
2:29 PM
octopus says no
3
 
@Quill Hi there too
 
@JeroenVannevel know much about EF?
 
bits n tits
what ya need?
 
We had a bug with DbContext lifetimes. I've fixed it now properly, but my colleague used AsNoTracking() everywhere it presented itself
I understand AsNoTracking has some performance benefits, but at this point I'm just thinking it's clutter
Confirm/deny?
 
2:33 PM
euhm
It's not clutter if it fixes the issue
It depends on if it's the right solution
 
It put a bandaid over the issue
 
For which I need to know the issue first
so to sum it up: what's the issue?
 
The actual issue was that we had a DbContext that had the lifetime of an application inside of a service
But every other service that used DbContext had a transient lifetime
So when we updated a transient DbContext, the singleton DbContext didn't "see" the new values
 
AsNoTracking() obviously fixes this by going directly to the DB
 
2:34 PM
no, I think they have their own caches
 
But the correct answer is to fix the Unity configuration, which I have
As each DbContext is transient and is just used for reading data in these instances (and is disposed at the end of a request), I'm thinking that AsNoTracking in this situation either provides minimal benefit or maybe even potential harm
There's no large-scale reads going on here, it's just single items
 
I guess you know your options then.
1. Use AsNoTracking() everywhere and get extra DB load on a no-cache lookup tradeoff
2. Use 1 DbContext so everything shares the same cache
3. Attach objects to other DbContexts so it gets tracked by them
 
It seems that the correct answer is to remove AsNoTracking and just fix the DI (Which I have)
 
It should be mentioned that DbContexts are made to be short-lived objects
 
Yeah, like I said, they are.
They're all transient
 
2:37 PM
although I don't think it is an issue to have them longer-lived
oh okay
right
 
there was just a bug in DI config where some were accidentally set to live the lifetime of the application
 
I don't see why this solves your issue though
 
1
Q: Simplifying Code for my Plugin! (enquire.js/jquery)

MarleyThis should be a walk in the park for any seasoned jqueryists. This code operates as intended, but only with two operational timers running, I need the resize event in the match section as I need to retrieve the window width as it is updated, but only if it is within the 600px or less constraint...

1
Q: Automating New User Creation With C# Web Service

BassieI created a web service which can be called from a form to add new users to the system. The final service will add users to Active Directory and Exchange in the required format (please not that FirstName and LastName are required fields in the form, so they will never be null): using System.Col...

2
Q: Mars Rover Simulator

leoOrionProblem Statement Consider a rover and a plateau of size nxn. The rover takes three type of instructions L,R and M. 'L' and 'R' rotate the rover in the left and right direction. 'M' moves the rover one step forward in the direction it faces. Input: Plateau size, Initial direction, Ini...

0
Q: get statment after dotpeek

user108567I need to refactore the machine code public int? Code { get { int Tmp = this.Source.Code; int GuardVar731 = Tmp; bool Tmp2 = true; bool Tmp3 = Tmp2; int? result; if (Tm...

 
Every DbContext is a separate object through DI
 
@JeroenVannevel Because one of the DbContexts was created at the start of the app and that single instance was passed into some instances
 
2:38 PM
They still have separate caches..
oh
 
AsNoTracking() caused that singleton DbContext to not consult it's cache
 
gotcha
 
Because that DbContext would check once, realise the value hadnt' changed, and never check again (because that value was tracked)
 
yeah that's silly
fix DI and slap coworker
 
So I've fixed that, but there's still AsNoTracking littered everywhere
I'll just git rebase -i and remove it, then force push PR, get it signed off and off we go
 
2:47 PM
0
Q: get statment after dotpeek

user108567I need to refactore the machine code Code: public int? Code { get { int Tmp = this.Source.Code; int GuardVar731 = Tmp; bool Tmp2 = true; bool Tmp3 = Tmp2; int? result; ...

opinions ?
 
decompiled code
 
that I know, the question is closing or not where I would go for closing
 
yes, lack of context?
I mean, right now it smells like obfuscation
 
I took "unclear what you are asking"
nevertheless the "refactoring" he did on the Code property is stupid.
 
Zak
Late, I know, but I've actually been working for a change ^^
 
2:54 PM
oh crap. red bull crash 1 hour earlier than expected
 
yes but how do you know the total traffic
 
Zak
@Pimgd I counted.
 
pfff you didn't even use your mad spreadsheet skills?
 
Zak
@Pimgd I can count really fast
And trust me, that would not have come out cleanly in a spreadsheet.
Intuition (Born of experience): If you try, you'll get the entire table pasted into a single column
 
regex extract, regex replace
 
Zak
2:58 PM
@Pimgd And how is this faster than just scrolling and counting again? :p
 
precision?
 
Zak
@Pimgd I'm willing to bet reasonable compensation that my number is within margin-for-error of the actual figures.
 
probability?
 
Zak
@Pimgd Depends on precise definition of "Margin for error"
 
0.01%
(as many significant digits as you gave)
 
Zak
3:07 PM
Sure ^^
 
0.003222972314
2 hours ago, by Zak
CR is a whole 00.36% of SE traffic ^^
Inspect source
 
{
get
{
int? code = this.Source.Code;
if (code != null)
{
return code;
}
return null;
}
}
 
one line
 
visits-per-day
 
3:09 PM
return this.Source.Code;
 
gives you large text dump...
paste in IDE and use multi-column edit to strip the first and last parts of the lines
gives you raw numbers
12754065.5 total visits per day on average according to that page
and 41,106 on average for CR
gives you 0.32%
not 0.36%
 
uh-huh. BIG difference!
hi @LindsayMorsillo! welcome to the 2nd monitor!
 
grep is just too awesome
and so is multi-line edits
 
@Malachi exactly
 
0
Q: Active Directory Searcher class/API

Michael Brandon MorrisThis is intended to be a model for an application that queries an Active Directory. It can return IEnumerables of the following: Users, given context. Groups, given context or users. Users, given group. User Group Membership, given context or users. User Direct Reports, given context or users. ...

 
3:15 PM
@Zak tbh I didn't want to take a bet on that though because I have a feeling you'd be off, but I didn't know by how much
 
@Pimgd Hey! where you not supposed to be working?
products = [xrange(1, 10), permutations( range(10), 2)]
    for prod1_range in products:
        for prod1 in prod1_range:
Any tips why this fails? (python)
 
I need fun distractions from time to time
 
That first for loop shouldn't be indented?
 
@syb0rg The formating got messed up when importing into chat.
 
@Heslacher just need to make sure that this.Source.Code is nullable, right?
 
Zak
3:18 PM
@Pimgd I forgot that, thanks to displaying as 4 S.F., I really shouldn't have been *quite* that sure of the precision ^^
 
Who starred my last comment lol
Whatever, I love stars
6
 
@Malachi it seems that Source.Code is int so return new int?(this.Source.Code); would do the trick
 
@syb0rg not as much as I like to give them.
 
@N3buchadnezzar What's the error?
 
3:22 PM
>>> products = [range(1, 10), range(10)]
>>> for prod1_range in products:
	for prod1 in prod1_range:
		print(prod1)
 
@JoeWallis I figured that I should really not been doing what I was ddoing :p
 
works
 
Whoops... Didn't know about codereview. And @Pointy you mean like: — xboxremote 20 secs ago
 
@DanPantry I don't know if this is the case, but something breaks on a null reference. I am going to see if I can fix it by going back to undefined
 
@Mat'sMug Thanks, new here mostly just lurking...
 
3:30 PM
IKR, this is quite possibly the best place to lurk :)
 
@Mat'sMug Seems like you like to use Duga to lurk.
 
Duga is @SimonForsberg's pet, I'm not using her
 
@Malachi Something is probably explicitly checking if (foo() ===undefined) instead of if(!foo()) :\
Duga is a strong independent robot that don't need no man
 
@DanPantry I think I broke the code somewhere else.
 
#unittestswhere
 
3:33 PM
I'm voting to close this question as off-topic because it is asking for code review. — Felix Kling 59 secs ago
What's the difference between asking about a performance issue and asking for a code review? I don't think I'm asking for a code review here, I'm asking a specific question based on specific parameters, right? — xboxremote 9 secs ago
 
@DanPantry #nothere
 
0
Q: C# Deep Clone Child Class

Nick SpicerI have an Abstract class "Player", the player plays several games of Roulette (samples) and for each game the desired player is cloned into a session method. for (int i = 0; i < samples; i++) { IList<int> sessionStakes = this.Session(player.DeepClone() as Player); this.maxima.Add(session...

 
Greetings, Programs.
 
HELLO, USER\0
 
3:50 PM
Hi!
 
EEEEeeeeek
pretends to be working
Takes up huge blank excel document
 
.standart-scheduler .k-scheduler-content .k-scheduler-table tbody tr:nth-child(n+17):nth-child(-n+36) td {
    background-color: #f8f8f8;
    border-color: #c5c5c5;
}
that selector is awfully specific lol
 
Maven says that package com.mycompany.stuff.morestuff.yada.yoda.foo does not exist, it worked just fine before I changed some maven versions. The dependency does exist in Nexus repository, there are no compiler errors in Eclipse, WTF am I doing wrong
 
@SimonForsberg proxy configuration perhaps?
 
No change in proxy configuration.
hmm... seems like it might be related to the merge I recently did, I will check the hg diff
 
4:04 PM
This should be on CodeReview — Macro Man 10 secs ago
 
0
Q: Why my CUDA program runs faster on the CPU?

DokkatI'm a very new to CUDA, so I'm still trying to understand how to make the best use of the GPU. I've ported a C algorithm to it. This algorithm works by loading the memory with an initial input, then calling a rewrite function, which rewrites 128 bits of memory, consecutively, until we arrive at a...

 
Damn Mercurial. Someone merged away my dependencies... And by "someone" I mean me.
 
Hmmm
trying to generate elements in permutations(range(1, 10), 4) < the range(1, 10) might be different
such that the elements are less than some number, hard
 
4:25 PM
@bipll -- "Don't do that then!" The same applies to the classes defined in the question. The nice thing about const_cast is that its use is searchable -- and rightfully questioned during code review. C-style casts are a bit harder to root out by a human review, but compilers are quite good at finding them. — David Hammen 33 secs ago
 
4:35 PM
> Me at my second rodeo: #this is not my first rodeo".
2
 
4:51 PM
Hello
 
Hello?
 
Hello.
 
Hellol
(embedded lol in the hello)
 
0
Q: UIButton Subclass - Overriding getters to return placeholder/default values

JALI'm in the process of converting a custom UIButton from Objective-C to Swift which has custom properties and default values for those properties: MyButton.h @interface MyButton : UIButton @property (nonatomic, strong) IBInspectable UIColor *buttonColor; @property (nonatomic, strong) IBInspecta...

 
5:08 PM
A graph of supertypes of string[] in .NET https://t.co/kxKsfOpKve
O_O
it's not quite high enough resolution to see the actual type names, but you can still see it's a big, tangled web
 
I searched on ebuyer for "European Keyboard" and it redirected me to a monitor
 
Monking
 
Is that ebuyer's way of telling me to get a tablet?
 
it's ebuyer's way of telling you to use Google instead
2
 
but I'm already getting stuff from ebuyer.. :(
 
5:29 PM
Thanks Simon. What a great answer. The GetDisplayName works like a charm (though it is scary to use DangerousGetHandle - i wonder if this would pass a code review:). However the naming convention doesn't seem to stick properly. Even in the above screenshot that i've added, Microsoft-SQLServerDataTools isn't being placed under Microsoft. Also, when i call GetLogNames() i see Microsoft-IIS-Configuration which isn't showing up under Microsoft in the screenshot above. I think there may be another "hidden" API like the one you discovered. — Mark 20 secs ago
 
Fine, serious stuff only, got it.
 
I'm still ecstatic that my joke question made it to the hot network questions list.
 
it is a little odd that messages moved to a different chat room stay in the starred list
 
5:33 PM
refresh the page :)
 
there it goes - just took a little while
 
Stars are not lightning.
 
Sorry for starting offtopic discussions mat :p
 
Sometimes they take a moment to update.
Also, @Mast you didn't remind me the thing last night.
 
5:36 PM
no problem. BTW we love here.. it's just we also like to keep the official CR chat roughly on-topic, so that if a new user pops in they don't leave running, wondering where the main chatroom might be.
4
I only moved it because it started dragging - the original comment was fine all by itself :)
gosh, and I just killed chat again?
4
lunch time, bbl
 
GOOD JOB @Mat'sMug
2
Woops
Caps
 
6:00 PM
so what is the problem? or are you looking for code review? — Kiril S. 27 secs ago
 
0
Q: Lookup class to get descriptions of values

AndyHFollowing yesterday's advice on my Customer class, I have now created a new class which is for looking up descriptions from a MySQL database. I have a Lookup table which contains type, name, value, and descriptions. Here's a basic example of type = customer and name = state Customer States N...

 
6:21 PM
0
Q: Is the re-opening queue enough?

Bruno CostaWith enough reason this question was closed by being out of scope. Meanwhile I gave some advice to the OP and the question seems to be in shape for a re-open vote. I already placed my vote. I also made question to wait some time before bringing this to meta because I wanted to verify that the r...

 
Zak
Upvote for the title alone
14
Q: I can has(kell) cheezburger?

Michael Brandon MorrisThis is a very rudimentary lolcats translator (it only works on the phrase "Can I have a cheeseburger") in Haskell. This is my first ever attempt at Haskell (or any functional programming language). I am sure that my code is absolutely atrocious (the documentation was dismal) but it works. Teh C...

 
6:36 PM
:D
Yeah, I did that whole thing on purpose.
 
I'm not sure if it's cheesy enough
 
@Zak A bit cheesy title though :-D
 
@Zak 200's post is appearing at the bottom for me, is it for you as well?
 
"This question shows research effort; it is useful and clear; it has a sick pun in its title"
8
 
@syb0rg sort by votes
 
6:38 PM
@Mat'sMug Sort by active is default tho, isn't it?
 
for you perhaps
:)
 
@MichaelBrandonMorris So made the question, just for the title?
 
@N3buchadnezzar I "learned" Haskell just for that title.
 
@MichaelBrandonMorris You can has tryhard :-)
 
It's the most popular question I've asked by far.
I'm using all the rep I got to put bounties on my serious, but unanswered questions.
For some reason PDFs and Active Directory are not nearly as amusing to most people. No idea why...
 
6:45 PM
@MichaelBrandonMorris I can relate to that lolcats are views & votes magnets apparently
 
@MichaelBrandonMorris You just need wittier titles, with more puns, memes and language used by todays kids.
 
This question was cross-posted on Code Review, and should be deleted on Stack Overflow. — 200_success 26 secs ago
 
@Mat'sMug That's hilarious. Maybe I should write the lolcats translator in lolcode...
@N3buchadnezzar The thing is, I thought this site was professionals, not kids. :P
 
@MichaelBrandonMorris We're all kids, really.
6
This is news in the UK, apparently
 
Alrighty then...
 

« first day (1132 days earlier)      last day (1963 days later) »