workspace
stringclasses
1 value
channel
stringclasses
1 value
sentences
stringlengths
1
3.93k
ts
stringlengths
26
26
user
stringlengths
2
11
sentence_id
stringlengths
44
53
timestamp
float64
1.5B
1.56B
__index_level_0__
int64
0
106k
pythondev
help
it might be easier to do all your request and flag the failed one. Then redo all the failed one
2018-01-24T15:59:17.000889
Micki
pythondev_help_Micki_2018-01-24T15:59:17.000889
1,516,809,557.000889
31,024
pythondev
help
Okay, gotcha
2018-01-24T15:59:25.000763
Cherlyn
pythondev_help_Cherlyn_2018-01-24T15:59:25.000763
1,516,809,565.000763
31,025
pythondev
help
That makes sense
2018-01-24T15:59:28.000451
Cherlyn
pythondev_help_Cherlyn_2018-01-24T15:59:28.000451
1,516,809,568.000451
31,026
pythondev
help
So the way I'm testing it now is I read the first cell (A1) of the downloaded header, if it doesnt match, I return an empty list
2018-01-24T16:03:15.000816
Cherlyn
pythondev_help_Cherlyn_2018-01-24T16:03:15.000816
1,516,809,795.000816
31,027
pythondev
help
Or actually, might return a list with the URL in it
2018-01-24T16:03:32.000468
Cherlyn
pythondev_help_Cherlyn_2018-01-24T16:03:32.000468
1,516,809,812.000468
31,028
pythondev
help
Given two binary images with random shapes, is there a way to get how many intersections(shapes overlap) are there?
2018-01-24T16:10:56.000685
Rosalyn
pythondev_help_Rosalyn_2018-01-24T16:10:56.000685
1,516,810,256.000685
31,029
pythondev
help
If I'm wanting to generate some content for an email, is it best to store all the values in memory as the script runs and then write the string to the email body or write it to a text file and then read that text file into the body of the email.
2018-01-24T16:17:27.000055
Brain
pythondev_help_Brain_2018-01-24T16:17:27.000055
1,516,810,647.000055
31,030
pythondev
help
<@Rosalyn> you probably want to check out the opencv project for that
2018-01-24T16:19:44.000058
Floy
pythondev_help_Floy_2018-01-24T16:19:44.000058
1,516,810,784.000058
31,031
pythondev
help
<@Brain> I’d do the first option, since unless you’re generating a huge email, memory used by storing the values is very low overall
2018-01-24T16:21:13.000157
Floy
pythondev_help_Floy_2018-01-24T16:21:13.000157
1,516,810,873.000157
31,032
pythondev
help
unless you’re working on a severely restricted hardware environment
2018-01-24T16:21:33.000916
Floy
pythondev_help_Floy_2018-01-24T16:21:33.000916
1,516,810,893.000916
31,033
pythondev
help
<@Floy> Right, no i play to just have the script hosted on somewhere like heroku or pythonanywhere and run once a day.
2018-01-24T16:22:00.000223
Brain
pythondev_help_Brain_2018-01-24T16:22:00.000223
1,516,810,920.000223
31,034
pythondev
help
yeah, no big deal
2018-01-24T16:22:23.000435
Floy
pythondev_help_Floy_2018-01-24T16:22:23.000435
1,516,810,943.000435
31,035
pythondev
help
<@Floy> Not sure if i've coded myself into a corner atm. I've got it sending the email and using a temple and a string substitution for the name in the body. I want to add my content that i'm generating now I've kind of made that bit. Not going so well though :stuck_out_tongue:
2018-01-24T16:23:09.000671
Brain
pythondev_help_Brain_2018-01-24T16:23:09.000671
1,516,810,989.000671
31,036
pythondev
help
just break it down piece by piece
2018-01-24T16:24:09.000043
Floy
pythondev_help_Floy_2018-01-24T16:24:09.000043
1,516,811,049.000043
31,037
pythondev
help
are you including images and such in the body?
2018-01-24T16:24:31.000284
Floy
pythondev_help_Floy_2018-01-24T16:24:31.000284
1,516,811,071.000284
31,038
pythondev
help
Nope, just text I've scraped.
2018-01-24T16:26:12.000617
Brain
pythondev_help_Brain_2018-01-24T16:26:12.000617
1,516,811,172.000617
31,039
pythondev
help
OpenCV project?
2018-01-24T16:26:42.000951
Rosalyn
pythondev_help_Rosalyn_2018-01-24T16:26:42.000951
1,516,811,202.000951
31,040
pythondev
help
yes. if you google it, it’ll be at the top of the list
2018-01-24T16:27:12.000168
Floy
pythondev_help_Floy_2018-01-24T16:27:12.000168
1,516,811,232.000168
31,041
pythondev
help
there are python bindings you can use, but the analysis methods are already there that you can use
2018-01-24T16:27:29.000973
Floy
pythondev_help_Floy_2018-01-24T16:27:29.000973
1,516,811,249.000973
31,042
pythondev
help
<https://github.com/MojoJojo86/DrOctoBot/blob/master/script.py>
2018-01-24T16:32:57.000245
Brain
pythondev_help_Brain_2018-01-24T16:32:57.000245
1,516,811,577.000245
31,043
pythondev
help
Thats what I've done so far <@Floy>, bare in mind I'm learning :stuck_out_tongue:
2018-01-24T16:33:23.000201
Brain
pythondev_help_Brain_2018-01-24T16:33:23.000201
1,516,811,603.000201
31,044
pythondev
help
and my constant notes :stuck_out_tongue:
2018-01-24T16:34:02.000227
Brain
pythondev_help_Brain_2018-01-24T16:34:02.000227
1,516,811,642.000227
31,045
pythondev
help
wow... pg_dump is a mighty tool :slightly_smiling_face:
2018-01-24T16:51:18.000256
Stefan
pythondev_help_Stefan_2018-01-24T16:51:18.000256
1,516,812,678.000256
31,046
pythondev
help
do you guys use that for running migration tests?
2018-01-24T16:51:33.001001
Stefan
pythondev_help_Stefan_2018-01-24T16:51:33.001001
1,516,812,693.001001
31,047
pythondev
help
I use that anytime I need to take a dump :smile:
2018-01-24T16:59:24.000121
Micki
pythondev_help_Micki_2018-01-24T16:59:24.000121
1,516,813,164.000121
31,048
pythondev
help
lol
2018-01-24T17:01:41.000885
Davina
pythondev_help_Davina_2018-01-24T17:01:41.000885
1,516,813,301.000885
31,049
pythondev
help
Okay newbie Question, but so far my google foo is not finding the solution! I have a package called models, under neath models is a file called machine.py that contains a class Machine. in the __init__.py i put a from machine import Machine, but when I try to use django makemigration, i get an exception telling me th...
2018-01-24T18:07:27.000628
Lorita
pythondev_help_Lorita_2018-01-24T18:07:27.000628
1,516,817,247.000628
31,050
pythondev
help
Have you tried making migrations with the app name?
2018-01-24T18:15:06.000767
Floy
pythondev_help_Floy_2018-01-24T18:15:06.000767
1,516,817,706.000767
31,051
pythondev
help
I've noticed that sometimes with django migrations
2018-01-24T18:15:17.000490
Floy
pythondev_help_Floy_2018-01-24T18:15:17.000490
1,516,817,717.00049
31,052
pythondev
help
to add a new wrinkle to it, this is Python 3.6, and a downgraded version of django to 1.11.9. if I run pyrthon -c 'from models import Machine' from the direcotry above I get an error about missing machine, but if I go into the models directory and run python -c 'from machine import Machine' I get a configuration excep...
2018-01-24T18:47:18.000566
Lorita
pythondev_help_Lorita_2018-01-24T18:47:18.000566
1,516,819,638.000566
31,053
pythondev
help
you might have to use absolute paths?
2018-01-24T18:55:46.000320
Floy
pythondev_help_Floy_2018-01-24T18:55:46.000320
1,516,820,146.00032
31,054
pythondev
help
eg `from app_name.models.machine import Machine`
2018-01-24T18:56:05.000386
Floy
pythondev_help_Floy_2018-01-24T18:56:05.000386
1,516,820,165.000386
31,055
pythondev
help
okay I have to use absolute paths. Turns out that I have to use from app_name.[package] everywhere I need to import the application code... Is that normal behavior? because it behaves total differently than what I would have expected.
2018-01-24T19:18:31.000180
Lorita
pythondev_help_Lorita_2018-01-24T19:18:31.000180
1,516,821,511.00018
31,056
pythondev
help
what do you mean, import application code?
2018-01-24T19:21:12.000114
Floy
pythondev_help_Floy_2018-01-24T19:21:12.000114
1,516,821,672.000114
31,057
pythondev
help
<https://stackoverflow.com/questions/12172791/changes-in-import-statement-python3>
2018-01-24T19:21:41.000444
Floy
pythondev_help_Floy_2018-01-24T19:21:41.000444
1,516,821,701.000444
31,058
pythondev
help
did you start the project with django’s default project template, or cookiecutter-django?
2018-01-24T19:22:10.000377
Floy
pythondev_help_Floy_2018-01-24T19:22:10.000377
1,516,821,730.000377
31,059
pythondev
help
or some other template?
2018-01-24T19:22:15.000578
Floy
pythondev_help_Floy_2018-01-24T19:22:15.000578
1,516,821,735.000578
31,060
pythondev
help
<@Floy> I meant that importing code within the app_name namespace.
2018-01-24T19:42:56.000335
Lorita
pythondev_help_Lorita_2018-01-24T19:42:56.000335
1,516,822,976.000335
31,061
pythondev
help
<@Floy> Thanks for the article, that answers my question.
2018-01-24T19:43:18.000371
Lorita
pythondev_help_Lorita_2018-01-24T19:43:18.000371
1,516,822,998.000371
31,062
pythondev
help
Thanks for the info.
2018-01-24T19:43:27.000469
Lorita
pythondev_help_Lorita_2018-01-24T19:43:27.000469
1,516,823,007.000469
31,063
pythondev
help
:thumbsup:
2018-01-24T19:59:16.000044
Floy
pythondev_help_Floy_2018-01-24T19:59:16.000044
1,516,823,956.000044
31,064
pythondev
help
I’m trying to create function so that user can attach on_success_cb and on_err_cb to it, do we have any wrapper function for it (example python has utility function: partial for allow attaching variable, chaining for chaining iterator…). Or I have to create it manually with format? ```def my_foo(my_var, on_success_cb=N...
2018-01-24T21:37:25.000068
Ben
pythondev_help_Ben_2018-01-24T21:37:25.000068
1,516,829,845.000068
31,065
pythondev
help
Anyone here know a way to convert doc/docx file to pdf?
2018-01-24T23:59:37.000347
Hai
pythondev_help_Hai_2018-01-24T23:59:37.000347
1,516,838,377.000347
31,066
pythondev
help
`pandoc`?
2018-01-25T00:02:19.000360
Sadye
pythondev_help_Sadye_2018-01-25T00:02:19.000360
1,516,838,539.00036
31,067
pythondev
help
there are also python binding for it
2018-01-25T00:18:10.000029
Sadye
pythondev_help_Sadye_2018-01-25T00:18:10.000029
1,516,839,490.000029
31,068
pythondev
help
Meaning?
2018-01-25T00:49:13.000122
Hai
pythondev_help_Hai_2018-01-25T00:49:13.000122
1,516,841,353.000122
31,069
pythondev
help
pandoc itself is written in haskell, and with python bindings you can get convenient access to it from python
2018-01-25T01:18:54.000222
Sadye
pythondev_help_Sadye_2018-01-25T01:18:54.000222
1,516,843,134.000222
31,070
pythondev
help
I have a urllib3.response.HTTPResponse object, how do I parse it into a file? ```&gt;&gt;&gt; a,b = container.get_archive('/srv/xxxxx/file.csv') &gt;&gt;&gt; a &lt;urllib3.response.HTTPResponse object at 0x7f83b90c8240&gt; &gt;&gt;&gt; a &lt;urllib3.response.HTTPResponse object at 0x7f83b90c8358&gt; &gt;&gt;&gt; b {'na...
2018-01-25T03:57:52.000557
Ben
pythondev_help_Ben_2018-01-25T03:57:52.000557
1,516,852,672.000557
31,071
pythondev
help
Hi I have 40 folders in my working directory, in those folders are 8 folders numbered from 1 to 8 . And in those folders is a file I want to supress every time named the same
2018-01-25T10:18:23.001059
Pennie
pythondev_help_Pennie_2018-01-25T10:18:23.001059
1,516,875,503.001059
31,072
pythondev
help
would like to know how I can open those folders
2018-01-25T10:18:47.000153
Pennie
pythondev_help_Pennie_2018-01-25T10:18:47.000153
1,516,875,527.000153
31,073
pythondev
help
os.openfolder is not a command
2018-01-25T10:18:55.000879
Pennie
pythondev_help_Pennie_2018-01-25T10:18:55.000879
1,516,875,535.000879
31,074
pythondev
help
<https://docs.python.org/3/library/os.html#os.listdir>
2018-01-25T10:20:18.000375
Micki
pythondev_help_Micki_2018-01-25T10:20:18.000375
1,516,875,618.000375
31,075
pythondev
help
ty
2018-01-25T10:20:53.000496
Pennie
pythondev_help_Pennie_2018-01-25T10:20:53.000496
1,516,875,653.000496
31,076
pythondev
help
Hello Everyone, please help with few python regex docs for analyzing log files.
2018-01-25T11:31:18.000315
Karin
pythondev_help_Karin_2018-01-25T11:31:18.000315
1,516,879,878.000315
31,077
pythondev
help
Eternally have issues with mock.patch :confused:
2018-01-25T11:31:26.001165
Cori
pythondev_help_Cori_2018-01-25T11:31:26.001165
1,516,879,886.001165
31,078
pythondev
help
Trying to patch('<http://requests.post|requests.post>') but it tries to send requests
2018-01-25T11:31:42.000099
Cori
pythondev_help_Cori_2018-01-25T11:31:42.000099
1,516,879,902.000099
31,079
pythondev
help
try to patch('requests') and I get invalid target
2018-01-25T11:31:51.000127
Cori
pythondev_help_Cori_2018-01-25T11:31:51.000127
1,516,879,911.000127
31,080
pythondev
help
_whyyyyyy_
2018-01-25T11:31:53.000793
Cori
pythondev_help_Cori_2018-01-25T11:31:53.000793
1,516,879,913.000793
31,081
pythondev
help
using `mock.patch` is never an easy thing :smile:
2018-01-25T11:50:46.000562
Sadye
pythondev_help_Sadye_2018-01-25T11:50:46.000562
1,516,881,046.000562
31,082
pythondev
help
regarding requests module... Just use library `responses`
2018-01-25T11:53:45.000201
Sadye
pythondev_help_Sadye_2018-01-25T11:53:45.000201
1,516,881,225.000201
31,083
pythondev
help
And save your soul :slightly_smiling_face:
2018-01-25T11:53:53.000294
Sadye
pythondev_help_Sadye_2018-01-25T11:53:53.000294
1,516,881,233.000294
31,084
pythondev
help
<@Karin> <http://www.nohello.com> for the rescue :wink:
2018-01-25T11:54:43.000517
Sadye
pythondev_help_Sadye_2018-01-25T11:54:43.000517
1,516,881,283.000517
31,085
pythondev
help
For mocking I like to use `flexmock`, it makes it clear and easy
2018-01-25T11:57:17.000918
Nancy
pythondev_help_Nancy_2018-01-25T11:57:17.000918
1,516,881,437.000918
31,086
pythondev
help
Have you tried writing your own? There's a great tool at <https://regex101.com/>. It's good way to learn :smiley:
2018-01-25T12:32:32.000473
Porsha
pythondev_help_Porsha_2018-01-25T12:32:32.000473
1,516,883,552.000473
31,087
pythondev
help
:confused:
2018-01-25T12:39:51.001053
Cori
pythondev_help_Cori_2018-01-25T12:39:51.001053
1,516,883,991.001053
31,088
pythondev
help
I'm not going to install a whole library to solve a one line issue I know I can get working somehow
2018-01-25T12:40:09.000391
Cori
pythondev_help_Cori_2018-01-25T12:40:09.000391
1,516,884,009.000391
31,089
pythondev
help
Thanks though guys
2018-01-25T12:40:18.000296
Cori
pythondev_help_Cori_2018-01-25T12:40:18.000296
1,516,884,018.000296
31,090
pythondev
help
the struggle continues...
2018-01-25T12:40:21.000189
Cori
pythondev_help_Cori_2018-01-25T12:40:21.000189
1,516,884,021.000189
31,091
pythondev
help
<@Cori> have you tried patching it relative to the file you are using it in?
2018-01-25T12:40:40.000633
Zack
pythondev_help_Zack_2018-01-25T12:40:40.000633
1,516,884,040.000633
31,092
pythondev
help
meaning like if you are testing `foo.bar` and inside `foo.bar` you import requests, maybe try patching `<http://foo.bar.requests.post|foo.bar.requests.post>`
2018-01-25T12:41:09.000928
Zack
pythondev_help_Zack_2018-01-25T12:41:09.000928
1,516,884,069.000928
31,093
pythondev
help
have you try not patching it ? :smile: and mock your function that call the request ?
2018-01-25T12:43:07.000715
Micki
pythondev_help_Micki_2018-01-25T12:43:07.000715
1,516,884,187.000715
31,094
pythondev
help
mock.patch works exactly like that. But once you move target code somewhere - all tests will break horribly
2018-01-25T12:45:10.000161
Sadye
pythondev_help_Sadye_2018-01-25T12:45:10.000161
1,516,884,310.000161
31,095
pythondev
help
I think that `mock.patch.object` might work though
2018-01-25T12:46:04.001051
Sadye
pythondev_help_Sadye_2018-01-25T12:46:04.001051
1,516,884,364.001051
31,096
pythondev
help
yeah, I mean I kind of expect that when patching things generally
2018-01-25T12:46:16.000285
Zack
pythondev_help_Zack_2018-01-25T12:46:16.000285
1,516,884,376.000285
31,097
pythondev
help
true. But when I did it first time I suffered so much :harold:
2018-01-25T12:47:51.000646
Sadye
pythondev_help_Sadye_2018-01-25T12:47:51.000646
1,516,884,471.000646
31,098
pythondev
help
heh
2018-01-25T12:49:17.000430
Zack
pythondev_help_Zack_2018-01-25T12:49:17.000430
1,516,884,557.00043
31,099
pythondev
help
it’s the suffering that’s expected. :stuck_out_tongue:
2018-01-25T12:49:33.000585
Zack
pythondev_help_Zack_2018-01-25T12:49:33.000585
1,516,884,573.000585
31,100
pythondev
help
sad_pepe.png
2018-01-25T12:49:42.000541
Sadye
pythondev_help_Sadye_2018-01-25T12:49:42.000541
1,516,884,582.000541
31,101
pythondev
help
<@Zack> tried it already
2018-01-25T12:57:34.000185
Cori
pythondev_help_Cori_2018-01-25T12:57:34.000185
1,516,885,054.000185
31,102
pythondev
help
<@Micki> that would be great if it weren't the function I was actually testing :stuck_out_tongue:
2018-01-25T12:58:01.000706
Cori
pythondev_help_Cori_2018-01-25T12:58:01.000706
1,516,885,081.000706
31,103
pythondev
help
yeah I’d go with what valentjedi said about patching the requests object maybe
2018-01-25T12:58:04.000044
Zack
pythondev_help_Zack_2018-01-25T12:58:04.000044
1,516,885,084.000044
31,104
pythondev
help
As in requests itself?
2018-01-25T12:58:23.000028
Cori
pythondev_help_Cori_2018-01-25T12:58:23.000028
1,516,885,103.000028
31,105
pythondev
help
right
2018-01-25T12:58:40.000989
Zack
pythondev_help_Zack_2018-01-25T12:58:40.000989
1,516,885,120.000989
31,106
pythondev
help
Didn't work
2018-01-25T12:59:21.000629
Cori
pythondev_help_Cori_2018-01-25T12:59:21.000629
1,516,885,161.000629
31,107
pythondev
help
:neutral_face:
2018-01-25T12:59:30.000085
Cori
pythondev_help_Cori_2018-01-25T12:59:30.000085
1,516,885,170.000085
31,108
pythondev
help
You see why I'm stuck right?
2018-01-25T12:59:40.000811
Cori
pythondev_help_Cori_2018-01-25T12:59:40.000811
1,516,885,180.000811
31,109
pythondev
help
I've tried mocking just requests. Says it doesn't exist
2018-01-25T12:59:56.000305
Cori
pythondev_help_Cori_2018-01-25T12:59:56.000305
1,516,885,196.000305
31,110
pythondev
help
so you are importing requests in `foo.bar` but when you try and patch `foo.bar.requests` it says it doesn’t exist?
2018-01-25T13:00:30.000992
Zack
pythondev_help_Zack_2018-01-25T13:00:30.000992
1,516,885,230.000992
31,111
pythondev
help
That does nothing
2018-01-25T13:00:52.000254
Cori
pythondev_help_Cori_2018-01-25T13:00:52.000254
1,516,885,252.000254
31,112
pythondev
help
I get timeout error because it makes requests to a server that's but running
2018-01-25T13:01:08.000833
Cori
pythondev_help_Cori_2018-01-25T13:01:08.000833
1,516,885,268.000833
31,113
pythondev
help
This is in a Django form
2018-01-25T13:01:38.000845
Cori
pythondev_help_Cori_2018-01-25T13:01:38.000845
1,516,885,298.000845
31,114
pythondev
help
Specifically `module.forms.form.save`
2018-01-25T13:01:58.000614
Cori
pythondev_help_Cori_2018-01-25T13:01:58.000614
1,516,885,318.000614
31,115
pythondev
help
is it possible to throw together what you have in a small standalone example? I’ve dealt with this somewhat recently so I might be able to get it going if I could see what you see
2018-01-25T13:02:04.000434
Zack
pythondev_help_Zack_2018-01-25T13:02:04.000434
1,516,885,324.000434
31,116
pythondev
help
I've tried `requests` - doesn't exist `<http://requests.post|requests.post>` - timeout `forms.requests` - forms doesn't exist `<http://forms.requests.post|forms.requests.post>` - same as above `module.forms.requests` - timeout `<http://module.forms.requests.post|module.forms.requests.post>` - same as above
2018-01-25T13:03:48.001062
Cori
pythondev_help_Cori_2018-01-25T13:03:48.001062
1,516,885,428.001062
31,117
pythondev
help
I just found out relatively old project where I did mock requests
2018-01-25T13:04:17.000381
Sadye
pythondev_help_Sadye_2018-01-25T13:04:17.000381
1,516,885,457.000381
31,118
pythondev
help
Let me post the code
2018-01-25T13:04:20.000835
Sadye
pythondev_help_Sadye_2018-01-25T13:04:20.000835
1,516,885,460.000835
31,119
pythondev
help
I'll put something together but covered in ill children right now :-D
2018-01-25T13:04:23.000628
Cori
pythondev_help_Cori_2018-01-25T13:04:23.000628
1,516,885,463.000628
31,120
pythondev
help
heh, no rush
2018-01-25T13:04:32.001054
Zack
pythondev_help_Zack_2018-01-25T13:04:32.001054
1,516,885,472.001054
31,121
pythondev
help
I’ll be around this evening
2018-01-25T13:04:36.000993
Zack
pythondev_help_Zack_2018-01-25T13:04:36.000993
1,516,885,476.000993
31,122
pythondev
help
I've had this issue before as well
2018-01-25T13:04:36.001151
Cori
pythondev_help_Cori_2018-01-25T13:04:36.001151
1,516,885,476.001151
31,123