updated packetmail to use csv.#98
Conversation
|
Hey! Thanks for this. I think this makes a lot of sense, and the new method you propose makes it prone to less errors in the longer run. Please make the changes to the other parsing functions as you see fit. No rush, take your time. :) In the meantime, I will forward you the CLA. Happy Holidays! |
|
Thanks, Bryce. LMK if you would like me to test and merge this separately or if you prefer to have it all done first. |
|
Hey Alex, Happy Holidays and sorry for the delay in my reply. I'm happy for you to Warm regards, On 12/23/2014 10:25 AM, Alex Pinto wrote:
|
|
No worries, Bryce. Happy holidays! I'll go ahead and merge this one, and then you can carry on with the changes as you see fit. |
|
Actually, you should compare |
Pulled the call for the current date out of the for loops. Should improve performance.
|
Hey Alex, I figured out that I was testing against the wrong file. I've verified Sorry about that! On 12/26/2014 10:39 PM, Alex Pinto wrote:
|
response is of a type where csv.reader needs the splitlines method.
|
Fixed! Like the commit message says, I need to use the splitlines method on response. I also pulled out the today functions from within the loops. These changes improved the run time of thresher from 14.5 seconds to 10.5 seconds on my machine. |
|
Nice catch. There should be several small optimizations like this on the code. Tested this and merging soon. |
This is less of an actual MR and more about trying to start a discussion about migrating the input parsing to being handled by the csv module instead of being done by hand. Let me know what you think and I can modify the rest of the parseing functiont to do the same.
Testing for this was:
Happy Holidays!