« first day (3431 days earlier)      last day (1531 days later) » 

6:31 AM
i am facing this issue when run : "tor-resolve -x onion-url"
Error while connecting to SOCKS host: Connection refused
 
7:24 AM
@Jincowboy You'll have better luck googling that or going to the Tor IRC / support group. We reserve this room for Python related questions & discussions.
 
Thanks @shad0w_wa1k3r
 
 
3 hours later…
10:41 AM
could someone advise if I've included the table html source for the op correctly or am missing something ? stackoverflow.com/questions/60586395/…
 
10:58 AM
Advice needed: this not-very-useful closed question How to use the results of groupby as new columns in pandas? has a title that unfortunately matches important stuff like [pandas] name result of aggregate. Should we just delete it?
...or downvote it so it gets automatically removed?
 
i think yes, since it's all about pivot
op reference a title which is different than the question asked.
 
@αԋɱҽԃαмєяιcαη if you have to ask you're doing it wrong. Don't write people's questions. I rolled it back.
 
@AndrasDeak am asking to confirm just.
 
@smci it's frowned upon to downvote for automatic deletion meta.stackoverflow.com/questions/307009/…
 
@AndrasDeak That's why I asked you all. What do we do with that then? delvote or what? It's also bad to leave things like that tha cause confusion.
 
11:04 AM
we could delvote, but unanswered closed questions are harmless
@smci whom would it confuse?
 
@AndrasDeak I just told you exactly. I gave you the keywords (above) showing what sort of frequently-used search it would mess up. So what's the answer please?
 
the Roomba page is a bit cryptic – shouldn't the question be deleted automatically as it is?
seems like RemoveAbandonedClosed should match, no?
 
@AndrasDeak I explained precisely why it wasn't harmless. Better to have checked it first before saying that.
 
@MisterMiyagi dupes are exceptions probably
 
@smci The question is marked as a dupe for one of the top hits of that precise search. How does that mess up the results?
 
11:18 AM
There's a roomba forecaster userscript if you're interested
 
@AndrasDeak oh, that's good to know.
@AndrasDeak only mildly so. My 10 minutes of cleaning up SO on a nice Sunday are up, I'm afraid.
 
@MisterMiyagi also unregistered users get automatically redirected to dupe targets
Hence the whole "signpost" thing
 
I can kinda see where this is coming from. When I'm not familiar with a package/topic, dupes often showed me what question I should have asked instead.
 
Yeah, it's great
Probably a mistake for a small percentage of cases, but overall has to be positive
 
12:00 PM
@MisterMiyagi Because the question is badly-phrased, yet it shows up as the #1 search hit on those keywords [pandas] name result of aggregate. Because the OP stated it as: I would like to use a groupby to filter values on a given column and then use the values as new columns in a data frame instead of aggregate. It looks like a pivot but without index.". That's a garbled statement that will hit most pandas keywords. So it matches searches for aggregate, even though it shouldn't. So:...
...either I edit the garbled statement to not hit every other keyword in pandas, or we simply delete it. Which?
 
leave it be. If im reading you correctly, you're stating that "aggregate" is the word against which it will come up, and thus you want to take that portion out. Fortunately, it doesn't come up as the top result for "aggregate pandas stackoverflow", and so mangling questions for the sake of SEO shouldn't really be our concern. Now, for the question, where the OP isn't really clear on the right terms to ask about, "instead of aggregate" is providing a critical step in eliminating certain things
So, it's directly relevant to what the OP wanted to ask about, and removing it would make the question more unclear compared to what it already was. Bottom line is, these were the words of an OP who didn't know what they were looking for, now routed to a signpost that leads them to the right answer. If that is serving it's purpose, mangling the words away from that state would actively harm this particular signpost/pathway.
 
12:19 PM
@ParitoshSingh That's totally irrelevant, it's still the #1 hit for [pandas] name result of aggregate, and it's clogging things up. Naming the result of aggregates is an important new thing in recent pandas versions, and SO coverage of it is awful, and junk like this makes it worse. This closed question has almost zero positive effect and has a slight negative effect. Hence should go.
 
