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
for example your query above, providing said exception info would be a key part in figuring the solution
2019-03-28T10:57:23.082200
Hiroko
pythondev_help_Hiroko_2019-03-28T10:57:23.082200
1,553,770,643.0822
15,521
pythondev
help
sorry
2019-03-28T11:02:31.082400
Florencio
pythondev_help_Florencio_2019-03-28T11:02:31.082400
1,553,770,951.0824
15,522
pythondev
help
`int() argument must be a string, a bytes-like object or a number, not 'builtin_function_or_method'`
2019-03-28T11:02:35.082600
Florencio
pythondev_help_Florencio_2019-03-28T11:02:35.082600
1,553,770,955.0826
15,523
pythondev
help
You really need to show your code
2019-03-28T11:03:43.083200
Clemmie
pythondev_help_Clemmie_2019-03-28T11:03:43.083200
1,553,771,023.0832
15,524
pythondev
help
the entire method
2019-03-28T11:03:49.083500
Clemmie
pythondev_help_Clemmie_2019-03-28T11:03:49.083500
1,553,771,029.0835
15,525
pythondev
help
That error makes little sense in the context of what we have been discussing
2019-03-28T11:04:15.083900
Clemmie
pythondev_help_Clemmie_2019-03-28T11:04:15.083900
1,553,771,055.0839
15,526
pythondev
help
how to convert a python datetime object to another timezone with pendulum? in the pendulum documentation it shows how to convert a pendulum object but it's not clear how to convert something that's not a pendulum object
2019-03-28T11:04:32.084300
Dawn
pythondev_help_Dawn_2019-03-28T11:04:32.084300
1,553,771,072.0843
15,527
pythondev
help
First set the datetime you have to a pendulum object, then follow the docs. <https://github.com/sdispater/pendulum/issues/29>
2019-03-28T11:06:54.085600
Clemmie
pythondev_help_Clemmie_2019-03-28T11:06:54.085600
1,553,771,214.0856
15,528
pythondev
help
ah like that. but i do need a datetime object because i'm sending it to an odbc
2019-03-28T11:11:59.087100
Dawn
pythondev_help_Dawn_2019-03-28T11:11:59.087100
1,553,771,519.0871
15,529
pythondev
help
that's becoming a mess..
2019-03-28T11:12:46.088000
Dawn
pythondev_help_Dawn_2019-03-28T11:12:46.088000
1,553,771,566.088
15,530
pythondev
help
okay
2019-03-28T11:13:28.088200
Florencio
pythondev_help_Florencio_2019-03-28T11:13:28.088200
1,553,771,608.0882
15,531
pythondev
help
I'll do that
2019-03-28T11:13:36.088800
Florencio
pythondev_help_Florencio_2019-03-28T11:13:36.088800
1,553,771,616.0888
15,532
pythondev
help
None
2019-03-28T11:14:46.090400
Florencio
pythondev_help_Florencio_2019-03-28T11:14:46.090400
1,553,771,686.0904
15,533
pythondev
help
what is `id` in this context?
2019-03-28T11:19:38.091100
Hiroko
pythondev_help_Hiroko_2019-03-28T11:19:38.091100
1,553,771,978.0911
15,534
pythondev
help
you don’t specify it at all
2019-03-28T11:19:43.091300
Hiroko
pythondev_help_Hiroko_2019-03-28T11:19:43.091300
1,553,771,983.0913
15,535
pythondev
help
line 16 is the first time it shows up, hasn’t been declared anywhere else
2019-03-28T11:20:10.092200
Hiroko
pythondev_help_Hiroko_2019-03-28T11:20:10.092200
1,553,772,010.0922
15,536
pythondev
help
any fast way to convert from pendulum back to datetime object? the only example i could find is ``` if isinstance(value, pendulum.Pendulum): value = datetime.datetime( value.year, value.month, value.day, value.hour, value.minute, value.second, value.microsecond, value.tzinfo ) ``` that's a real detour
2019-03-28T11:20:44.092400
Dawn
pythondev_help_Dawn_2019-03-28T11:20:44.092400
1,553,772,044.0924
15,537
pythondev
help
and even that doesn't work as wanted, i just want a naive datetime as output, without the timezone explicitly included
2019-03-28T11:21:32.093000
Dawn
pythondev_help_Dawn_2019-03-28T11:21:32.093000
1,553,772,092.093
15,538
pythondev
help
Why are you using pendulum?
2019-03-28T11:24:12.093500
Clemmie
pythondev_help_Clemmie_2019-03-28T11:24:12.093500
1,553,772,252.0935
15,539
pythondev
help
to convert to another timezone?
2019-03-28T11:24:35.094000
Dawn
pythondev_help_Dawn_2019-03-28T11:24:35.094000
1,553,772,275.094
15,540
pythondev
help
don't know any other way to do that
2019-03-28T11:24:42.094300
Dawn
pythondev_help_Dawn_2019-03-28T11:24:42.094300
1,553,772,282.0943
15,541
pythondev
help
the use case is: i have a datetime object with UTC timezone i want to convert it to CET timezone output should still be a datetime object because a database is going to handle it
2019-03-28T11:25:18.095600
Dawn
pythondev_help_Dawn_2019-03-28T11:25:18.095600
1,553,772,318.0956
15,542
pythondev
help
do you need pendulum for anything else? if not you should probably use the `pytz` package (python timezone)
2019-03-28T11:25:32.095800
Clemmie
pythondev_help_Clemmie_2019-03-28T11:25:32.095800
1,553,772,332.0958
15,543
pythondev
help
i use it in other places to set the current time, but can use both
2019-03-28T11:26:20.096300
Dawn
pythondev_help_Dawn_2019-03-28T11:26:20.096300
1,553,772,380.0963
15,544
pythondev
help
as long as it fixes my problems :upside_down_face:
2019-03-28T11:26:32.096800
Dawn
pythondev_help_Dawn_2019-03-28T11:26:32.096800
1,553,772,392.0968
15,545
pythondev
help
it should, it is basically for editing timezone info on python datetime objects
2019-03-28T11:27:12.097800
Clemmie
pythondev_help_Clemmie_2019-03-28T11:27:12.097800
1,553,772,432.0978
15,546
pythondev
help
<@Hiroko> id is supposed to be msg_list.id
2019-03-28T11:27:39.098900
Florencio
pythondev_help_Florencio_2019-03-28T11:27:39.098900
1,553,772,459.0989
15,547
pythondev
help
but rn I don't even know what to think
2019-03-28T11:27:59.099600
Florencio
pythondev_help_Florencio_2019-03-28T11:27:59.099600
1,553,772,479.0996
15,548
pythondev
help
I should prolly take coffee
2019-03-28T11:28:09.100300
Florencio
pythondev_help_Florencio_2019-03-28T11:28:09.100300
1,553,772,489.1003
15,549
pythondev
help
If you want to get the list of all transactions that have an `accepted` message you can do it with the one-liner `transactions = Transactions.objects.filter(message__status = "Accepted")`
2019-03-28T11:32:52.103300
Clemmie
pythondev_help_Clemmie_2019-03-28T11:32:52.103300
1,553,772,772.1033
15,550
pythondev
help
It reads a little odd otherwise, because you are getting all the accepted Messages, but then setting tick based on at least one of those messages being in a transaction
2019-03-28T11:34:19.104700
Clemmie
pythondev_help_Clemmie_2019-03-28T11:34:19.104700
1,553,772,859.1047
15,551
pythondev
help
Hi all. How does someone escape the hash `#` symbol in an `.env` value? I've tried using a backslash `\` but it's not working
2019-03-28T11:37:20.107500
Jamey
pythondev_help_Jamey_2019-03-28T11:37:20.107500
1,553,773,040.1075
15,552
pythondev
help
I'm new to python development and I am looking to build some scripts to configure linux VMs. Something like a bootstrap script with options to install different components like apache or mysql depending on the server's purpose. This is mostly just a learning exercise. Any suggestions on places I can look to get me started? Specifically, are there packages that have usefull tools for common system administration tasks? Thanks!
2019-03-28T11:38:42.109000
Leonarda
pythondev_help_Leonarda_2019-03-28T11:38:42.109000
1,553,773,122.109
15,553
pythondev
help
<@Clemmie> I only want to work with id
2019-03-28T11:38:53.109300
Florencio
pythondev_help_Florencio_2019-03-28T11:38:53.109300
1,553,773,133.1093
15,554
pythondev
help
can you describe what you are trying to do in words - your code doesn’t make a huge amount of sense to me
2019-03-28T11:39:43.110000
Clemmie
pythondev_help_Clemmie_2019-03-28T11:39:43.110000
1,553,773,183.11
15,555
pythondev
help
I understand what it is trying to do, but what it is trying to do is confusing
2019-03-28T11:39:59.110400
Clemmie
pythondev_help_Clemmie_2019-03-28T11:39:59.110400
1,553,773,199.1104
15,556
pythondev
help
okay i'll try
2019-03-28T11:41:06.110700
Florencio
pythondev_help_Florencio_2019-03-28T11:41:06.110700
1,553,773,266.1107
15,557
pythondev
help
i have lets say 4 different request for different products
2019-03-28T11:41:43.111400
Florencio
pythondev_help_Florencio_2019-03-28T11:41:43.111400
1,553,773,303.1114
15,558
pythondev
help
this method shows only the ones I accepted
2019-03-28T11:42:12.111900
Florencio
pythondev_help_Florencio_2019-03-28T11:42:12.111900
1,553,773,332.1119
15,559
pythondev
help
in the ones accepted, they're some I have attended to and others I'm yet to
2019-03-28T11:42:41.112500
Florencio
pythondev_help_Florencio_2019-03-28T11:42:41.112500
1,553,773,361.1125
15,560
pythondev
help
the ones I've attended to, their Ids are saved in `Transaction` table
2019-03-28T11:43:20.113700
Florencio
pythondev_help_Florencio_2019-03-28T11:43:20.113700
1,553,773,400.1137
15,561
pythondev
help
I get that - but the code seems to care about returning the accepted messages, where it seems to me you want to return the list of transactions whose messages were accepted
2019-03-28T11:43:27.114000
Clemmie
pythondev_help_Clemmie_2019-03-28T11:43:27.114000
1,553,773,407.114
15,562
pythondev
help
okay
2019-03-28T11:44:43.114800
Florencio
pythondev_help_Florencio_2019-03-28T11:44:43.114800
1,553,773,483.1148
15,563
pythondev
help
am i correct?
2019-03-28T11:44:51.115300
Clemmie
pythondev_help_Clemmie_2019-03-28T11:44:51.115300
1,553,773,491.1153
15,564
pythondev
help
or not
2019-03-28T11:44:54.115600
Clemmie
pythondev_help_Clemmie_2019-03-28T11:44:54.115600
1,553,773,494.1156
15,565
pythondev
help
but not all Accepted Messages are in Transaction
2019-03-28T11:45:17.116100
Florencio
pythondev_help_Florencio_2019-03-28T11:45:17.116100
1,553,773,517.1161
15,566
pythondev
help
That's why I just go with if it is Accepted and also have it's Id in Transaction
2019-03-28T11:45:44.116700
Florencio
pythondev_help_Florencio_2019-03-28T11:45:44.116700
1,553,773,544.1167
15,567
pythondev
help
Do you need all accepted messages, or only accepted messages that are also in a transaction?
2019-03-28T11:46:20.117300
Clemmie
pythondev_help_Clemmie_2019-03-28T11:46:20.117300
1,553,773,580.1173
15,568
pythondev
help
Or all accepted messages, and whether they are in a transaction or not
2019-03-28T11:46:42.117700
Clemmie
pythondev_help_Clemmie_2019-03-28T11:46:42.117700
1,553,773,602.1177
15,569
pythondev
help
yeah all Accepted messages that are in Transaction will have `tick = "ok"`
2019-03-28T11:48:43.118200
Florencio
pythondev_help_Florencio_2019-03-28T11:48:43.118200
1,553,773,723.1182
15,570
pythondev
help
else `tick = ""`
2019-03-28T11:50:05.119100
Florencio
pythondev_help_Florencio_2019-03-28T11:50:05.119100
1,553,773,805.1191
15,571
pythondev
help
so all accepted messages, with tick ok for those in a transaction
2019-03-28T11:50:08.119300
Clemmie
pythondev_help_Clemmie_2019-03-28T11:50:08.119300
1,553,773,808.1193
15,572
pythondev
help
yeah
2019-03-28T11:50:37.119500
Florencio
pythondev_help_Florencio_2019-03-28T11:50:37.119500
1,553,773,837.1195
15,573
pythondev
help
that's it
2019-03-28T11:50:42.119700
Florencio
pythondev_help_Florencio_2019-03-28T11:50:42.119700
1,553,773,842.1197
15,574
pythondev
help
Ok, so now put that into code. In particular you are not iterating through the message list to check if each message is in a transaction (and you will need to use `filter()` in the lookup, not `get()` as by you model a message can be in more than one transaction. You will probably also want to put them into a dict like `{'ok':[&lt;list of messages&gt;'], 'not':[&lt;list_of_messages&gt;]}`
2019-03-28T11:54:55.123000
Clemmie
pythondev_help_Clemmie_2019-03-28T11:54:55.123000
1,553,774,095.123
15,575
pythondev
help
wow
2019-03-28T11:56:59.123200
Florencio
pythondev_help_Florencio_2019-03-28T11:56:59.123200
1,553,774,219.1232
15,576
pythondev
help
i'll try to understand what you mean
2019-03-28T11:57:51.123600
Florencio
pythondev_help_Florencio_2019-03-28T11:57:51.123600
1,553,774,271.1236
15,577
pythondev
help
i think i'll just leave this
2019-03-28T12:04:30.124000
Florencio
pythondev_help_Florencio_2019-03-28T12:04:30.124000
1,553,774,670.124
15,578
pythondev
help
cos in my head it should be simple, but when i try to implement it, it's something else
2019-03-28T12:05:12.124900
Florencio
pythondev_help_Florencio_2019-03-28T12:05:12.124900
1,553,774,712.1249
15,579
pythondev
help
I'll make the field unique so that I dont have the same request twice in `Transaction`
2019-03-28T12:06:15.125800
Florencio
pythondev_help_Florencio_2019-03-28T12:06:15.125800
1,553,774,775.1258
15,580
pythondev
help
You can also make it a OneToOne - it sounds like that is somewhat more correct for your use case
2019-03-28T12:07:09.126500
Clemmie
pythondev_help_Clemmie_2019-03-28T12:07:09.126500
1,553,774,829.1265
15,581
pythondev
help
but it's Foreignkey
2019-03-28T12:07:46.126800
Florencio
pythondev_help_Florencio_2019-03-28T12:07:46.126800
1,553,774,866.1268
15,582
pythondev
help
Is this a production system?
2019-03-28T12:07:58.127000
Clemmie
pythondev_help_Clemmie_2019-03-28T12:07:58.127000
1,553,774,878.127
15,583
pythondev
help
yep
2019-03-28T12:08:08.127200
Florencio
pythondev_help_Florencio_2019-03-28T12:08:08.127200
1,553,774,888.1272
15,584
pythondev
help
oh, ok
2019-03-28T12:08:10.127400
Clemmie
pythondev_help_Clemmie_2019-03-28T12:08:10.127400
1,553,774,890.1274
15,585
pythondev
help
that's why I wanted to differentiate them by `ticks`
2019-03-28T12:09:30.127900
Florencio
pythondev_help_Florencio_2019-03-28T12:09:30.127900
1,553,774,970.1279
15,586
pythondev
help
so that I know while going through the list of all `Accepted` requests, I could see the ones with the `ticks`
2019-03-28T12:10:28.128800
Florencio
pythondev_help_Florencio_2019-03-28T12:10:28.128800
1,553,775,028.1288
15,587
pythondev
help
I would do a boolean as True/False rather than "ok", ""
2019-03-28T12:23:39.129200
Maricruz
pythondev_help_Maricruz_2019-03-28T12:23:39.129200
1,553,775,819.1292
15,588
pythondev
help
just a small thing
2019-03-28T12:23:41.129500
Maricruz
pythondev_help_Maricruz_2019-03-28T12:23:41.129500
1,553,775,821.1295
15,589
pythondev
help
Good afternoon guys, its a pleasure to find a community in slack around django learning!!
2019-03-28T12:28:25.130100
Sharika
pythondev_help_Sharika_2019-03-28T12:28:25.130100
1,553,776,105.1301
15,590
pythondev
help
Im trying to login into powerbi from my portal, get the tokens and thru that avoid the extra login step in powerbi embedded reports. Have any of you guys worked in something related or give me some advice, i was looking into adal but dont get the whole idea
2019-03-28T12:29:32.131500
Sharika
pythondev_help_Sharika_2019-03-28T12:29:32.131500
1,553,776,172.1315
15,591
pythondev
help
anyone help plz,when m running this exe it says:import error, DLL load failed,the specified module could not be foud
2019-03-28T12:51:35.131600
Svetlana
pythondev_help_Svetlana_2019-03-28T12:51:35.131600
1,553,777,495.1316
15,592
pythondev
help
make sure tcl86t.dll and tk86t.dll are in the directory
2019-03-28T12:55:33.132400
Sharika
pythondev_help_Sharika_2019-03-28T12:55:33.132400
1,553,777,733.1324
15,593
pythondev
help
check if this can help <https://bitbucket.org/anthony_tuininga/cx_freeze/issues/155/required-environment-variables-tcl_library>
2019-03-28T12:56:27.132600
Sharika
pythondev_help_Sharika_2019-03-28T12:56:27.132600
1,553,777,787.1326
15,594
pythondev
help
yes both r in the directory
2019-03-28T12:58:25.132800
Svetlana
pythondev_help_Svetlana_2019-03-28T12:58:25.132800
1,553,777,905.1328
15,595
pythondev
help
why dont you try into the executable folder?
2019-03-28T12:59:24.133100
Sharika
pythondev_help_Sharika_2019-03-28T12:59:24.133100
1,553,777,964.1331
15,596
pythondev
help
i didnt get that
2019-03-28T13:02:10.133500
Svetlana
pythondev_help_Svetlana_2019-03-28T13:02:10.133500
1,553,778,130.1335
15,597
pythondev
help
apologies for the late reply. I see now. Thanks for the heads up.
2019-03-28T13:03:41.133700
Nenita
pythondev_help_Nenita_2019-03-28T13:03:41.133700
1,553,778,221.1337
15,598
pythondev
help
<@Deon> Sorry for the delay on replying to this.
2019-03-28T14:21:49.133900
Carmen
pythondev_help_Carmen_2019-03-28T14:21:49.133900
1,553,782,909.1339
15,599
pythondev
help
So what you're doing is setting up a full git repo copy of your code on your server and serving from that directory.
2019-03-28T14:22:29.134100
Carmen
pythondev_help_Carmen_2019-03-28T14:22:29.134100
1,553,782,949.1341
15,600
pythondev
help
Then you can use the built-in git remote functionality to push code to that remote production repo with a simple `git push production master`
2019-03-28T14:29:06.134300
Carmen
pythondev_help_Carmen_2019-03-28T14:29:06.134300
1,553,783,346.1343
15,601
pythondev
help
Assuming, of course, that you've named the remote `production` and you're serving up the `master` branch.
2019-03-28T14:29:28.134500
Carmen
pythondev_help_Carmen_2019-03-28T14:29:28.134500
1,553,783,368.1345
15,602
pythondev
help
If you're serving from gunicorn, however, I'd recommend that you wrap the push deployment process inside another script (such as a Fabric fabfile) and have it restart gunicorn automatically once it's pushed the code to the production git remote.
2019-03-28T14:30:41.134700
Carmen
pythondev_help_Carmen_2019-03-28T14:30:41.134700
1,553,783,441.1347
15,603
pythondev
help
I think my understanding of git kinda stinks, so let me read up a little bit more on that so it makes more sense
2019-03-28T14:31:51.134900
Deon
pythondev_help_Deon_2019-03-28T14:31:51.134900
1,553,783,511.1349
15,604
pythondev
help
has anyone in here used jinja2 to generate HTML, PHP, Js files? I am thinking of automating some part of the process for a current project I'm working on and could use some advice in the structure.
2019-03-28T17:20:32.137200
Henrietta
pythondev_help_Henrietta_2019-03-28T17:20:32.137200
1,553,793,632.1372
15,605
pythondev
help
Depending on what you’re hoping to learn, you could take a look at the `subprocess` module to execute commands to install packages. You might want to look at setting up config files to specify those packages/versions etc and parse those with the script. Don’t know of any python provisioning libraries that might help you with this. Learning `subprocess` might be more useful in any case.
2019-03-28T17:38:19.137300
Henry
pythondev_help_Henry_2019-03-28T17:38:19.137300
1,553,794,699.1373
15,606
pythondev
help
yeah! It was exhilarating :megaman:
2019-03-28T18:16:11.137500
Elmo
pythondev_help_Elmo_2019-03-28T18:16:11.137500
1,553,796,971.1375
15,607
pythondev
help
If I'm going to be logging to a database should I use a using a sockethandler to connect to it?
2019-03-28T21:05:25.138300
Huong
pythondev_help_Huong_2019-03-28T21:05:25.138300
1,553,807,125.1383
15,608
pythondev
help
log _to_ a db?
2019-03-28T21:05:48.138900
Hiroko
pythondev_help_Hiroko_2019-03-28T21:05:48.138900
1,553,807,148.1389
15,609
pythondev
help
why?
2019-03-28T21:05:54.139300
Hiroko
pythondev_help_Hiroko_2019-03-28T21:05:54.139300
1,553,807,154.1393
15,610
pythondev
help
log to a flat file
2019-03-28T21:06:03.139800
Candra
pythondev_help_Candra_2019-03-28T21:06:03.139800
1,553,807,163.1398
15,611
pythondev
help
if you were saying elasticsearch or solr for a search engine, then I could understand
2019-03-28T21:06:14.140200
Hiroko
pythondev_help_Hiroko_2019-03-28T21:06:14.140200
1,553,807,174.1402
15,612
pythondev
help
<@Candra> rotating flat file :slightly_smiling_face:
2019-03-28T21:06:26.140700
Hiroko
pythondev_help_Hiroko_2019-03-28T21:06:26.140700
1,553,807,186.1407
15,613
pythondev
help
^
2019-03-28T21:06:30.140900
Candra
pythondev_help_Candra_2019-03-28T21:06:30.140900
1,553,807,190.1409
15,614
pythondev
help
Well it may eventually get to that point
2019-03-28T21:06:34.141100
Huong
pythondev_help_Huong_2019-03-28T21:06:34.141100
1,553,807,194.1411
15,615
pythondev
help
one giant log file :upside_down_face:
2019-03-28T21:06:39.141300
Candra
pythondev_help_Candra_2019-03-28T21:06:39.141300
1,553,807,199.1413
15,616
pythondev
help
been there, done that
2019-03-28T21:06:44.141800
Hiroko
pythondev_help_Hiroko_2019-03-28T21:06:44.141800
1,553,807,204.1418
15,617
pythondev
help
hah
2019-03-28T21:06:46.142000
Huong
pythondev_help_Huong_2019-03-28T21:06:46.142000
1,553,807,206.142
15,618
pythondev
help
it was about 18 GB in size
2019-03-28T21:06:49.142200
Hiroko
pythondev_help_Hiroko_2019-03-28T21:06:49.142200
1,553,807,209.1422
15,619
pythondev
help
lets just say grep was a wee bit slow
2019-03-28T21:07:04.142800
Hiroko
pythondev_help_Hiroko_2019-03-28T21:07:04.142800
1,553,807,224.1428
15,620