« first day (1395 days earlier)      last day (2921 days later) » 
00:00 - 15:0015:00 - 00:00

15:00
Please Post it on codereview.stackexchange.com as it may get downvoted here, just alerting you. people do downvote off topic. — Suraj Jain 40 secs ago
I'm voting to close this question as off-topic because it is asking for a review of working code and is thus more appropriate for Code Review. — Toby Speight 52 secs ago
Kaz
Kaz
GAH! Stop sending me spreadsheet data in PDFs! /rant
Monking
0
Q: Is there a more efficient way to subtract multiple columns in a PANDAS DataFrame by a series (or single column)?

James DraperBackground I have tons of very large pandas DataFrames that need to be normalized with the following operation; log2(data) - mean(log2(data)) Example Data The example DataFrame my_df looks like this; iovrrx nfinsu mvdfjc idjges fubmrg lvuhfv 0 0.987654 0.206104 0.802920...

0
Q: Iterate over list and valid email address

user132159I have the following code: (emailList type is List<string>) //Add All emails foreach (var mail in emailList) { var isEmail = Regex.IsMatch(mail.Trim(), @"\A(?:[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9...

15:24
@Mast Where's that at?
0
Q: Is an answer not discussing the code at all on-topic?

insertusernamehereI came across the question: Single-page personal portfolio website It has an answer, that doesn't review the code at all. It only comments: […] I can tell you there is not many things you can really cut in order to make the code more tidy without resorting to frameworks. Inevitably as this ...

0
Q: Javascript: Google Analytics Track Outbound Page Views