premature optimization is the root of all evil
give it time. don't actively harm a question for the sake of SEO.
also, i never thought i'd be using that statement out of programming
if its new, it's new. that is all.
 
hello i need someone help me with numpy
 
@ParitoshSingh That actual question is irrelevant. The OP already knew about pivot. If they'd simply said "Hey how do I do this pivot?" it would not cause confusion. But they phrased the question so that it hits almost every keyword, unnecessarily.
 
AttributeError: 'list' object has no attribute 'argmax'
 
@BlackSnow that's not a numpy issue :P
 
12:23 PM
@ParitoshSingh It's not premature. It simply needs to be deleted or rewritten. Now beats never. None of you is proposing to rewrite it, and I don't intend to.
 
your object is not a numpy array, it's a native python list
 
well yea that's true so how to make the object numpy array
the object is a sentence
 
call np.array on it
 
english sentence
 
@BlackSnow then maybe not
sounds like an XY problem
 
12:24 PM
You search like a guy who knows what to search for. Not everyone does that. The question is one of many examples where you'd probably want to say "what the heck is the person even asking" but fact of the matter is, that's what they asked. Anyways, You can keep stating the same things, i've heard what you have to say. I've said what i wanted to say. If what i said doesn't matter for you, then it's okay.
 
@BlackSnow Are you looking for the letter in the sentence that's the latest in the alphabet?
 
@BlackSnow Why are you trying to call argmax on a string, or list of string, or np.array of string. What are you doing? word-vector?
 
i have build a machine translation model build with keras
 
this went from a 0 to a 100 real quick. :P
 
and i can make a prediction perfectly with file if the sentences are in a file the prediction goes with out even a single error
but when i want to make a prediction with user input i get errors
 
12:28 PM
@ParitoshSingh You keep misunderstanding my point. People who search on 'aggregate' shouldn't find it. Or 'name result of'. It hits too many irrelevant keywords, as written. It should not show up in their searches. End of story. It takes like 5 seconds editing to remove it. Else delete it. None of you guys was prepared to edit it. Alternative is delete it.
 
@BlackSnow have you read a numpy tutorial? It might help.
 
I didn't find it when i searched aggregate. And im sure there's plenty of questions that say "i don't want x" where x can be anything. To me, those are "good" additions to a question statement, not bad ones.
 
yea i went to it
 
I don't even know why finding it on keywords became a criteria for editing or deleting questions, shouldn't we judge a question on it's own merits or demerits?
 
@ParitoshSingh you don't have to argue if you don't want to
 
12:31 PM
aye, indeed
 
@ParitoshSingh It did show up for the keywords I listed. In this case it's a bad addition. I understand pandas better than both you guys, I don't know why you keep pushing back with not very releveant comments. Either edit or delete.
 
rbrb, Paritosh
 
rbrb * n
Closing out: "name the result of an aggregate" is an important new feature in pandas for which SO coverage is abymsal, and between 0.23 - 1.0 the pandas guys messed around with deprecating dicts for that, and also changed .assign(). Now there's tons of confusion and stale questions. The thing I cited makes things worse. Hence should be flamethrowered.
 
12:50 PM
@smci I don't think "it is easier to delete than volunteer some time of a nice Sunday for extensive editing" is a valid reason to remove someone else' content.
 
@MisterMiyagi That's misrepresenting things: it wasn't "extensive editing", just removing the bogus keywords that cause unwanted hits. Take less than a minute. Or deleting takes a second. "name the result of an aggregate" is an important new feature in pandas for which SO coverage is abysmal, agreed? Just look at what "[pandas] name the result of an aggregate" returns you. That confused question I cited is secondary to its keyword mess. The only reason I asked the room is to understand our protocol.
Logging off. bye
 
bye
 
 
2 hours later…
3:17 PM
how to clean such type of html source code
<div class='\"name\"' itemprop='\"author\"'>
expected it to be

