On Sat, Apr 13, 2013 at 4:28 PM, Mark Janssen wrote:
>> Mark, this proposal is out of place on a Python list, because it proposes an
>> object methodology radically different from any that is implemented in
>> Python now, or is even remotely likely to be implemented in Python in the
>> future.
>
>
> Mark, this proposal is out of place on a Python list, because it proposes an
> object methodology radically different from any that is implemented in
> Python now, or is even remotely likely to be implemented in Python in the
> future.
Wow, you guys are a bunch of ninnies. I'm going to find som
David M Chess於 2013年4月12日星期五UTC+8下午11時37分28秒寫道:
> > Roy Smith
>
>
>
>
> > As part of our initial interview screen, we give
> applicants some small
>
> > coding problems to do. One of the things we see a lot is what
> you could
>
> > call "Java code smell". This is our clue that the
> per
Τη Σάββατο, 13 Απριλίου 2013 4:41:57 π.μ. UTC+3, ο χρήστης Cameron Simpson
έγραψε:
> On 11Apr2013 09:55, Nikos wrote:
>
> | Τη Πέμπτη, 11 Απριλίου 2013 1:45:22 μ.μ. UTC+3, ο χρήστης Cameron Simpson
> έγραψε:
>
> | > On 10Apr2013 21:50, nagia.rets...@gmail.com
> wrote:
>
> | > | the doctype
On Sat, Apr 13, 2013 at 1:17 PM, Steven D'Aprano
wrote:
> On Sat, 13 Apr 2013 03:33:29 +0100, Nobody wrote:
>> If you want to wait for the data written to be written to the physical
>> disk (in order to obtain specific behaviour with respect to an unclean
>> shutdown), use f.flush() followed by os
On Sat, 13 Apr 2013 03:33:29 +0100, Nobody wrote:
> On Fri, 12 Apr 2013 00:06:21 +, Steven D'Aprano wrote:
>
>>> The close method is defined and flushing and closing a file, so it
>>> should not return until that's done.
>>
>> But note that "done" in this case means "the file system thinks i
On Sat, Apr 13, 2013 at 12:33 PM, Nobody wrote:
> But most of the time, there's no point. If you actually care about what
> happens in the event of an unclean shutdown, you typically also need to
> sync the directory, otherwise the file's contents will get sync'd but the
> file's very existence mi
On Fri, 12 Apr 2013 00:06:21 +, Steven D'Aprano wrote:
>> The close method is defined and flushing and closing a file, so it
>> should not return until that's done.
>
> But note that "done" in this case means "the file system thinks it is
> done", not *actually* done. Hard drives, especially
On Fri, 12 Apr 2013 23:26:05 +, Cousin Stanley wrote:
> The firefox browser keeps different sqlite database files for various
> uses
Yes, and I *really* wish they wouldn't. It's my number 1 cause of major
problems with Firefox. E.g.
http://kb.mozillazine.org/Bookmarks_history_and_t
On 11Apr2013 09:55, Nikos wrote:
| Τη Πέμπτη, 11 Απριλίου 2013 1:45:22 μ.μ. UTC+3, ο χρήστης Cameron Simpson
έγραψε:
| > On 10Apr2013 21:50, nagia.rets...@gmail.com wrote:
| > | the doctype is coming form the attempt of script metrites.py to open and
read the 'index.html' file.
| > | But i don'
On 04/13/2013 01:26 AM, Cousin Stanley wrote:
someone wrote:
So SQLite is very good for "practicing"
Yes it is but it is also very good
for much more than just practice
Check the wikipedia info
http://en.wikipedia.org/wiki/Sqlite
Very interesting...
someone wrote:
>
> So SQLite is very good for "practicing"
>
Yes it is but it is also very good
for much more than just practice
Check the wikipedia info
http://en.wikipedia.org/wiki/Sqlite
"It is arguably the most widely deployed database engine,
as
> I have a CSV file with 20 rows and 12 columns and I need to store it as a
> matrix.
If you can use pandas, the pandas.read_csv is what you want.
--
http://mail.python.org/mailman/listinfo/python-list
Keep the flattened data array others suggested, and then just split it like
this: *(replace `example_data`, `_array`, and `columns`)*
>>> example_data = range(15)
>>> split_array = lambda _array, colums: \
. . .[_array[i:i + colums] for i in \
. . .xrange(0, len(_array),
On 4/12/2013 4:46 PM, Piotr Dobrogost wrote:
Hi!
I'd like to bring your attention to the question titled "Use HTTP/1.1
with SimpleHTTPRequestHandler" at
http://stackoverflow.com/q/15839718/95735 which reads; "When I use
I find the doc slightly confusing. The SO code uses BaseHTTPServer. The
d
Neil Cerutti wrote:
> On 2013-04-12, Mark Janssen wrote:
> > Possibily, but don't accept this view of the legal system.
> > Judges can be quite reasonable. They don't want more time
> > taken for bullshit cases and would much prefer for things to be
> > settled (that is what their duty is -- to s
Jabba Laci
> Hi,
>
> I wonder if there is a nice way to extract a whole HTML table and have the
> result in a nice structured
> format. What I want is to have the lifetime table at the bottom of this page:
> http://en.wikipedia.org/wiki/List_of_Ubuntu_releases (then figure out with a
> script un
Steven D'Aprano wrote:
> try:
> main()
> except Exception as err:
> log(err)
> print("Sorry, an unexpected error has occurred.")
> print("Please contact support for assistance.")
> sys.exit(-1)
>
>
I like the traceback[0] module for logging last exception thrown.
See tracebac
On 04/12/2013 06:58 PM, Cousin Stanley wrote:
someone wrote:
As you can see, on my system I
had to use:
print row[0] , row[1]
instead of:
print row[ 'xtime' ] , row[ 'col4' ]
I'm not sure exactly why
The magic there is setting up the row_factory
after the database connection .
Hi!
I'd like to bring your attention to the question titled "Use HTTP/1.1 with
SimpleHTTPRequestHandler" at http://stackoverflow.com/q/15839718/95735 which
reads; "When I use HTTP/1.1 with SimpleHTTPRequestHandler, loading a page that
pulls in other resources will hang after the second resource
Τη Παρασκευή, 12 Απριλίου 2013 9:37:29 μ.μ. UTC+3, ο χρήστης Ian έγραψε:
> On Fri, Apr 12, 2013 at 8:36 AM, wrote:
>
> > Τη Παρασκευή, 12 Απριλίου 2013 4:29:51 μ.μ. UTC+3, ο χρήστης rusi έγραψε:
>
> >> On Apr 12, 6:18 pm, nagia.rets...@gmail.com wrote:
>
> >> > Well, instead of being a smartas
Mark Janssen wrote:
> >> It doesn't have to say so, if it's not charging any money -- there's no
> >> expectation that you're getting anything at all!
> >
> > Of course there is. If Oprah Winfrey stands up and publicly says that
> > she's giving you a car, FOR FREE, no strings attached, and then gi
On 2013-04-12, Mark Janssen wrote:
> Possibily, but don't accept this view of the legal system.
> Judges can be quite reasonable. They don't want more time
> taken for bullshit cases and would much prefer for things to be
> settled (that is what their duty is -- to settle matters, not
> to make l
On Fri, Apr 12, 2013 at 12:46 PM, Prasad, Ramit
wrote:
> Mark Janssen wrote:
>> But you see, there's the critical difference. First of all you're
>> making two errors in your comparison. Firstly, a *person* is saying
>> that she's going to *do something for you*. She's making a promise.
>> If I
In article ,
Ian Kelly wrote:
> I would also recommend that in the future you should stop deploying
> untested code to your production website. Set up a development
> environment for yourself, make the changes there, and only deploy when
> you know that everything is working.
But that takes al
On Fri, Apr 12, 2013 at 8:36 AM, wrote:
> Τη Παρασκευή, 12 Απριλίου 2013 4:29:51 μ.μ. UTC+3, ο χρήστης rusi έγραψε:
>> On Apr 12, 6:18 pm, nagia.rets...@gmail.com wrote:
>> > Well, instead of being a smartass it would be nice if you could actually
>> > help for once.
>>
>> Interesting!
>>
>> Amo
On 04/12/2013 01:29 PM, Ana Dionísio wrote:
That only puts the data in one column, I wanted to separate it.
For example:
data in csv file:
1 2 3 4 5
7 8 9 10 11
a b c d e
I wanted an array where I could pick an element in each position. In the case
above if I did print array[0][3] it would pi
On Apr 12, 10:12 pm, Ana Dionísio wrote:
> Hi, thanks for yor answer! ;)
>
> Anyone has more suggestions?
My suggestions:
1. Tell us what was lacking in Mark's suggestion (to use loadtxt)
2. Read his postscript (for googlegroup posters).
[In case you did not notice your posts are arriving in dou
That only puts the data in one column, I wanted to separate it.
For example:
data in csv file:
1 2 3 4 5
7 8 9 10 11
a b c d e
I wanted an array where I could pick an element in each position. In the case
above if I did print array[0][3] it would pick 4
--
http://mail.python.org/mailman/lis
- Original Message -
> Hello!
>
> I have a CSV file with 20 rows and 12 columns and I need to store it
> as a matrix. I already created an array with zeros, but I don't know
> how to fill it with the data from the csv file. I have this script:
>
> import numpy
> from numpy import array
>
Hi, thanks for yor answer! ;)
Anyone has more suggestions?
--
http://mail.python.org/mailman/listinfo/python-list
someone wrote:
> As you can see, on my system I
> had to use:
>
> print row[0] , row[1]
>
> instead of:
>
> print row[ 'xtime' ] , row[ 'col4' ]
>
> I'm not sure exactly why
The magic there is setting up the row_factory
after the database connection
dbc = DBM.connect( 'some.s
Roy Smith, 12.04.2013 17:33:
> Giampaolo Rodol� wrote:
>
>> Hi there folks,
>> I'm pleased to announce the 0.7.0 release of psutil:
>> http://code.google.com/p/psutil/
>
> I see a lot of these types of announcements. May I suggest that people
> add a short description of what that package is.
Steven D'Aprano於 2013年4月12日星期五UTC+8上午8時06分21秒寫道:
> On Thu, 11 Apr 2013 19:55:53 +, Neil Cerutti wrote:
>
>
>
> > On 2013-04-11, Rob Schneider wrote:
>
> >> Thanks. Yes, there is a close function call before the copy is
>
> >> launched. No other writes. Does Python wait for file close com
> Roy Smith
> As part of our initial interview screen, we give applicants some small
> coding problems to do. One of the things we see a lot is what you could
> call "Java code smell". This is our clue that the person is really a
> Java hacker at heart who just dabbles in Python but isn't
In article ,
Giampaolo Rodolà wrote:
> Hi there folks,
> I'm pleased to announce the 0.7.0 release of psutil:
> http://code.google.com/p/psutil/
I see a lot of these types of announcements. May I suggest that people
add a short description of what that package is. From the name, I can't
tel
On 12/04/2013 15:22, Ana Dionísio wrote:
Hello!
I have a CSV file with 20 rows and 12 columns and I need to store it as a
matrix. I already created an array with zeros, but I don't know how to fill it
with the data from the csv file. I have this script:
import numpy
from numpy import array
fr
In article ,
Rob Schneider wrote:
> f.close
Well, there's your problem. You're not calling close. You forgot the
()'s after the function name!
--
http://mail.python.org/mailman/listinfo/python-list
Hi there folks,
I'm pleased to announce the 0.7.0 release of psutil:
http://code.google.com/p/psutil/
This is mainly a bugfix release addressing a couple of high priority
issues on Linux and FreeBSD.
Complete list of bugfixes and enhancements is here:
https://psutil.googlecode.com/hg/HISTORY
===
On 4/12/2013 3:17 AM, Ulrich Eckhardt wrote:
Am 11.04.2013 10:19, schrieb Steven D'Aprano:
if sys.version >= '3':
Use sys.version_info >= (3,), otherwise your code breaks when upgrading
to Python 10 and greater. ;^)
The second question that came up was if there is a way to keep a
metaclass
In article <51674ffc$0$29977$c3e8da3$54964...@news.astraweb.com>,
Steven D'Aprano wrote:
> On Thu, 11 Apr 2013 19:55:53 +, Neil Cerutti wrote:
>
> > On 2013-04-11, Rob Schneider wrote:
> >> Thanks. Yes, there is a close function call before the copy is
> >> launched. No other writes. Does
In article ,
Cameron Simpson wrote:
> 45046 is exactly 11 * 4096. I'd say your I/O is using 4KB blocks,
> and the last partial block (to make it up to 47970) didn't get
> written (at the OS level).
Yeah, this sounds like a good diagnosis.
BTW, the dtruss command I recommended in my earlier pos
On 4/12/2013 3:32 AM, Chris Angelico wrote:
On Fri, Apr 12, 2013 at 4:25 PM, Rob Schneider wrote:
The close method is defined and flushing and closing a file, so
it should not return until that's done.
What command are you using to create the temp file?
re command to write the file:
f
In article ,
Rob Schneider wrote:
> Source (correct one) is 47,970 bytes. Target after copy of 45,056 bytes.
> I've tried changing what gets written to change the file size. It is usually
> this sort of difference.
>
> The file system is Mac OS Extended Journaled (default as out of the box).
Τη Παρασκευή, 12 Απριλίου 2013 4:29:51 μ.μ. UTC+3, ο χρήστης rusi έγραψε:
> On Apr 12, 6:18 pm, nagia.rets...@gmail.com wrote:
>
> > Τη Παρασκευή, 12 Απριλίου 2013 4:14:39 μ.μ. UTC+3, ο χρήστης Chris Angelico
> > έγραψε:
>
> >
>
> > > On Fri, Apr 12, 2013 at 10:50 PM, wrote:
>
> >
>
> > > >
On 04/12/2013 10:19 AM, Roy Smith wrote:
As part of our initial interview screen, we give applicants some small
coding problems to do. One of the things we see a lot is what you could
call "Java code smell". This is our clue that the person is really a
Java hacker at heart who just dabbles in P
Hello!
I have a CSV file with 20 rows and 12 columns and I need to store it as a
matrix. I already created an array with zeros, but I don't know how to fill it
with the data from the csv file. I have this script:
import numpy
from numpy import array
from array import *
import csv
input = open(
On 2013-04-11 20:44, Cousin Stanley wrote:
Cousin Stanley wrote:
The stand-alone sqlite interpreter can first be used
to create an empty database named some.sql3
and create a table named xdata in that data base
sqlite3 some.sql3 '.read xdata_create.sql'
This step can
In article <51678b94$0$29977$c3e8da3$54964...@news.astraweb.com>,
Steven D'Aprano wrote:
> - If you have a complicated interface, or data with complicated internal
> state, the best solution is to use a custom object with methods.
>
> - But if your interface is simple, and the data is simple,
On 2013-04-11 19:58, Cousin Stanley wrote:
someone wrote:
I want to put this table into an appropriate container
such that afterwards I want to:
1) Put the data into a mySql-table
You might consider using sqlite3 as a database manager
since it is "batteries included" with p
On 11.04.2013 22:16, Ian Kelly wrote:
On Thu, Apr 11, 2013 at 9:23 AM, Ethan Furman wrote:
On 04/11/2013 04:13 AM, Sven wrote:
Yes, I had the idea to add bluetooth too, removes the whole plugging and
unplugging spiel. I might start work on that,
and if anyone else wants to dive in and help, fe
On Apr 12, 6:18 pm, nagia.rets...@gmail.com wrote:
> Τη Παρασκευή, 12 Απριλίου 2013 4:14:39 μ.μ. UTC+3, ο χρήστης Chris Angelico
> έγραψε:
>
> > On Fri, Apr 12, 2013 at 10:50 PM, wrote:
>
> > > Someone HEELP ME!!
>
> >http://youtu.be/VxMYwjp8t0o
>
> > ChrisA
>
> Well, instead of
On Fri, Apr 12, 2013 at 11:18 PM, wrote:
> Τη Παρασκευή, 12 Απριλίου 2013 4:14:39 μ.μ. UTC+3, ο χρήστης Chris Angelico
> έγραψε:
>> On Fri, Apr 12, 2013 at 10:50 PM, wrote:
>>
>> > Someone HEELP ME!!
>>
>> http://youtu.be/VxMYwjp8t0o
>>
>> ChrisA
>
>
> Well, instead of being a
Τη Παρασκευή, 12 Απριλίου 2013 4:14:39 μ.μ. UTC+3, ο χρήστης Chris Angelico
έγραψε:
> On Fri, Apr 12, 2013 at 10:50 PM, wrote:
>
> > Someone HEELP ME!!
>
>
>
> http://youtu.be/VxMYwjp8t0o
>
>
>
> ChrisA
Well, instead of being a smartass it would be nice if you could actu
On Fri, Apr 12, 2013 at 10:50 PM, wrote:
> Someone HEELP ME!!
http://youtu.be/VxMYwjp8t0o
ChrisA
--
http://mail.python.org/mailman/listinfo/python-list
Someone HEELP ME!!
--
http://mail.python.org/mailman/listinfo/python-list
On 12/04/2013 13:07, Rob Schneider wrote:
On Friday, 12 April 2013 10:22:21 UTC+1, Chris Angelico wrote:
On Fri, Apr 12, 2013 at 7:18 PM, Rob Schneider wrote:
f.close
Yep, there's the problem! See my previous post for details. Change this to:
f.close()
and you should be sorted.
Chris
On Friday, 12 April 2013 10:22:21 UTC+1, Chris Angelico wrote:
> On Fri, Apr 12, 2013 at 7:18 PM, Rob Schneider wrote:
>
> > f.close
>
>
>
> Yep, there's the problem! See my previous post for details. Change this to:
>
>
>
> f.close()
>
>
>
> and you should be sorted.
>
>
>
> Chris
On 4/11/2013 9:57 PM, Mark Janssen wrote:
Okay peeps, I'm re-opening this thread, because despite being hijacked
by naysayers, the merit of the underlying idea I think still has not
been communicated or perceived adequately.
Mark, this proposal is out of place on a Python list, because it
propo
On Fri, Apr 12, 2013 at 6:16 AM, Ian Kelly wrote:
> On Thu, Apr 11, 2013 at 9:23 AM, Ethan Furman wrote:
> > On 04/11/2013 04:13 AM, Sven wrote:
> >>
> >> Yes, I had the idea to add bluetooth too, removes the whole plugging and
> >> unplugging spiel. I might start work on that,
> >> and if anyon
On 12/04/2013 02:57, Mark Janssen wrote:
[dross snipped]
A summary here http://pinterest.com/pin/464293042804330899/
--
If you're using GoogleCrap™ please read this
http://wiki.python.org/moin/GoogleGroupsPython.
Mark Lawrence
--
http://mail.python.org/mailman/listinfo/python-list
On Fri, Apr 12, 2013 at 7:18 PM, Rob Schneider wrote:
> f.close
Yep, there's the problem! See my previous post for details. Change this to:
f.close()
and you should be sorted.
ChrisA
--
http://mail.python.org/mailman/listinfo/python-list
On Friday, 12 April 2013 09:26:21 UTC+1, Cameron Simpson wrote:
>
> | > > Question: is the size of the incomplete file a round number? (Like
>
> | > > a multiple of a decent sized power of 2>)
>
> [...]
>
> | Source (correct one) is 47,970 bytes. Target after copy of 45,056
>
> | bytes. I've
On 11Apr2013 23:32, Rob Schneider wrote:
| > > Question: is the size of the incomplete file a round number? (Like
| > > a multiple of a decent sized power of 2>)
[...]
| Source (correct one) is 47,970 bytes. Target after copy of 45,056
| bytes. I've tried changing what gets written to change the
Am 11.04.2013 10:19, schrieb Steven D'Aprano:
if sys.version >= '3':
Use sys.version_info >= (3,), otherwise your code breaks when upgrading
to Python 10 and greater. ;^)
The second question that came up was if there is a way to keep a
metaclass defined inside the class or if the only way
In article <6eeabeb2-e6dd-49fc-bd64-8de539651...@googlegroups.com>,
Rob Schneider wrote:
> > The file system is Mac OS Extended Journaled (default as out of the box).
> It shows file size 45,056 on both source and target, which is the file size
> of the flawed target, and is not what Finder show
On Fri, Apr 12, 2013 at 4:25 PM, Rob Schneider wrote:
>
>> The close method is defined and flushing and closing a file, so
>>
>> it should not return until that's done.
>>
>>
>>
>> What command are you using to create the temp file?
>>
>>
>
> re command to write the file:
> f=open(fn,'w')
> ... th
On Thu, Apr 11, 2013 at 9:23 AM, Ethan Furman wrote:
> On 04/11/2013 04:13 AM, Sven wrote:
>>
>> Yes, I had the idea to add bluetooth too, removes the whole plugging and
>> unplugging spiel. I might start work on that,
>> and if anyone else wants to dive in and help, feel free. I will probably
>>
On Fri, Apr 12, 2013 at 11:57 AM, Mark Janssen
wrote:
> Further, I will admit that I am not deeply
> experienced in application or Internet programming
Would you listen to someone who is, by his own admission, not
experienced as a surgeon, and tries to tell you that your liver and
heart would be
69 matches
Mail list logo