SwalkerI've researched this morning how to use Google Analytics to track outbound page views. However, I think the implementation might be a bit difficult on our website (as we have hundreds of outbound links) Here's what google recommends. /** * Function that tracks a click on an outbound link i...

@StackExchange user didn't understand any and all aspects ... yay
15:52
I'm voting to close this question as off-topic because it belongs on the CodeReview site. — Dmitry 29 secs ago
@Vogel612 Somebody should probably leave a comment though.
I'm having a headache and having trouble being friendly, so, not me.
44
A: What is the difference between \$V_{CC}\$, \$V_{DD}\$, \$V_{EE}\$, \$V_{SS}\$

PkPI think I may have the definite answer to this. This naming comes from a 1963 IEEE standard 255-1963 "Letter Symbols for Semiconductor Devices" (IEEE Std 255-1963). I'm an electronics history fanatic and this might be interesting to other (fanatic)s, so I'll make this answer a bit broader than ne...

Kaz
Kaz
So the OP from this Question added some proper description, screenshots and context. I'd like to reward them for improving it. Hence: Pimp.
@Kaz !@#$ that's ugly
    r221.Value = r1.Value
    r231.Value = r11.Value
    r251.Value = r31.Value
    r261.Value = r41.Value
    r271.Value = r51.Value
    r281.Value = r61.Value
    r291.Value = r71.Value
    r301.Value = r81.Value
    r311.Value = r91.Value
    r321.Value = r101.Value
    r331.Value = r111.Value
    r451.Value = r441.Value
    r361.Value = r141.Value
    r371.Value = r151.Value
    r381.Value = r161.Value
    r391.Value = r171.Value
    r401.Value = r181.Value
    r411.Value = r191.Value
    r421.Value = r201.Value
maintainability.Value = 0
Kaz
Kaz
@Mast I think you mean -∞
Probably.
16:03
1
Q: Golang crypto library: security

CCooperI've recently put together a library for working with Crypto in Go. I did not roll my own, I'm relying on stdlib for the core parts of this, but I would still like to get this reviewed by some experts in case I've done something horrific. If you're interested and want to view this in a more pal...

16:17
> My best guess of how to tighten up the code would be to move the 470 lines of set variable as range into a separate procedure that could be accessed from all of the different procedures in the sheet (those same 470 lines of code are repeated in the use of both the New Issue button and the Prioritize Issues button).
ouch ...
@CaptainObvious "I did not roll my own" - aren't there already Go crypto libraries out there?
Greetings, Programs.
@ThomasWard Without even looking, yes.
@DanPantry That makes my comment that much more relevant
I'm confused, you say you aren't rolling your own crypto, but you're creating your own crypto library. Correct me if I'm wrong, but aren't there other crypto libs already out there that have had a lot more vetting from a security perspective? — Thomas Ward 4 mins ago
16:37
1
Q: Python hash format converter

redfast00This program should convert a file containing Mana, Hashcat or John the Ripper NTLMv1 hashes to another file containing Hashcat or John the Ripper hashes. Do you have any suggestions on how to make the code cleaner? The hash format selection code feels kinda dirty. #!/usr/bin/env python3 # Take...

@ThomasWard It may be an abstraction to the library, like urllib and requests. Or at least that's how I read it...
@DanPantry Is Bootstrap + jQuery my best option for a lightweight UI with a backend in Python?
@Peilonrayz possibly.
@EBrown yeah, probably
Alright, any other recommendations? It's going to be single-page and I'd like to have async data refreshes.
16:44
@EBrown If it's just a simple website, jquery + bootstrap is probably fine.
Rivets may be a good way to help structure that since bootstrap is basically just going to be jQuery soup
I want to drop a D3 graph in it as well, and refresh that graph asynchronously.
Then I'd say Rivets + jQuery + d3 + bootstrap should be fine
jquery/d3/bootstrap for functionality
Sweet
and rivets just lets you group things into components so it's easier to lay out.
I think I tried Rivets once and I don't know how to use it lol
But I'll add it and try it out anyway.
16:46
it's got its own DSL but it shouldn't take more than an hour to get going with IMO
What?
The XKCD is a feed :)
ah :)
E: Did not know
@ThomasWard I was thinking about working as customer service. One of these days I'm going to be like Daffy Duck when he was working for the telecommunications company.
16:52
lol
customer service is a fairly evil profession
He was like: "People get paid to make other people miserable? Here I've been doing it all my life for free!"
5
Then he submitted the best resume he could think of. They were like "you look overqualified." "No, no, I'm not overqualified! It's just because everything is in bold! I was born for this position!"
Monking
@Hosch250 This is how I got the job at the campus student IT help desk. Except with actual work experience, not falsehoods.
they basically skipped all the technical knowledge questions xD
Did an ad just travel with me...?
"You're very overqualified, why are you looking for this job?"
@skiwi Yes, it did, it is stalking you
17:02
At work I researched something, my work PC and my phone both share the same location, now I'm at home and I got an ad about that tool
Yup, they do that.
@skiwi it's Skynet, it's hunting you
2
it's not really an ad but spyware that is tracking you
Yup, they are adding stuff to your ad ID.
I don't have this problem. I block most cookies, use ad-block in my browsers, and tell them to not give me a consistent ad experience.
@ThomasWard He did use actual work experience.
He mentioned he'd been in the Marines (he didn't mention he went AWOL and never went back).
17:04
Well, for a select few sites I unblock ads as that's their main revenue, so I spotted it there
I pointed out to someone at work today that they had too many tabs open
He may have mentioned he was the CEO of SomethingOrOther Corp. If so, he didn't mention that he had bankrupted the company.
@ThomasWard Did you just fix up that sidebar notification? Because I'm pretty sure I saw an @Skiwi in front :P
@skiwi maybe?
@ThomasWard How can I turn a list from a DB to JSON easy with Python?
@EBrown what's the data you're trying to get out as a JSON object?
17:15
Gonna read my data from MySQL then send to a JSON object for D3.
min, max, avg. humidity/temp?
It's just going to be a query result.
@user2315094: only if you want your class to be move-only. Please read some resources onto the subject or create new questions / a question on CodeReview.se if you have further doubts. — Vittorio Romeo 13 secs ago
@EBrown right, but that's not what i'm askin
@EBrown show me your query result and the data you get back in raw form. Or give me a copy of your DB or temporary access
I need to return two elements: Logged (datetime) and Value (float).
17:16
because returning as a JSON isn't too hard if I know the data being returned already from your SQL query
@EBrown for every value, or just a single value?
A list of them...
which do you want to be the key, the 'logged' datetime?
SELECT Logged, AVG(Value) AS Value FROM TemperatureLog GROUP BY Logged
That's the query.
Need that to JSON through Python.
@EBrown sample output from that statement please?
I can store all the relevant values in a list.
17:18
..,.
@EBrown I don't think you know what i'm trying to get from you
i'm trying to get sample output from the query, and details on how you want the data to show in JSON
I presume you want the Logged result to be the key, so that jsonobject[logged] would return the relevant Value
right?
No, I need them in a JSON array.
...
I'm confused by how you expect your output to be
i'm also damned tired
sounds like you need an SO question for this, but it'll be closed as "unclear"
since you don't give me an example of how you want the output JSON array/dataset to look
[{"Logged":"2017-02-27 12:20:16","Value":"21.0"},...]
Just like that.
oh
that's easy
hang on
(Sorry, i'm real tired)
@EBrown give me a few, 'cause I also ahve to replicate the DB query
which takes not long
i think i have mysql here
(I really need sleep)
Take a nap on your lunch break.
17:35
@EBrown do you need it as a string, or is a datetime object OK?
for "Logged"?
Need it as a string IIRC.
@ThomasWard object.ToString()
@Hosch250 not as easy when it returns a datetime object, I don't think it ihas a default toString object. Also, PYTHON
oop that worked
@EBrown
import pymysql

sqldb = pymysql.connect(host='localhost', user='user', password='password', db='database')

JSONARRAY = []
try:
    with sqldb.cursor() as cursor:
        # noinspection SqlResolve
        query = "SELECT Logged, AVG(Value) AS Value FROM TemperatureLog GROUP BY Logged"
        cursor.execute(query)
        for result in cursor.fetchall():
            JSONARRAY.append({'Logged': str(result[0]), 'Value': result[1]})
except Exception as e:
    print "DEATH!\n%s" % str(e)
finally:
    sqldb.close()
should give you an array like you want, but double check the output first.
I don't have an example of your data though
so it's half-assed
but it should generate what you're looking for.
Assuming you are using pymysql from pip of course.
example output:
[{'Logged': '2017-02-25 12:20:00', 'Value': 10.0}, {'Logged': '2017-02-25 12:30:00', 'Value': 20.0}, {'Logged': '2017-02-25 12:40:00', 'Value': 10.0}]
god I need sleep
and probably more coffee
stupid neighbors
17:45
OMG FREAKING INTERNET AND THIS BAD UI DESIGN
o.O
slowly walks away
All these damn images are links and the best part is this page has 160 or so of them
I have to click one near the bottom
Guess what that means
Yep, waiting a while.
DON'T MAKE THE DAMN TITLE ABOVE THE IMAGE THE LINK
No
At least they are lazily loaded so the whole page doesn't just time out.
They didn't lazily load, they lazily developed.
3
17:46
Close enough?
possible answer invalidation by clockw0rk on question by clockw0rk: codereview.stackexchange.com/posts/156396/revisions
well that's poor... my phone case from Lifeproof... not so life proof.
just broke so it's not as usable :/
0
Q: Return MySQL data and use as coordinates in flask-GoogleMaps

MingyJFirst I'm using the library here https://github.com/rochacbruno/Flask-GoogleMaps I have a .py file that looks like the following import MySQLdb from dbconnect import connection import gc def Import_Sql(): c, conn = connection() dictCursor = conn.cursor(MySQLdb.cursors.DictCursor) d...

0
Q: Capturing URLs using Regex

DelfinoI'm currently learning regular expressions, and have been toying around with how to use different capturing groups to match on a variety of URLs using the http protocol. I've been running all my regex through http://regex101.com/, which has proven extremely useful, however I have come across som...

0
Q: Looping over Survey answers in PHP (Laravel)

NotflipI'm using PHP (Laravel) to iterate over the survey_answers table and build datasets which I can show in a Graph. I'm just wondering if this is the way to go. Thank you. ChartFactory.php public static function buildFromSurvey($survey) { $chart = new Chart($survey->name); foreach($survey->...

18:10
Naruto answer; accepted non-selfie answer with 0 score: SQL database for a social network
Ripe zombie; open question with answers, at least one answer having score 0, no answer having score > 0: Javascript write a for loop for elements inside of a function
18:25
My graph works.
possible answer invalidation by 200_success on question by AdmiralAdama: codereview.stackexchange.com/posts/156394/revisions
posted on February 27, 2017 by CommitStrip

3
@EBrown Yup, definitely a graph.
Oooh, 2 graphs for the price of 1.
18:36
1
Q: Ruby script to to check the status of a rabbitmq queue and send alert

tesWe are using a message broker called rabbitmq. The code checks the status of number of messages in q queue and sent messages. This is achieved by a curl request to a given API.The script has a sleep of 5 seconds. I want to beutify and optimize this code for memory. I am getting offences too many ...

19:03
Impressive improvement. Would you mind to take a look at codereview.stackexchange.com/questions/154926/… and see how i have to extract the matrices from an image. — Nikolas Rieble 47 secs ago
0
Q: Find the lowest and second lowest values in an array of numbers

Matthew FarabaughTrying to find way to do this with only one pass through the array, so I won't run a sort on it and take arr[0..1]. Not sure how to make it look better: def LowestSecondLowest(arr) lowest,second_lowest = nil,nil arr.each do |n| if second_lowest.nil? second_lowest=n elsif lowe...

possible answer invalidation by 200_success on question by ImSlake: codereview.stackexchange.com/posts/156429/revisions
Now that you have a working code, I advise you to move your entire code to Code Review to get it reviewed and "cleaned" — Victor Moraes 42 secs ago
19:38
This question may also be better suited for Code ReviewAndyG 46 secs ago
@AndyG No! If the OP isn't sure it works, it's not allowed on Code Review. Code Review only accepts working code, please check the help center before recommending. — Mast 10 secs ago
0
Q: Code to count number of lines. [C]

MichaelXVery simple code, works fine. I'm mainly interested in the method I used to count lines. I thought about using fgetc, but I'm not even sure if it'd read the newline character, and I think it's slower too. #include <stdio.h> #include <stdlib.h> #define MAX_SIZE 1000 int main(void){ FILE *in_...

@Mast It's fine to ask for a Code Review as long as the code appears to work. — 200_success 54 secs ago
@Duga I disagree with diverting that question to CR. I might have screwed up stating it correctly, but it was a lousy fit.
@CommitStrip 5-star.
19:54
0
Q: Expression evaluator with Shunting-Yard algorithm

GabrielI am especially concerned about: Correctness: Does my algorithm always output the correct answer given a correct input? Readability: Is my algorithm easy to understand for an experienced Ruby programmer (or, in other words: how many WTFs does a experienced Ruby programmer say while reading my c...

0
Q: Makefile for building ASM/C project

SebazzzI am building a bare bones freestanding kernel in ASM and C. My make file is below. CFLAGS= -ffreestanding -nostdlib -gdwarf-4 -m32 -ggdb3 -Wall -Wextra -Werror -std=c11 ASMCFLAGS= -f elf32 -F dwarf -g -w+all LDFLAGS= --nmagic -m elf_i386 --script=os.lds BUILD_DIR=../build/os BUILD_DIR_IMM=$(BU...

20:13
0
Q: Run "Runtime.getRuntime().exec(cmd);" in a static method

Shayne HartfordAm I missing something here? I'm trying to run Runtime.getRuntime().exec("java -jar MyJar.jar --args1 value"); From my public static void main(String[] args) {} But get http://prntscr.com/ee4mmi I know its probably the easiest problem for anyone else, But i've come across this in multipl...

0
Q: Directory Organizer

Mahmud Muhammad NaguibMy Windows desktop is messy so I thought of writing a program to organize it, and other directories too, for me. Here is my code: import os import shutil class File: """Represents a computer file. attributes: path, name, extension """ def __init__(self, path): """Inint...

0
Q: Using loop to convert multiple files into separate files

DalyaI used this command to convert multiple pcap log files to text using tcpdump : # cat snortLogFilePath/snortLogFileName* | tcpdump -n -r - > snortLogFilePath/snortLogFileName/file2.txt and it worked well. Now i want to separate the output, each converted file in a separate output file using ...

20:25
0
Q: Model structure for Player Team and Match in football application

RobsonI'm creating an application for foosball matches. I have models like below: class Player(models.Model): match_amount = models.IntegerField(default=0) wins = models.IntegerField(default=0) avatar = models.ImageField(blank=True) user = models.OneToOneField( on_delete=model...

20:44
Jess Pardue on February 27, 2017
Welcome to the Stack Overflow Podcast #102 recorded Thursday, February 23, 2017 at the Stack Overflow HQ in NYC. Today's podcast is brought to you by rogue cows and SHA-1. SHA-1: You can depend on it.
21:02
Anyone willing to lend a hand in Music Fans Meta?
2
Q: No effort, no research, no use to future visitors

TetsujinIt seems quite clear that the community doesn't want useless "Identify This" questions - "Identify this song / genre / artist" - on topic? and yet our only close reason is Questions seeking to identify a song/sample/artist/etc need enough objective detail to be answerable. Please if poss...

We could use some comments and especially votes on the question and answer.
21:42
18
Q: What maximum password length to choose when using bcrypt?

user1When I generated password for GitHub with KeePass I got a message on GitHub site that said the limit for password length is 72 characters. It seemed weird it not being a power of 2 so I googled a bit and it appeared that 72 is the max bytes for brypt algorithm. So it seems logical to restrict the...

:o wasn't aware of this
21:55
Could you cut down the example and highlight what is wrong? The question sounds like its asking for code review, when SO's for specific answerable questions. Elaborating on what doesn't work is a good first step here. — TankorSmash 35 secs ago
No, I'm not. Someone down voted all the answers, including mine! I wouldn't down vote for such a suggestion, but if you were in code review, I'd ask if it must be static, because it is really unpleasant to refactor static methods. — Edwin Buck 41 secs ago
22:33
0
Q: Performance improvement for finding roughly matching keys in python dictionary

The NightmanThe purpose of my code here is to play a part in genome sequencing analysis, and while functional it takes days to run, so I am looking for any way I can improve speed. The input is up to 500 million lines long (making speed code efficiency important) and contains sequencing reads and correspondi...

23:06
0
Q: how to optimize vba looping code using variables?

user132196Sub Testingloop() Dim endrown As String Dim ex As String Dim ez As String Dim eh As String Dim eg As String Dim el As String Dim ee As String Dim es As String Dim ef As String Dim ei As String Dim i As Integer Dim LastRowColumnA As Long: LastRowColumnA = Sheets("looping").Cells(Rows.Count, 1).End...

0
Q: A recursive function that performs a binary search

Joseph PalominoI created a recursive function that uses binary search to just return true if it finds the value and false if it does not. I'm new to recursion and binary search so please let me know where I can improve upon. Thank you, for taking time out of your day to help. /** * Uses binary search O(lo...

23:39
Maybe you should ask this question on Code ReviewBackSlash 48 secs ago
00:00 - 15:0015:00 - 00:00

« first day (1395 days earlier)      last day (2921 days later) »