<div class="name" itemprop="author">
 
@αԋɱҽԃαмєяιcαη How did you end up with that html?
 
here's the code used
and here's the output
i think it's a JavaScript string containing HTML
 
ah, LOL
well, that's one way to make html i suppose
 
idk how to deal with it
 
Are you trying to help the user with 3 scraping questions about that website in the last 2 days?
 
3:29 PM
that one
0
Q: Adjusting Web Scraping Code for another site

Sara JitkresornI'm currently using this code to web scrape reviews from TrustPilot. I wish to adjust the code to scrape reviews from (https://boxes.mysubscriptionaddiction.com/box/boxycharm?ratings=true#review-update-create). However, unlike most other review sites, the reviews are not separated into multiple s...

 
I figured
 
I've just found a bad way to do it
i can access the div using r''
1
A: BeautifulSoup find on class doesn't work

Martijn PietersYour HTML is badly formed and contains embedded backslashes and quotes in the attribute values. You'll have to include those quotes when searching for the class: >>> from bs4 import BeautifulSoup >>> sample = r''' ... <html> ... <body> ... <p> ... }" ... </p> ... <

 
They have 2 newer questions scraping the same site, with selenium
 
I figured a way to scrape using requests. selenium is too slow
 
But selenium can evaluate that JS mess
 
3:33 PM
:( sadly i couldn't parse now. got much broken output
for com in soup.findAll("div", class_=r'\"comment-body\"'):
                print(com.text)
 
Perhaps you could ast.literal_eval those class names...ugh
Ah, but you want to search the html...
 
i think regex to match everything in between \n and \n</div> if it's contain alpha will be the key
 
This is probably a measure to prevent scraping by the site. It would probably also make an empty page show up if you're using some JS blocker...which makes it very likely for me to just close the webpage without interacting with it.
@αԋɱҽԃαмєяιcαη yeah, regex is the best way to parse broken HTML. Go for it :P
 
is there a difference between doing python3 -m pip install somepackage and just pip3 install somePackage ?
 
@Manik yes
pip3 and python3 might point to different python versions
Use the former
 
3:44 PM
ohk melon
 
doesn't python run the program top to bottom line by line? how come this error comes before executing the code before it:
mysql.connector.errors.InterfaceError: 2003: Can't connect to MySQL server on 'localhost:3306' (111 Connection refused)
 
@Manik no MCVE
 
@Manik ask yourself ! we haven't see your code ! but i think you are trying to connect to MySQL in order to execute a code ?
 
@AndrasDeak the code is long and not useful to answer this i think
@αԋɱҽԃαмєяιcαη yes i know. i broke my hard disk during partitioning so had to get a new ssd and reinstall everything now the old code is not running because mysql is not installed
 
4:12 PM
@AndrasDeak I'm sorry that question was stupid i didn't think before asking. it was the function definition. i was calling the function later. facepalm
i can't delete the message now
 
since you are have a conversation with anyone in room, you don't need to mention him/her each time. as long as it's open conversation. just post your question and wait for answer. imagine that you are working on something and got a noise notification ? what it will sounds like for you. :)
we are using mention only if we pinging each other for something we both talk about in time frame
 
@Manik function bodes aren't run in declaration order.
 
ok i'll keep that in mind from now on :)
 
Any good( from that I mean which explains the theoretical aspect unlike most of the resources which I have found on google where just code is inserted from nowhere with some brief explanation) and brief resources for learning about interpreters(which can be implemented in high level languages like python)?
 
4:19 PM
oh boy, sounds like an oxymoron
topic like that, i imagine cant be both good and brief at the same time
 
Brief ~ 10 - 20 pages, not the whole book of 500 pages.
 
i thought that python has some internal code optimisation, so its trying to establish sql connection first and stuff...crazy
 
My goal is solve this programming exercise, if you know introductory bookish explanation, please recommend.
 
