On Thu, May 19, 2016 at 12:34 PM, Terry Carroll wrote:
> Is anyone aware of any good tutorials on testing one's Python code?
>
> These days, I'm a hobby programmer, writing little things just for my own
> use, and don't really sweat testing much. But I do have one niche
> open-source project where
Dear Peter & Alan,
Thanks alot. Have a great day
Cheers,
Hank
On Fri, May 20, 2016 at 12:00 AM, wrote:
> Send Tutor mailing list submissions to
> tutor@python.org
>
> To subscribe or unsubscribe via the World Wide Web, visit
> https://mail.python.org/mailman/listinfo/tutor
> or
On 19/05/16 20:34, Terry Carroll wrote:
> Is anyone aware of any good tutorials on testing one's Python code?
I'm not a big fan of video tutorials but I recently had to teach
myself Junit testing (and mockito) in Java and I found that
Youtube videos really helped. I know there are similar videos
o
On 19/05/16 19:01, Craig Jackson wrote:
> Adding the parentheses worked. So sorry for taking your time. I'm new
> to Python and not at all a programmer. Thanks for your help.
No trouble, that's what the list is here for.
Just remember next time to post the code that fails
rather than the code tha
Is anyone aware of any good tutorials on testing one's Python code?
These days, I'm a hobby programmer, writing little things just for my own
use, and don't really sweat testing much. But I do have one niche
open-source project where I need to be a bit more regimented, and
specifically need to
Adding the parentheses worked. So sorry for taking your time. I'm new
to Python and not at all a programmer. Thanks for your help.
On Thu, May 19, 2016 at 11:37 AM, Alan Gauld via Tutor wrote:
> On 19/05/16 15:11, Craig Jackson wrote:
>
>> ftp. In a nutshell the problem is that if the two objecti
jarod_v6--- via Tutor wrote:
> Dear All!
> This is my data from a file. I want to obtain a count table how many
> times c11 are present for each project and Samples and Program.
>
> ['Program', 'Sample', 'Featurename', 'Project'],
> ['A', 'A100', 'c11', 'post50'],
> ['A', 'A100', 'c12', 'post
Dear All!
This is my data from a file. I want to obtain a count table how many times c11
are present for each project and Samples and Program.
['Program', 'Sample', 'Featurename', 'Project'],
['A', 'A100', 'c11', 'post50'],
['A', 'A100', 'c12', 'post50'],
['A', 'A100', 'c14', 'post50'],
['A
On 19/05/16 15:11, Craig Jackson wrote:
> ftp. In a nutshell the problem is that if the two objectives are
> combined into one Python script, ftp stops uploading in the middle of
> the file, but if the same code is split into two files, web page
> creation in one script and ftp in another, and the
On 19/05/16 10:03, Crusier wrote:
> c.execute('''CREATE TABLE stocks
> (code text)''')
>
> # Insert a row of data
> List = ['1', '2', '3', '4', '5', '6', '7',
> '8', '9', '00010', '00011', '00012']
>
> c.executemany('INSERT INTO stocks VALUES (?)'
On 19/05/16 12:51, Ek Esawi wrote:
> Thanks again!
>
> I tried a combination of the suggestions and still not getting what i want.
>
> Here are the original code, file, and output.
>
> CODE
>
> mport csv; import numpy as np; from datetime import datetime, date, time
>
> CF = lambda date: datet
The Python script has two objectives: a) create a web page from data
in an Excel spreadsheet, b) upload that web page to a web server using
ftp. In a nutshell the problem is that if the two objectives are
combined into one Python script, ftp stops uploading in the middle of
the file, but if the sam
Thanks again!
I tried a combination of the suggestions and still not getting what i want.
Here are the original code, file, and output.
CODE
mport csv; import numpy as np; from datetime import datetime, date, time
CF = lambda date: datetime.strptime(bytes.decode(date),
'%m/%d/%Y').strftime('%Y
Crusier wrote:
> Dear Alan,
>
> I have read your web page and try to test thing out on SQLite.
>
> Attached is my code:
>
> import sqlite3
> conn = sqlite3.connect('example1.db')
> c = conn.cursor()
> c.execute('drop table if exists stocks')
> c.execute('''CREATE TABLE stocks
> (co
Dear Alan,
I have read your web page and try to test thing out on SQLite.
Attached is my code:
import sqlite3
conn = sqlite3.connect('example1.db')
c = conn.cursor()
c.execute('drop table if exists stocks')
c.execute('''CREATE TABLE stocks
(code text)''')
# Insert a row of data
Lis
On 19/05/16 01:31, Ek Esawi wrote:
> Thanks Alan!
>
> Taking the strtime off did not work either and printed dattime.dattime(very
> long date format).
But isn't that just the representation of a datetime object (which is
what strptime produces)? In other words it's an object not a string.
Can y
Thanks Alan!
Taking the strtime off did not work either and printed dattime.dattime(very
long date format). I was able to get the integer and string parts fixed via
dtype,
but could not do the same for date and time. I have a feeling that
structured arrays might do the trick but don't know yet how
17 matches
Mail list logo