import htmllib, formatter, urllib
class x(htmllib.HTMLParser):
inanchor = True # indicates whether we are inside anchor element
def dump(self, tag, attrs):
#print tag,
for a, v in attrs:
if a in ['a', 'src', 'href']:
print v,
print
#
Stefan Behnel wrote:
> Ethan Furman, 24.07.2013 20:31:
> > On 07/24/2013 10:23 AM, Stefan Behnel wrote:
> >> Peter Otten, 24.07.2013 08:23:
> >>> Ethan Furman wrote:
>
> So, my question boils down to: in Python 3 how is dict.keys() different
> from dict? What are the use cases?
> >
Terry Reedy wrote:
>
> On 7/24/2013 4:34 PM, Prasad, Ramit wrote:
>
> > I am still not clear on the advantage of views vs. iterators.
>
> A1: Views are iterables that can be iterated more than once. Therefore,
> they can be passed to a function that re-iterates its
Chris Angelico wrote:
> On Fri, Jul 26, 2013 at 5:07 AM, wrote:
> > Let start with a simple string \textemdash or \texttendash
> >
> sys.getsizeof('-')
> > 40
> sys.getsizeof('a')
> > 26
>
> Most of the cost is in those two apostrophes, look:
>
> >>> sys.getsizeof('a')
> 26
> >>> sys.
CTSB01 wrote:
> On Thursday, July 25, 2013 3:19:27 PM UTC-4, Dave Angel wrote:
> > On 07/25/2013 12:03 PM, CTSB01 wrote:
> >
> > > I have the following code that runs perfectly:
> >
> >
> > > def psi_j(x, j):
> >
> > >rtn = []
> >
> > >for n2 in range(0, len(x) * j - 2
Devyn Collier Johnson wrote:
> Thanks Matthew Lefavor! But specifically, why use "#!/usr/bin/env python3"
> instead of
> "#!/usr/bin/python3"?
>
> Mahalo,
>
> DCJ
I believe this will work on Windows for Python 3.3+ and also with virtualenv.
https://pypi.python.org/pypi/virtualenv
Virtualenv i
cerr wrote:
> Hi,
>
> Can I somehow use pickle.dump() to store a dictionary of lists to a file?
> I tried this:
>
> >>> import pickle
> >>> mylist = []
> >>> mydict = {}
> >>> mylist = '1','2'
> >>> mydict['3'] = mylist
> >>> fhg = open ("test", 'w')
> >>> pickle.dump(
;"
http://www.jython.org/docs/tutorial/interpreter.html?highlight=pythonstartup
Ramit
Ramit Prasad | JPMorgan Chase Investment Bank | Currencies Technology
712 Main Street | Houston, TX 77002
work phone: 713 - 216 - 5423
--
This email is confidential and subject to important disclaimers and
cond
y:
table_name( revision_number, file/config name, data, username, timestamp ).
Otherwise, if you want to track "environments" and not files:
table_name( revision_number, data, username, timestamp ).
Where revision number can be a sequence used to track / change
current configuration. I r
have better things to do than
implementing a dozen (or more) major libraries like lxml and xlwt
just to name a few.
For that matter, I do not think mysqldb is a built-in Python package.
:)
Ramit
Ramit Prasad | JPMorgan Chase Investment Bank | Currencies Technology
712 Main Street | Houston, TX
ect
> 2. after this, I typed like "cd .." but I/O is already closed so I
> can't do another things..
>
> Is there any good way?
Not much experience with subprocess, but from what I have read
on here shell=True is usually bad. If you are trying to use
Python as a s
while OS X will move a file to Trash quite happily
only tell me it cannot remove the file when I try to empty the Trash.
Ramit
Ramit Prasad | JPMorgan Chase Investment Bank | Currencies Technology
712 Main Street | Houston, TX 77002
work phone: 713 - 216 - 5423
--
This email is confidentia
t;> VERBOSE = True
>>> caller()
calling function with arg 1
I might be being OCD, but caller needs `global VERBOSE` for that to
work as you explain.
Ramit
Ramit Prasad | JPMorgan Chase Investment Bank | Currencies Technology
712 Main Street | Houston, TX 77002
work phone: 713 - 216 - 542
> > Please do NOT catch BaseException, since that is the wrong thing to do.
>
> I would agree if you had said "in production code".
>
> If you are investigating why a third-party function is stopping your
> interpreter, then catching BaseException may tell you that the code
> is raising the wrong
> >> Well "neat tricks" aside, I am of the firm belief that deleting files
> should
> >> never be possible whilst they are open.
> > This is one of the few instances I think Windows does something better
> > than OS X. Windows will check before you attempt to delete (i.e. move
> > to Recycling Bin)
> >> VERBOSE = True
> >>
> >> def function(arg):
> >> if VERBOSE:
> >>print("calling function with arg %r" % arg)
> >> process(arg)
> >>
> >> def caller():
> >> VERBOSE = False
> >> function(1)
> >>
> >> -
> >> Python semantics: fu
> > import unittest
> >
> > class TestWithRaises(unittest.TestCase):
> > def test_first(self):
> > assert False
> >
> > def test_second(self):
> > print("also called")
> > assert True
> >
> > if __name__ == '__main__':
> > unittest.main()
> >
> > in this ca
> On 17/07/2012 18:49, Prasad, Ramit wrote:
> >>> import unittest
> >>>
> >>> class TestWithRaises(unittest.TestCase):
> >>> def test_first(self):
> >>> assert False
> >>>
> >>>
> >>> ipatterns
> ('*.txt', '*.hdf', '*.pdf', '*.png')
> >>> igf = shutil.ignore_patterns(ipatterns)
> >>> ignorethis = igf(ddftopdir,os.listdir(ddftopdir))
>
> Traceback (most recent call last):
> File "", line 1, in
> ignorethis = igf(ddftopdir,os.listdir(ddftopdir))
> File "C:\Python27
> > I am making the assumption that you intend to collapse the directory
> > tree and store each file in the same directory, otherwise I can't think
> > of why you need to do this.
>
> Hi Simon, thanks for the reply. It's not quite this - what I am doing
> is creating a zip file with relative path
er2','persona2.3','pro1'),('per2','persona2.3','pro2'),('per2','persona2.3','pro3'),('per2','persona2.3','pro4'),('per2','persona2.3','pro5'),('per2&
> No offence to all the well meaning participants here, but this looks like
> trolling
I thought Ranting Rick had sole dominion over trolling?
Ramit
This email is confidential and subject to important disclaimers and
conditions including on offers for the purchase or sale of
securities, accura
> I work in financials and the majority of our apps are developed in C++
> and Java yet all the tools that startup, deploy and conduct rigorous
> unit testing are implemented in Python or Shell scripts that wrap
> Python scripts.
>
> Python definitely has its place in the enterprise however not so
> > However, personally, I am not interested in all the details (typically
> > found in "CHANGES.txt") but some (often implicit) information is
> > sufficient for me: something like "major API change", "minor bug
> > fixes". Thus, think carefully what you put on the overview page.
> I see your poi
> >> I would suggest you change the theme -- using Firefox 3.6 the page is
> >> very difficult to read.
> >
> > Thanks for the report. Do you mind if I ask why you are using such an
> > old version?
> > (It looks fine with Firefox 14.0.1)
>
>
> That version works for me -- I don't like upgrading
> > my code in Eclipse:
> >
> > dict.fromkeys(['China','America'])
> > print "dict is",dict
> >
> > output: dict is
> >
> > my code in Python Shell:
> >
> > dict.fromkeys(['China','America'])
> >
> > output:{'America': None, 'China': None}
> >
> > Output in Python Shell is what i wanna,but why not
> On 7/31/2012 11:49 PM, Mark Hammond wrote:
> > On 1/08/2012 10:48 AM, Damon Register wrote:
> >> 1. though I have looked in a few readme files, I don't see instructions for
> >> installing what I have just built using MSVC. Where can I find the
> >> instructions for installing after buil
> I'm in stuck record mode here, but one of the things I really enjoy
> about reading here is the way things do go off topic. IMHO makes for a
> far more interesting experience. YMMV.
+1
Ramit
This email is confidential and subject to important disclaimers and
conditions including on offers fo
> Also, please use the names correctly and consistently. The None object
> (yes, there is only one) is not the same as a none object. And there is
> no standard type called Nonetype.
To be fair, this is not very clear to a beginner.
>>> len(None) # Python 2.6
TypeError: object of type 'NoneTyp
> def func1():
>
> num1=10
>
> num2=20
>
> print "The Second Number is:",num2
>
> return
>
>
> def func2():
>
> func1()
> num3=num1+num2
>
> num4=num3+num1
>
> print "New Number One is:",num3
>
> print "New Number Two is:",num4
>
>
> > I also tend to blame M$ (Outlook and variants) for this tendency to
> > quote everything and top-post -- Outlook makes it almost impossible
> > to do a trim&interleave response style.
>
> I that Outlook & Co are guilty. That and the fact that few people even
> think about this.
Nonsense, I po
>Look you are the only person complaining about top-posting.
>GMail uses top-posting by default.
>I can't help it if you feel irritated by it.
He is most certainly not the only person to feel irritated nor
even the only person who has requested you not to top post.
He does happen to be the most
> I'll be using Google Groups (hopefully it won't top-post by default) to post
> stuff.
Thanks for not top-posting. Even if it is the default, it is
not difficult to change. :)
Ramit
This email is confidential and subject to important disclaimers and
conditions including on offers for the pu
Ulrich Eckhardt wrote:
> A good tool would reduce the effort and guide users, like e.g. giving
> them a hint if they leave the whole mail they're replying to as copy.
> Several corporate email solutions (like MS Outlook/Exchange) put very
> little emphasis on communication efficiency but only on ey
Willem Krayenhoff
Any idea why print isn't working here?
I tried restarting my Command prompt. Also, print doesn't work inside a class.
--
Best Wishes,
Bruce
C: 604-441-5791
My Availability
Just as a note, this is a usenet group that can be accessed via email; a good
po
tinn...@isbd.co.uk wrote:
> I want to print a series of list elements some of which may not exist,
> e.g. I have a line:-
>
> print day, fld[1], balance, fld[2]
>
> fld[2] doesn't always exist (fld is the result of a split) so the
> print fails when it isn't set.
>
> I know I could simply u
Dwight Hutto wrote:
> Why don' you just time it,eit lops through incrementing thmax input/
What? Without context I have no idea what this means.
Ramit
--
This email is confidential and subject to important disclaimers and
conditions including on offers for the purchase or sale of
securities,
Dwight Hutto wrote:
[snip]
> On Wed, Sep 12, 2012 at 3:37 AM, Mark Lawrence
> wrote:
[snip]
> Others would be able to see this for themselves but
> > you insist on sending email without context. Please don't do this.
>
> How are my emails without context? I'm referring the OP to the docs,
Ramchandra Apte wrote:
> On Wednesday, 12 September 2012 14:11:56 UTC+5:30, Ramchandra Apte wrote:
> > On Wednesday, 12 September 2012 14:04:56 UTC+5:30, alex23 wrote:
> > > On 12 Sep, 16:31, Mark Lawrence wrote:
> > > > Perhaps this will sway youhttp://docs.python.org/dev/whatsnew/3.3.html
> >
Dwight Hutto wrote:
> On Thu, Sep 13, 2012 at 5:17 PM, Mark Lawrence
> wrote:
> > On 13/09/2012 21:34, Joshua Landau wrote:
> >>
> >> On 13 September 2012 20:53, Mark Lawrence
> wrote:acci sequence
> >>
> >>> On 13/09/2012 19:39
Dwight Hutto wrote:
> Chris Angelico wrote:
> > honest. How do you feel? Interesting...
> >
> Um, I guess like an inconsiderate bandwidth hog, but from now on I'll
> trim more text.
>
> First it was too little, and now it's too much.
It is a fine line to walk and nobody does it perfectly all the
Dwight Hutto wrote:
> On Fri, Sep 14, 2012 at 4:20 AM, alex23 wrote:
> > On Sep 14, 6:04 pm, Dwight Hutto wrote:
> >> > Using foreign names derogatively is a common tactic of the racist.
> >>
> >> Not really. But nice spin on my pun to make me look bad.
> >
> > It actually *is* common behaviour o
Jean-Michel Pichavant wrote:
[snip]
> Ultimately, the goal is to have something like
>
> @timeout(2)
> def doAction1
>
> @timeout(4)
> def doAction2
[snip]
> Here's Steven example:
>
> # Untested!
> def timeout(t=15):
> # Decorator factory. Return a decorator to actually do the work.
>
Paul Rubin wrote:
> Rolando Cañer Roblejo writes:
> > Is it possible for me to put a limit in the amount of processor usage
> > (% CPU) that my current python script is using? Is there any module
> > useful for this task?
>
> One way is check your cpu usage once in a while, compare with elapsed
>
Hans Mulder wrote:
> On 22/09/12 23:57:52, ross.mars...@gmail.com wrote:
> > To capture the traceback, so to put it in a log, I use this
> >
> > import traceback
> >
> > def get_traceback(): # obtain and return the traceback
> > exc_type, exc_value, exc_traceback = sys.exc_info()
> > return
? G??ee? wrote:
> I shouldn't have asked about Joomla here, or even about Python embedding
> within Joomla cms. I was under the impression that the latter was relevant to
> ask here but it seems it isnt.
>
> My bad, let's just close this thread so i don't waste anyone's time.
Now when/if you
Tim Chase wrote:
> [snip] though I'm minorly miffed that
> enumerate()'s starting-offset wasn't back-ported into earlier 2.x
> versions and have had to code around it for 1-based indexing; either
> extra "+1"s or whip up my own simple enumerate() generator).
Starting offset is in Python 2.6, unle
Dennis Lee Bieber wrote:
> Sent: Sunday, September 23, 2012 11:53 AM
> To: python-list@python.org
> Subject: Re: Capitalization for variable that holds a class
>
> On Sun, 23 Sep 2012 16:48:38 +0100, Joshua Landau
> declaimed the following in
> gmane.comp.python.general:
>
> > Simple question:
>
Dwight Hutto wrote:
> > Ergo: 'enumerate()' is the correct suggestion over manually
> > maintaining your own index, despite it ostensibly being "more" code
> > due to its implementation.
>
> But, therefore, that doesn't mean that the coder can just USE a
> function, and not be able to design it th
Andriy Kornatskyy wrote:
> Try to see 'Hello World' benchmark as an answer to the question how effective
> is the framework inside...
>
> If computer X boots faster than Y, it means it is more effective in this
> particular area.
>
> If a sportsman runs a distance 1 second faster than other, he g
Terry Reedy wrote:
> On 9/25/2012 4:07 PM, Ian Kelly wrote:
> > On Tue, Sep 25, 2012 at 1:58 PM, Terry Reedy wrote:
> >> On 9/25/2012 11:03 AM, Chris Angelico wrote:
> >>> Instance attributes override (shadow) class attributes.
> >>
> >>
> >> except for (some? all?) special methods
> >
> > Those n
iMath wrote:
> Sent: Wednesday, September 26, 2012 2:39 AM
> To: python-list@python.org
> Subject: regular expression : the dollar sign ($) work with re.match() or
> re.search() ?
>
> I only know the dollar sign ($) will match a pattern from the
> end of a string,but which method does it work wi
Benjamin Jessup wrote:
> Hello all,
>
> What do people recommend for a file format for a python desktop
> application? Data is complex with 100s/1000s of class instances, which
> reference each other.
>
> Write the file with struct module? (Rebuild object pointers, safe,
> compact, portable, not
(A little quoting manipulation to make it easier to read with
appropriate context.)
> > On Wed, Oct 3, 2012 at 11:25 AM, Amirouche Boubekki
> > wrote:
> >
> 2012/10/3 Jonathan Hayward
> > > The chief benefit besides the searching, so far, is that you can use Py3k
> > > mixed with shell command
Chris Angelico wrote:
> Sent: Thursday, October 04, 2012 9:28 AM
> To: python-list@python.org
> Subject: Re: final question: logging to stdout and updating files
>
> On Fri, Oct 5, 2012 at 12:00 AM, Steven D'Aprano
> wrote:
> > That is *terrible* advice. But if you insist on following it, you can
Steven D'Aprano wrote:
> Sent: Thursday, October 04, 2012 7:22 PM
> To: python-list@python.org
> Subject: Re: notmm is dead!
>
> On Thu, 04 Oct 2012 14:10:46 -0400, Etienne Robillard wrote:
>
> > Dear list,
> >
> > Due to lack of energy and resources i'm really sad to announce the
> > removal of
Agon Hajdari wrote:
> Sent: Monday, October 08, 2012 3:12 PM
> To: python-list@python.org
> Subject: Re: Insert item before each element of a list
>
> On 10/08/2012 09:45 PM, Chris Kaynor wrote:
> > [('insertme', i) for i in x]
>
> This is not enough, you have to merge it afterwards.
Why do you
Agon Hajdari wrote:
> On 10/08/2012 11:15 PM, Prasad, Ramit wrote:
> > Agon Hajdari wrote:
> >>
> >> On 10/08/2012 09:45 PM, Chris Kaynor wrote:
> >>> [('insertme', i) for i in x]
> >>
> >> This is not enough, you have to merge it
Thomas Bach wrote:
> Hi there,
>
> On Sat, Oct 06, 2012 at 03:08:38PM +, Steven D'Aprano wrote:
> >
> > my_tuple = my_tuple[:4]
> > a,b,c,d = my_tuple if len(my_tuple) == 4 else (my_tuple + (None,)*4)[:4]
> >
>
> Are you sure this works as you expect? I just stumbled over the following:
>
>
Bob Martin wrote
> in 682592 20121008 232126 "Prasad, Ramit" wrote:
> >Thomas Bach wrote:=0D=0A> Hi there,=0D=0A> =0D=0A> On Sat, Oct 06, 2012 at =
> >03:08:38PM +, Steven D'Aprano wrote:=0D=0A> >=0D=0A> > my_tuple =3D my_=
> >tuple[:4
Chris Angelico wrote:
> On Fri, Oct 12, 2012 at 3:49 AM, Gisle Vanem wrote:
> > wrote in comp.lang.python
> >
> > (my ISP no longer updates this group. Last message is from 8. April.
> > Does the postings to the python mailing-list automatically get reposted to
> > comp.lang.python?)
>
> Yes, c.
Label(frame, width = 40, text='text', name = 'name')
widgets.append( label )
def configure(name_):
found = False
for w in widgets:
if w.name == name_: # No idea how to get name from Tk widget
found = True
break
if found:
#
Steven D'Aprano wrote:
> On Tue, 16 Oct 2012 09:27:48 -0700, rurpy wrote about trolls and dicks:
>
> > The best advise is to ignore such posts and encourage others to do the
> > same.
>
> If you ignore such posts, how will the poster know they are unacceptable?
>
> How should somebody distinguis
Daniel Fetchinson wrote:
> >> Hi folks,
> >>
> >> I'm using a stand alone window manager without gnome or kde or any
> >> other de. But I still would like to have a system tray or notification
> >> area and so far used stalonetray for this. Stalonetray is written in C
> >> and is a GTK application,
David Hutto wrote:
> On Wed, Oct 17, 2012 at 2:06 AM, Demian Brecht wrote:
> > * Your strength is not design. Using bevel and emboss (and a pattern here
> > and there) does not constitute good
> design.
>
> It's simplicity within a symbolism, and now that I need money for
> medical reasons, the
st in the developer communities). They often default to
80 characters, but handle various sizes. So that comparison is not quite
fair.
Ramit Prasad
This email is confidential and subject to important disclaimers and
conditions including on offers for the purchase or sale of
securities, ac
> ChrisA
> --
Home and end do not bother me much as I can usually use ctrl+a/ctrl+e
for the same purpose. I do wish I found a better way to page up/down.
Ramit Prasad
This email is confidential and subject to important disclaimers and
conditions including on offers for the purchase o
you write here is public and can be seen by anyone
with access to the Internet and a search engine. That includes prospective
clients/employers! I know there is an increasing trend for employers
to search the Internet to learn about potential employees. I do the
same before I hire a company fo
David Hutto wrote:
> On Wed, Oct 17, 2012 at 12:38 PM, Prasad, Ramit
> wrote:
> > David Hutto wrote:
> >> On Wed, Oct 17, 2012 at 2:06 AM, Demian Brecht
> >> wrote:
[snip]
>
> > The question is whose opinion matters. Yours? Mine? Others? Personally,
>
not
look like it was un-indented to be part of a different block.
if looks_like_it_might_be_spam(
some_longer_variables,
here_and_here, and_here_also):
logger.notice("might be spam")
move_to_spam_folder(some_longer_variables)
update_spam_statistics(here_
time. That includes the possibility
> of a subtraction as indicated above.
>
Why does pointer arithmetic work for dicts? I would think the position
of a value would be based on the hash of the key and thus "random" for
the context of this conversation.
Ramit Prasad
This email is
Ian Kelly wrote:
> Sent: Thursday, October 18, 2012 2:39 PM
> To: Python
> Subject: Re: len() on mutables vs. immutables
>
> On Thu, Oct 18, 2012 at 1:18 PM, Prasad, Ramit
> wrote:
> > Why does pointer arithmetic work for dicts? I would think the position
> > of
it separate from the OS X system Python. MacPorts will take
care of everything for you as long as you have Xcode installed.
`sudo ports install py27-pip`
Ramit Prasad
This email is confidential and subject to important disclaimers and
conditions including on offers for the purchase or sal
Emile van Sebille wrote:
> On 10/19/2012 10:08 AM, Pradipto Banerjee wrote:
> > Hi,
> >
> > I am trying to read a file into memory. The size of the file is around 1
> > GB. I have a 3GB memory PC and the Windows Task Manager shows 2.3 GB
> > available physical memory when I was trying to read the
ython 2.5+ I would do the following instead.
with open(filename) as f:
for line in f:
# do something with line
This will automatically close the file when it is done. I doubt
it will help with memory issues, but closing files after you
are done with them is a Good practice.
Ram
python takes up more memory than the size of the
> file itself.
Of course it will. Python has to keep its own code in memory and
load the file. Not to mention that the file is converted from data
into a Python object with its own overhead.
Ramit Prasad
This email is confidential and su
oft.com/en-us/library/cc754820.aspx
[2] http://fuzzytolerance.info/using-python-to-manage-windows-services/
Ramit Prasad
This email is confidential and subject to important disclaimers and
conditions including on offers for the purchase or sale of
securities, accuracy and completeness of inform
you just want to disable/enable the button while leaving it
visible maybe try setting the config state as shown here:
http://www.daniweb.com/software-development/python/threads/69669/tkinter-button-disable-#
.
Hope that helps,
Ramit Prasad
This email is confidential and subject to important di
Roy Smith wrote:
> Pet peeve of the day...
>
> Why do you have to write:
>
> global foo
> foo = 4
>
> when
>
> global foo = 4
>
> would have been so much easier?
To make it more annoying for people who use globals, duh. :)
Ramit Prasad
This email is c
t is always helpful to provide python version, operating system version, full
error message,
and input/expected output for the code. Now I can tell you are using Python 2.x
but
without having any clue what is in keywords1.txt it is impossible to figure out
what the problem might be. Other than us
ms to
> defeat much of the point for me. I may as well just set up the tables
> manually without the reflection, which is what I'll probably do.
>
> Maybe I just misunderstood what was meant in the SQLAlchemy docs here?:
>
> "but note that SA can also “import” whole
s the str version.
>>> class t(object):
... def __str__(self):
... return 'str'
... def __repr__(self):
... return 'repr'
...
>>> a = t()
>>> print [a]
[repr]
>>> print a
str
>>> print a.__class__.__base_
t; long time. Probably needed only by me in debugging mode, but anyway I
> can do the simple try/except then, thanks..
On the other hand, if you store state externally (pickle?) maybe
you can just restart at the last "check point". That way even if
the program dies you can recover on
> for num in range(0,range_of_seq):
>if num % 3 != 0:
>next_3_d_array.append(num)
>if num % 3 == 0:
>array_list.append(next_3_d_array)
>next_3_d_array = [ ]
>
Wow, that looks complicated. Why hardcode to
arg 2',
> "even args containing a ' are ok")
>
> For Windows, you'll have to modify this somehow.
>
The subprocess module suggests using pipes.quote for escaping.
>>> a
('program name', 'argu"ment 1', '$arg 2', &q
Replying to skyworld because I could not find the original message
from MRAB.
skyworld wrote:
> On Oct 27, 11:02 am, MRAB wrote:
> > On 2012-10-27 03:28, skyworld wrote:> Hi,
> >
> > > I'm new to python and I'm trying to porting some scripts from v0.96 to
> > > v2.0.1. A piece of code is like thi
Gary Herron wrote:
> On 10/29/2012 04:13 PM, noydb wrote:
> > All,
> >
> > I need help with a date and time comparison.
> >
> > Say a user enters a date-n-time and a file on disk. I want to compare the
> > date and time of the file to the
> entered date-n-time; if the file is newer than the enter
Grant Edwards wrote:
> On 2012-11-05, Roy Smith wrote:
> > In article ,
> > Chris Angelico wrote:
> >
> >> It's nothing to do with operating system. File names are names, and
> >> spaces in them are seldom worth the hassle unless you manipulate those
> >> files solely using a GUI.
> >
> > That's
Steven D'Aprano wrote:
>
> On Mon, 05 Nov 2012 14:47:47 -0500, Dennis Lee Bieber wrote:
>
[snip]
>
> Nevertheless, I do tend to prefer underscores to spaces, simply because I
> often use naive tools that treat spaces as separators. That is, command
> line shells.
I visually prefer spaces but it
Ian Kelly wrote:
>
> On Tue, Nov 6, 2012 at 1:21 AM, Andrew Robinson
>
[snip]
> > See if you can find *any* python program where people desired the
> > multiplication to have the die effect that changing an object in one of the
> > sub lists -- changes all the objects in the other sub lists.
> >
Dennis Lee Bieber wrote:
>
> On Tue, 06 Nov 2012 13:26:11 +0100, Peter Otten <__pete...@web.de>
> declaimed the following in gmane.comp.python.general:
>
> > anuradha.raghupathy2...@gmail.com wrote:
[snip]
> > > def main():
> > >logging.basicConfig(Filename='c://myapp.log', level=logging.ERRO
Levi Nie wrote:
>
> Who can give me some practical tutorials on django 1.4 or 1.5?
> Thank you.
Maybe this will help: http://gettingstartedwithdjango.com/resources/
~Ramit
This email is confidential and subject to important disclaimers and
conditions including on offers for the purchase or sa
Steven D'Aprano wrote:
>
> On Tue, 06 Nov 2012 17:16:44 +0000, Prasad, Ramit wrote:
>
> >> To enter the newline, I typed Ctrl-Q to tell bash to treat the next
> >> character as a literal, and then typed Ctrl-J to get a newline.
> >
> > That sounds
Andrew Robinson wrote:
>
> On 11/06/2012 01:04 AM, Steven D'Aprano wrote:
> > On Mon, 05 Nov 2012 21:51:24 -0800, Andrew Robinson wrote:
> >
[snip]
> > Q: What about other mutable objects like sets or dicts?
> > A: No, the elements are never copied.
> They aren't list multiplication comp
iMath wrote:
> how to get a list of names of everything in the current directory ?
http://lmgtfy.com/?q=python+get+files+in+directory
~Ramit
This email is confidential and subject to important disclaimers and
conditions including on offers for the purchase or sale of
securities, accuracy and
Gregory Ewing wrote:
>
> Roy Smith wrote:
> > Call by social network? The called function likes the object.
> > Depending on how it feels, it can also comment on some of the object's
> > attributes.
>
> And then finds that it has inadvertently shared all its
> private data with other functions a
Anders wrote:
>
> I've run into a Unicode error, and despite doing some googling, I
> can't figure out the right way to fix it. I have a Python 2.6 script
> that reads my Outlook 2010 task list. I'm able to read the tasks from
> Outlook and store them as a list of objects without a hitch. But whe
wxjmfa...@gmail.com wrote:
>
> Le jeudi 8 novembre 2012 19:49:24 UTC+1, Ian a écrit :
> > On Thu, Nov 8, 2012 at 11:32 AM, Oscar Benjamin
> >
> > wrote:
> >
> > > If I want the other characters to work I need to change the code page:
> > >
> > > O:\>chcp 65001
> > > Active code page: 65001
> > >
Graham Fielding wrote:
>
> Hey, folks, me again!
>
> I've been puzzling over this for a while now:
>
> I'm trying to write data to a file to save the state of my game using the
> following function:
>
> def save_game():
> #open a new empty shelve (possibly overwriting an old one) to write
Andriy Kornatskyy wrote:
>
> Thank you for all comments.
>
> > It makes very good sense to say:
> >
> > duckmatch(IFoo).compare(Foo)
>
> Since we do duck match of IFoo... but there is no `duck match`, there is
> `duck test`. I believe instead of
> `compare` is more readable with `equals`. Than
1 - 100 of 330 matches
Mail list logo