i see
have you been able to solve the other linked exercises that are simpler? It seems like they're trying to get you to work your way up to this
Might be useful to try to solve the simplest one first
you might not even need a tutorial if you follow their path perhaps.
i dont have a good resource for you though
 
I have solved the mathematical evaluator, like you give some expression like fun(3+23*(232+23*(23))) it would return the result, but interpreter to me seem close to magic(they are close to opaque to me)
 
4:32 PM
well, the magic is in realising, they aren't really all that different, a mathematical evaluator and an interpreter
at least, not in the scope of this kata.
you're still working in a fairly high level language, and not having to deal with evaluating machine code, you're essentially trying to just parse input that comes in, and give an appropriate output
 
5:29 PM
missed up with the formatting in chat. lol
@AndrasDeak solved it without regex stackoverflow.com/a/60590147/7658985
for com in soup.findAll("div", class_=r'\"comment-body\"'):
    print(com.text[5:com.text.find(r"\n", 3)])
 
6:25 PM
getting ill amidst all this corona virus hysteria is pretty worrying, ngl
even more so since we're all out of tea
 
the word "hysteria" sort of implies that it's unfounded
 
does it? Well, I do think some people take it too far
 
I think if society would put more emphasis on science we wouldn't have to see such a day
 
@Manik uh, yeah, we would
@Aran-Fey as long as it's not just a cough with a fever... :P
 
oh god, vscode tired me to prettify JSON . it's post it as one line :(
 
6:34 PM
I mean, both of those are symptoms of the virus
 
...according to my 5 minute internet search
 
i think it's all based on political things under table.
 
according to the internet, pretty much everything is a symptom of it. Basically if you're feeling sick, you might have it. Very insightful.
 
are u one of those who believe that coronavirus is man-made virus in a lab?
 
6:39 PM
that's the first time I've heard of that idea, but my gut reaction is "nope, that doesn't sound right"
 
@Aran-Fey worldometers.info/coronavirus has a lot of exact-looking info
@Manik I'd rather we stuck to facts here
 
ok, so I only need to start worrying if it gets worse. That's good to know
 
that's possible but too cynical, people have conscience i believe
 
:D we haven't seen the conscience during bird flu.
 
6:54 PM
I hear that Tamiflu makes delicious croutons in soup. We have to find some use for the millions of doses lying around
If nothing else, though, this is a decent lesson in the fact that we're not infallible, our containment approach apparently sucks and our development pipelines are still super long, despite the technology. I think that's a reasonable thing for some people to realise these days when it appears that we have the tech to do pretty much anything
 
is someone working on uploading human consciousness into computers? because that would make us immortal
 
the mad thing in that topic, the people which keep infected without any travel history to china or relative countries. even without any roots to infection source
 
@αԋɱҽԃαмєяιcαη without any known roots, please stop spreading this vague FUD
vast majority of sick people have very mild symptoms and they are neither diagnosed nor tracked
the known statistics are only a fraction of the real sick
 
@AndrasDeak To be fair, it's a well published topic in the British Medical Journal that he was referring to and it was factually correct. Extrapolating to this issue was conjecture, though
@αԋɱҽԃαмєяιcαη You can't say that for sure. The incubation period is far too long, and there could be any number of interim vectors that could take it out of the country, infect other people, and never be aware that they had anything other than a cold
 
7:07 PM
what is the likelihood of a human making a virus that could also kill him/herself so that someday they can sell serums to cure it?
 
That wouldn't be a great venture. Not only would you have to go to the effort of creating the virus, but then you'd also have to go to the effort of finding a cure (or working backwards). You'd be better just fixing one of the existing virus problems
 
sadly today a german tourist died in Egypt and that's count as first death record. english.ahram.org.eg/NewsContent/1/64/364922/Egypt/Politics-/… and the government already announced Medical stone in luxor/aswan which the first record of it and infected a big group of nile cruise stuff were American women :(
 
7:32 PM
hello
 
cbg
 
8:01 PM
i know it's not related to python but can a hard disk become undetected because of partitioning?
 
don't think so
 
heh.. sounds like a day and a half of linux configuration
 
i thought partitioning is a software thing, it shouldn't affect the hardware, in any case i'd be able format the disk and use it but its showing not detected...strange
@Todd lol
 
i just wrote a little program that solves the kirkland's schoolgirl problem
er.. social golfer problem
 
@Todd do you work in combinatorics?
 
8:10 PM
no. something I'd like to learn more about though.
 
cbg
 
is that tensorflow?
 
See my comment under the question. I think that method probably comes from some custom code in the paper they cite. The OP is now asking me what I mean by suggesting that they follow citations :/
It almost certainly is a custom method
The only references to VariationalLSTMCell are in the paper I found and linked to them, and that github issue. It's on the OP to actually follow citations back
 
oh, it definitely is (a custom method). i just dug through tensorflow docs
 
8:21 PM
Wut? Has my google-foo failed? VariationalLSTMCell, if it's a method in tensorflow, isn't indexed by google
 
not a single mention of VariationalLSTMCell
i had a feeling i left the sentence incomplete :P
 
Oooo, I totally read your comment the opposite way :P
 
@ParitoshSingh separately, I'm looking to close my question with an answer to say I was a doofus. I left the offer open for you to answer after you rubber ducked with me; are you intending to write an answer and get the rep or should I just self-answer (with exactly the same thing)?
 
he could just clone it and search it if he already hasn't
 
8:24 PM
@roganjosh go for it, self answer away!
Aye. also, i wasn't aware of researchers giving code source alongside papers. is this a thing?
Because this seems really awesome
Then again, papers intimidate me. :(
@roganjosh for context, i went exploring the decorator thing with contextvars, and ran into more strange behaviour i couldn't explain to myself. Let's just say the rabbit hole went very deep
Pretty sure i decided i had to step away and stop myself at some point :P
 
Yes, it's a thing. I can't speak for all areas of study, of course, but I have seen open-source scripts tagged on to the end of research papers as an appendix in chemical engineering. At the time, I wouldn't have understood it anyway, but I imagine that the code can often be pretty poor
 
Ah, touche, that would probably be a thing too
 
Andras fixed a published script in this room only last week (IIRC) and he put a lot of work in just to meet basic conventions
Feb 26 at 9:45, by coding girl
@AndrasDeak I am investigating on a code from Rutgers University. It uses the weave module which is a standalone package, separated from scipy and available on Python 2.x only
^ starts there, @ParitoshSingh
 
can't always assume that open source code isn't going to be good quality
 
i keep trying to read that as "can't always assume that open source code is going to be good quality" because that's the statement i thought you were going to make
 
8:36 PM
That's why I said "can often be". I do know people who were coding when I was doing my PhD and I know that many of them just scramble to just get something to work when their field has nothing directly to do with programming in the first instance
And that wasn't a statement from me about open-source in general. I use a huge number of open-source libraries that are fantastic. I'm talking about programs that are distributed to solve a super-niche issue that is the topic of a single research paper
 
But if you are saying what you're saying, then well no, We use python. Im pretty happy with the standards that open source code can achieve.
 
ah
got it
 
I do think it has to do with a "critical mass" and also with the nature of academia though. I'll more readily assume that code put out by academia might not be at par with code released with the intention of consumption for general use
Primarily because the people in academia are primarily there for academia. they are essentially creating code only to further or provide assistance for their thesis first and foremost. At least i think it's safe to presume that much
(and i do not even remotely mean to imply that as a bad thing. it's a great thing actually, putting code out for people to consume and to validate results. I hope it's a common trend, or becomes a common trend if it isnt)
Sadly; i really do not have any numbers to back up any of what i just said, these are all hunches/guesses you can say
o well :)
 
idk.. in my experience, what was said about students scrambling to meet deadlines and hastily writing code in languages they just learned..
seems the standard
 
heh, at least that comes from a reasonable standpoint
 
8:43 PM
The critical part of what I said was "when their field has nothing directly to do with programming in the first instance"
 
You really don't want to know the kind of battles i've had to fight to defend open source in the corporate world so to speak.
 
interesting
 
<-- ranted about not being allowed to use git in any form when I started this position :P
 
the last few places I've worked, open source was an easy sell
 
The gist was simple: "open source is virus." That was what I had to push back against.
 
8:45 PM
oh.. yeah.. you have those religious wars to fight with the incumbent "senior engineers" when you start at any place
people don't like this or that in software for the oddest reasons
 
Thankfully i haven't seen or been involved in one of those yet. This was upper management
So bit easier to navigate in that sense
 
ah
 
I'd rather take the fight to someone who doesn't know something vs someone who knows outdated or partial information
 
well there are licensing issues.. back in the 90's this large company I worked for made a few mistakes with it
ended up either having to open source a few major projects, or dump them
 
8:47 PM
Now I'm curious about how?
 
use code that uses a copyleft license
I only recently learnt about this stuff
 
I often see "you can't share this without attribution etc etc" (whatever is in the license) but I've never been sure about how it gets found out if I use something for internal, corporate means, if I just download a "personal" version
 
in a presentation for the software my department was planning on release.. I just made the statement, "but I thought SWING was proprietary"
and that set off a chain reaction
 
I've never done it because I assume there is some audit that can expose it
 
the developers back then thought swing was open source
or rather freeware
 
8:48 PM
Ah, that direction
@roganjosh actually, some companies draw really hard lines about this kind of stuff, even if no one would find out. Someone hears about it, and there's an "executive decision" to drop it.
Happened not 2 weeks ago for me actually. Turns out oracle jre changed how they operate, and there's a commercial license for their environment
 
ugh
 
Ha, JRE messed up a while back, didn't they on that?
 
Aye, except we hadn't known about this
That essentially nuked the first half of a pipeline we relied upon for a demo, not 2 days before the demo. There was panic all around
 
i was disappointed when oracle acquired sun
 
The minute our higher up found out, it was a straight call though: we will not use this code that relies on this JRE even for the demo
That was a long night. :P
 
8:52 PM
Anyway, what are they afraid of? Is there some actual threat? It's not generally in the Senior MGMT culture to not cut corners. So I'm assuming there is some mechanism by which they think they will get caught
 
Well, i think essentially the only way you can be caught on this kind of stuff is audit i imagine
 
Which boils down to; what audits catch this? :)
 
well, i suppose in that case you can assume this company is the exception to the rule
 
Presumably there is one, but maybe it's ancillary to something like a Financial Conduct Authority audit or something
 
integrity, and the public perception of integrity, is paramount to this company, their business model relies on it
indeed
I was honestly both impressed and shocked at the same time
never seen anything like it, never thought i would either.
The more common problem when it comes to open source with licenses though, is basically copyleft licenses.
We've been trying to make sure one of those don't sneak into our code somewhere, since essentially that puts a restriction on further code that the company would like to treat as propriety
 
8:58 PM
That makes more sense; if it's distributed in some proprietary product against the license then I image you could have a world of pain waiting to boil up. It only takes one disgruntled developer to dig a little into the code
 
teams ive been on are pretty diligent with running tools on the source code to detect any open source.. everything has to be listed and documented. and legal has to check it all
 
9:22 PM
 
9:45 PM
I love getting to the very last function to document
time for a break
 
10:05 PM
does someone know a proper dupe for why is multiprocessing slow when its payloads do nothing? This question has garnered quite some upvotes for basically being user error.
aaaand it has just been modified to have completely different behaviour. sigh
correction: it has just been modified to have even less runtime, but in an even more convoluted way...
 
@MisterMiyagi Sunday, Funday, hey? :P
 
eh.. maybe let him keep plunking at it if he's still editing
i just solved a ton of threading issues by imlementing __enter__() and __exit__() on my base class that acquires and releases an object lock...
python is an awesome langauge
 
10:24 PM
@roganjosh Yeah. Their newest version doesn't even run properly…
 

« first day (3431 days earlier)      last day (1531 days later) »