Mike Meyer wrote:
> "Mike Schilling" <[EMAIL PROTECTED]> writes:
>> Another advantage is that evewry internet-enabled computer today already
>> comes with an HTML renderer (AKA browser)
>
> No, they don't. Minimalist Unix distributions don't include a browser
> by default. I know the BSD's don't,
John Bokma wrote:
> [EMAIL PROTECTED] wrote:
>
>> In comp.lang.perl.misc John Bokma <[EMAIL PROTECTED]> wrote:
>
> [ web based boards ]
>
>>> And which useful tools do you require?
>>>
>> A choice of news readers to suit different people with different
>> interfaces,
>
> - different browsers, d
John Bokma wrote:
> Ulrich Hobelmann <[EMAIL PROTECTED]> wrote:
>
>> What I hate about most are the sites that don't even *mention* that
>> they want cookies. Often I have to wonder, reinput input fields etc.
>> and then after ten minutes trying *bang*, the
John Bokma wrote:
>> I have cookies off, with explicit exception for sites where
>> I want cookies. When the crappy website doesn't bother to MENTION that
>> it wants cookies, i.e. give me an error page, how am I to know that it
>> needs cookies? Do I want EVERY website to ask me "do you allow
John Bokma wrote:
[cookies]
> Delete them after each session automatically, except the ones on the
> exception list.
But why? I simply don't even take them, except my exception list ;)
Some people have all cookies turned off.
> You are clearly not an average user, so your usage pattern
> prob
Mike Meyer wrote:
>> This can be designed much better by using iframes, maybe even Ajax.
>
> Definitely with Ajax. That's one of the things it does really well.
But then you're probably limited to the big 4 of browsers: MSIE,
Mozilla, KHTML/Safari, Opera. Ok, that should cover most desktop user
Mike Meyer wrote:
> Try turning off JavaScript (I assume you don't because you didn't
> complain about it). Most of the sites on the web that use it don't
> even use the NOSCRIPT tag to notify you that you have to turn the
> things on - much less use it to do something useful.
I had JS off for a l
Mike Meyer wrote:
>> I'd rather develop a native client for the machine that people
>> actually WANT to use, instead of forcing them to use that
>> little-fiddly web browser on a teeny tiny display.
>
> You missed the point: How are you going to provide native clients for
> platforms you've never
Mike Meyer wrote:
> I'm still waiting for an answer to that one - where's the Java toolkit
> that handles full-featured GUIs as well as character cell
> interfaces. Without that, you aren't doing the job that the web
> technologies do.
Where is the text-mode browser that would even run part of the
Mike Meyer wrote:
> If your web apps are well-written, any of them should work. As
> previously stated, Sturgeon's law applies to the web, so chances are
> good they aren't well-written.
:)
>> But as soon as some user of platform 54 tries your website, she'll
>> encounter some weird behavior with
on of remote procedure call via HTTP
sockets).
It's built-in in Python since 2.2
(http://www.python.org/doc/2.4/lib/module-xmlrpclib.html),
in Java use e.g. Apache XML-RPC (http://ws.apache.org/xmlrpc/).
Ulrich
--
http://mail.python.org/mailman/listinfo/python-list
Torsten Bronger wrote:
HallÃchen!
Tach!
Moreover, I dislike the fact that new features are implemented
partly in the interpreter and partly in Python itself. It reminds
me of TeX/LaTeX, where the enormous flexibility of TeX is used to
let it change itself in order to become a LaTeX compiler. Howe
[EMAIL PROTECTED] wrote:
The Python doc, though relatively incompetent, but the author have
Really, how could those morons even dream of creating a language,
and even writing docs to accompany it??
tried the best. This is in contrast to documentations in unix related
things (unix tools, perl, apa
alex goldman wrote:
Daniel Silva wrote:
At any rate, FOLD must fold.
I personally think GOTO was unduly criticized by Dijkstra. With the benefit
of hindsight, we can see that giving up GOTO in favor of other primitives
failed to solve the decades-old software crisis.
The fault of goto in imperati
pagesize (labelsize) and a minimum format
(boldface). But may be there is another light-weight-format besides PDF?
Any idea?
Ulrich
--
Ulrich Goebel
Paracelsusstr. 120, 53177 Bonn
--
https://mail.python.org/mailman/listinfo/python-list
Many thanks for the moment. I will try reportlab the next days.
Am 09.03.2014 22:29, schrieb Ulrich Goebel:
Hallo,
has anybody an idea how to make small formated documents redy to print
with python?
I would like to print address labels as
firstname lastname
street and number
cip
Am 01.08.2013 18:02, schrieb cool1...@gmail.com:
I know I should be testing out the script myself but I did, I tried
and since I am new in python and I work for a security firm that ask
me to scan hundreds of documents a day for unsafe links (by opening
them) I thought writing a script will be mu
Am 02.08.2013 12:54, schrieb matt.doolittl...@gmail.com:
I am using 2.7 on Ubuntu 12.10. All I need to do is to print time with the
microseconds.[...]
# write date and time and microseocnds
self.logfile.write('%s\t'%(str(strftime("%Y-%m-%d",
self.logfile.write(
Am 02.08.2013 15:17, schrieb matt.doolittl...@gmail.com:
so you are saying that
self.logfile.write('%s\t'%(str(time(
should be:
self.logfile.write('%s\t'%(str(time.time(
No, I'm not saying that. What I wanted to make clear is that your code
is impossible to understand as it
Am 05.08.2013 21:38, schrieb Olive:
I have found telnetlib which make very easy to interact with a telnet
server, especially the read_until command. I wonder if something
similar exits for other things that a telnet server.
It's not Python and I haven't played with it extensively, but there is
Am 21.08.2013 08:50, schrieb chandan kumar:
class Test(threading.Thread):
def StartThread(self):
Lock = threading.Lock()
self.start()
Inconsistently indented code, this is a killer for Python. Please read
PEP8 and use four spaces! That said, there is never a need for de
Am 21.08.2013 20:58, schrieb Johannes Bauer:
On 21.08.2013 11:11, Ulrich Eckhardt wrote:
That said, there is never a need for deriving
from the Thread class, you can also use it to run a function without
that. That way is IMHO clearer because the threading.Thread instance is
not the thread
Am 23.08.2013 05:28, schrieb Steven D'Aprano:
On Thu, 22 Aug 2013 13:54:14 +0200, Ulrich Eckhardt wrote:
When the Python object goes away, it doesn't necessarily affect
thethread or file it represents.
>
That's certainly not true with file objects. When the file object goes
Am 28.08.2013 13:55, schrieb Ferrous Cranus:
Τη Τετάρτη, 28 Αυγούστου 2013 2:32:44 μ.μ. UTC+3, ο χρήστης Dave Angel έγραψε:
You really have no directory in which you have write permissions? If
so, perhaps you'd better solve that first.
of cours ei ahve write permissions. Here:
ni...@superh
return r
def compare (a, b):
aa = normal(a)
bb = normal(b)
if aa < bb:
return -1
elif aa == bb:
return 0
else:
return 1
That works, but my be there is a more intelligent way? Especially there
could be much more r.replace to handle all the accents as ^ ° ´ ` and so on.
idecode does - and what it doesn't.
There is also a rather long-ish recent topic on a similar topic that
might be worth scanning as well.
Sorry, I didn't find that.
I've no direct/recent experience with this topic. I'm just an
interested bystander.
But even a helpful bys
ward, two steps
forward).
Any help will be wellcome!
Ulrich
--
Ulrich Goebel
Paracelsusstr. 120, 53177 Bonn
--
https://mail.python.org/mailman/listinfo/python-list
Hi
Am 31.10.2013 23:35, schrieb Terry Reedy:
On 10/31/2013 5:29 PM, Ulrich Goebel wrote:
I'm locking for an "iterator" type with not only the .next() method, but
with a .previous(), .first() and .last() method, so that I can through
it from the beginning or from the e
e byte 0xc3 in position 6:
ordinal not in range(128)
The "position 6" is exactly the position of the special character, ß in
this case.
What to do?
Ulrich
--
Ulrich Goebel
Paracelsusstr. 120, 53177 Bonn
--
https://mail.python.org/mailman/listinfo/python-list
Hi!
I'm trying to provide some scripting capabilities to a program. For that,
I'm embedding a Python interpreter, running a script in a separate thread to
decouple it from the UI.
Now, how should I handle rogue scripts? For example, when a script hangs in
an endless loop, how do I signal the P
Steven D'Aprano wrote:
> Ulrich Eckhardt wrote:
>> I'm trying to provide some scripting capabilities to a program. For that,
>> I'm embedding a Python interpreter, running a script in a separate thread
>> to decouple it from the UI.
>>
>> Now, how
Chris Angelico wrote:
> You can use PyErr_SetInterrupt to raise KeyboardInterrupt
This sounds useful. Just to make sure, this would be called from a different
thread than the one running the Python script, is that still OK?
> , but it can be caught by the script. There's no guaranteed way,
> sho
superhappyfuntime wrote:
> #this is antiWYSIWYG, an easy to learn cap for begginners to LaTeX.
It's LaTeX, not Python.
Uli
--
http://mail.python.org/mailman/listinfo/python-list
Am 05.10.2011 15:33, schrieb faucheuse:
I was wondering something :
when you do : return value1, value2, value3
It returns a tuple.
Right.
So if I want to pass these value to a function, the function have to
look like :
def function(self,(value1, value2, value3))
[...]
No, you don't have to
Am 06.10.2011 05:40, schrieb Steven D'Aprano:
(4) Do all your processing in Unicode, not bytes.
(5) Encode the text into bytes using UTF-8 encoding.
(6) Write the bytes to a file.
Just wondering, why do you split the latter two parts? I would have used
codecs.open() to open the file and defi
Am 10.10.2011 14:18, schrieb X1:
has this bug been resolved?
if yes, which version on files to install?
That seems to be part of PyOpenGL, so I'd check their bugtracking system.
Uli
--
http://mail.python.org/mailman/listinfo/python-list
Am 16.10.2011 10:03, schrieb masood shaik:
I am trying to call python function from c code.The following
program i got from the web source while i am trying to run this
program it throws an segmentation fault.
Try checking what functions returns instead of blindly using it.
Use a debugger to fi
Am 23.10.2011 14:41, schrieb Stefan Behnel:
That's just fine. If you are interested in the inner mechanics of the
CPython runtime, reading the source is a very good way to start getting
involved with the project.
However, many extension module authors don't care about these inner
mechanics and j
Am 01.11.2011 16:05, schrieb Gnarlodious:
I want to assign a list of variables:
locus=[-2, 21, -10, 2, 12, -11, 0, 3]
updating a list of objects each value to its respective instance:
for order in range(len(Orders)):
Orders[order].locus=locus[order]
This works, even though it reads lik
Am 03.11.2011 11:07, schrieb Martin Landa:
in my python application I am calling functions from a C library via
`ctypes` interface. Some fns from that C library calls `exit()` on
error.
Just curious, which library is that?
Uli
--
http://mail.python.org/mailman/listinfo/python-list
Am 04.11.2011 01:33, schrieb Anthony Kong:
I would like to find out what is the current prevailing view or
consensus (if any) on the use of Design Pattern in python?
My consensus with myself is that design patterns are language-agnostic.
If I write "class Foo serves as view and controller for
Hi!
I'm currently trying to establish a few tests here that evaluate certain
performance characteristics of our systems. As part of this, I found
that these tests are rather similar to unit-tests, only that they are
much more fuzzy and obviously dependent on the systems involved, CPU
load, ne
Am 16.11.2011 15:36, schrieb Roy Smith:
It's really, really, really hard to either control for, or accurately
measure, things like CPU or network load. There's so much stuff you
can't even begin to see. The state of your main memory cache. Disk
fragmentation. What I/O is happening directly ou
Am 18.11.2011 08:51, schrieb Pekka Kytölä:
Is it possible to pass my own dll's (already loaded) handle as an
argument to load/attach to the very same instance of dll? Thing is
that I've done plugin (dll) to a host app and the SDK's function
pointers are assigned once the dll is loaded in the host
Am 18.11.2011 12:49, schrieb Pekka Kytölä:
What I'd like to do is that after fetching those SDK function
pointers I'd like to fire up .py/.pyc that snoops for possible
plugins written in python and registers those plugins and callbacks
and let them react to events. Obviously this python code need
Hi!
I have a few tests that require a network connection. Typically, the
target will be localhost on port 2. However, sometimes these
settings differ, so I want to be able to optionally set them.
What I'm currently doing is this:
try:
from settings import REMOTE_HOST, REMOTE_
Am 17.11.2011 00:59, schrieb Ben Finney:
David Robinow writes:
but your code works fine on Windows. Thanks.
I'm glad to know that. Perhaps you could investigate why, and suggest an
update to the above documentation if it's wrong? The bug tracker at
http://bugs.python.org/> would be the appro
Am 25.11.2011 04:49, schrieb alex23:
On Nov 24, 6:51 pm, Tim Golden wrote:
The Ctrl-Z thing is what *exits* the interpreter on Windows
(a la Ctrl-D on Linux).
With ActivePython, Ctrl-D works as well, which is a godsend as I'm
constantly working across Windows& linux.
In short - on Windows,
Am 29.11.2011 08:34, schrieb Mrinalini Kulkarni:
I need to run .pyc files using python c api. if i do PyImport_Import it
executes the script. However, i need to pass a set of variables and
their values which will be accessed from within the script. How can this
be done.
I don't think what you w
Am 08.12.2011 23:41, schrieb Frank van den Boom:
arglist = [PATH_TO_7ZIP,"a", "-sfx", archive_name, "*", "-r",
"-p",PASSWORD]
The "*" is resolved by the shell, this is not a wildcard that gets
passed to the program. At least not normally, your case might be different.
if output:
print o
Am 15.12.2011 12:12, schrieb yeet:
My LCD has 2ms respond time thus it can handle a maximum of 50Hz ON/
OFF (white/black) thus seems to fit my 1-40Hz range.
You might want to ask Santa for a new calculator, as in my book a
response time of 2ms would be enough for 250Hz (period = 2 * 2ms).
Re
Hi!
I'm trying to create a struct_time that is e.g. one year ahead or a
month back in order to test some parsing/formatting code with different
dates.
Now, the straightforward approach is
t = time.localtime()
t.tm_year += 1
This fails with "TypeError: readonly attribute". This kind-of m
Am 16.12.2011 10:45, schrieb Ulrich Eckhardt:
I'm trying to create a struct_time that is e.g. one year ahead or a
month back in order to test some parsing/formatting code with different
dates.
There is something I stumbled across that helps and that is the datetime
module, which seems
Am 16.12.2011 18:48, schrieb Nathan Rice:
I realize this has been discussed in the past, I hope that I am
presenting a slightly different take on the subject that will prove
interesting. This is primarily motivated by my annoyance with using
comprehensions in certain circumstances.
[...]
Havin
Hi!
I'd like to give my users a meaningful error message when they are using
obsolete Python versions. Is there some kind of best practice or recipe
for that? Specifically, the case is a bunch of unittests that use
features new to Python 2.7.
Thank you!
Uli
--
http://mail.python.org/mailman
Hi!
Let us assume I had a class HTTPClient that has a socket for HTTP and a
logfile for filing logs. I want to make this HTTPClient a context
manager, so that I can write
with HTTPClient(url) as client:
pass
and reliably have both the socket and the logfile closed. The easy way
is w
Am 20.12.2011 15:15, schrieb Ulrich Eckhardt:
Let us assume I had a class HTTPClient that has a socket for HTTP and a
logfile for filing logs. I want to make this HTTPClient a context
manager, so that I can write
with HTTPClient(url) as client:
pass
Actually, I overestimated the task
Am 05.01.2012 09:05, schrieb ru...@yahoo.com:
I have optparse code that parses a command line containing
intermixed positional and optional arguments, where the optional
arguments set the context for the following positional arguments.
For example,
myprogram.py arg1 -c33 arg2 arg3 -c44 arg4
Hi!
The topic explains pretty much what I'm trying to do under Python
2.7[1]. The reason for this is that I want dir(SomeType) to show the
attributes in the order of their declaration. This in turn should
hopefully make unittest execute my tests in the order of their
declaration[2], so that t
Am 06.01.2012 12:44, schrieb Peter Otten:
Alternatively you can write your own test loader:
[...CODE...]
Well, actually you just did that for me and it works! ;)
Nonetheless, I'm still wondering if I could somehow replace the dict
with an OrderedDict.
Thank you!
Uli
--
http://mail.python.
Am 06.01.2012 12:43, schrieb Lie Ryan:
On 01/06/2012 08:48 PM, Ulrich Eckhardt wrote:
Hi!
The topic explains pretty much what I'm trying to do under Python
2.7[1]. The reason for this is that I want dir(SomeType) to show the
attributes in the order of their declaration. This in turn s
Am 09.01.2012 13:10, schrieb Lie Ryan:
I was just suggesting that what the OP thinks he wants is quite
likely not what he actually wants.
Rest assured that the OP has a rather good idea of what he wants and
why, the latter being something you don't know, because he never
bothered to explain
Am 09.01.2012 15:35, schrieb Roy Smith:
The classic unittest philosophy says that tests should be independent of
each other, which means they should be able to be run in arbitrary
order. Some people advocate that the test framework should
intentionally randomize the order, to flush out inter-tes
Am 10.01.2012 13:31, schrieb Lie Ryan:
While it is possible to replace __dict__ with OrderedDict and it is
possible to reorder the test, those are not his original problem, and
the optimal solution to his original problem differs from the optimal
solution to what he think he will need.
Oh, and
Am 06.01.2012 12:44, schrieb Peter Otten:
[running unit tests in the order of their definition]
class Loader(unittest.TestLoader):
def getTestCaseNames(self, testCaseClass):
"""Return a sequence of method names found within testCaseClass
sorted by co_firstlineno.
"
Am 19.01.2012 21:45, schrieb Jabba Laci:
In a unit test, I want to verify that a function returns a
cookielib.LWPCookieJar object. What is the correct way of doing that?
1) First I tried to figure out its type with type(return_value) but it
is
I'm not sure where the problem here is and where e
Am 04.02.2013 18:12, schrieb Jabba Laci:
autoflush_on = False
def unbuffered():
"""Switch autoflush on."""
global autoflush_on
# reopen stdout file descriptor with write mode
# and 0 as the buffer size (unbuffered)
if not autoflush_on:
sys.stdout = os.fdopen(sys
Am 05.02.2013 05:14, schrieb Anthony Correia:
I need to pick up a language that would cover the Linux platform. I use
Powershell for a scripting language on the Windows side of things. Very simple
copy files script. Is this the best way to do it?
import os
objdir = ("C:\\temp2")
Dro
Am 05.02.2013 01:09, schrieb Jabba Laci:
I like the context manager idea
There is a helper library for constructing context managers, see
http://docs.python.org/2/library/contextlib.html. That would have made
your code even shorter.
setting the sys.stdout back to the original value doesn
Am 05.02.2013 11:35, schrieb Peter Otten:
Ulrich Eckhardt wrote:
[...] use os.path.walk(), because that doesn't first build a list and
then iterate over the list but iterates over the single elements directly.
[...]
Not true. os.walk() uses os.listdir() internally.
Oh. 8|
Thank
Hello Pythonistas!
Below you will find example code distilled from a set of unit tests,
usable with Python 2 or 3. I'm using a loop over a list of parameters to
generate tests with different permutations of parameters. Instead of
calling util() with values 0-4 as I would expect, each call uses
Dave and Terry,
Thanks you both for your explanations! I really appreciate the time you
took.
Am 05.02.2013 19:07, schrieb Dave Angel:
If you need to have separate function objects that already know a
value for i, you need to somehow bind the value into the function object.
One way to do it,
Heureka!
Am 06.02.2013 15:37, schrieb Dave Angel:
> def myfunc2(i):
def myfunc2b():
print ("myfunc2 is using", i)
return myfunc2b
Earlier you wrote:
There is only one instance of i, so it's not clear what you expect.
Since it's not an argument to test(), it has to be found
Am 08.02.2013 07:29, schrieb Chris Angelico:
On Fri, Feb 8, 2013 at 3:32 PM, iMath wrote:
which situations should we use thread. join() ?
http://bpaste.net/show/yBDGfrlU7BDDpvEZEHmo/
why do we not put thread. join() in this code ?
I've no idea why you don't put thread.join() in that code. M
Am 08.02.2013 14:03, schrieb gmspro:
One said, Python is not programming language, rather scripting language, is
that true?
That depends on your definition of scripting language and programming
language.
Python's not a language but an animal.
Uli
--
http://mail.python.org/mailman/listinfo
Am 13.02.2013 um 17:14 schrieb Rick Johnson:
Q1: How could a line in the "try" block ever be considered
offensive? Because it throws an error?
try:
rrick.go_and_fuck_yourself()
finally:
rrick.get_lost()
See, wasn't that difficult, was it? :D
Are you serious?
No, I just coul
Am 15.02.2013 08:51, schrieb Rick Johnson:
"How could a line in the "try" block ever be considered offensive?"
My suggestion of "offensive" does not imply ignorance on /my/ part[...]
Well, it seems to imply that you are not aware of the subtle difference
between "offending" and "offensive".
Am 01.03.2013 09:59, schrieb Isaac Won:
try to make my triple nested loop working. My code would be:
c = 4
[...]
while c <24:
c = c + 1
This is bad style and you shouldn't do that in python. The question that
comes up for me is whether something else is modifying "c" in that loop,
Am 01.03.2013 17:28, schrieb Isaac Won:
What I really want to get from this code is m1 as I told. For this
purpose, for instance, values of fpsd upto second loop and that from
third loop should be same, but they are not. Actually it is my main
question.
You are not helping yourself...
In any
Am 27.03.2013 06:44, schrieb Eric Parry:
I downloaded the following program from somewhere using a link from
Wikipedia and inserted the “most difficult Sudoku puzzle ever” string
into it and ran it. It worked fine and solved the puzzle in about 4
seconds. However I cannot understand how it works.
Hi!
I'm having problems using a metaclass to generate test functions. This
works when I try to run all tests from the module or test case, but it
fails when I'm trying to specify a single test function. My environment
is Python 2.7.3 on MS Windows 7 at the moment. It should be upgraded to
at
Am 10.04.2013 11:52, schrieb Peter Otten:
Ulrich Eckhardt wrote:
[...]
It looks like this particular invocation relies on class attribute and
function __name__ being identical.
Please file a bug report.
Thanks for confirming this and reducing the test case even more.
Now, concerning
Am 10.04.2013 11:52, schrieb Peter Otten:
It looks like this particular invocation relies on class attribute and
function __name__ being identical.
Please file a bug report.
http://bugs.python.org/issue17696
Uli
--
http://mail.python.org/mailman/listinfo/python-list
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
Am 23.04.2013 06:00, schrieb Steven D'Aprano:
If it comes down to micro-optimizations to shave a few microseconds off,
consider using string % formatting rather than the format method.
Why? I don't see any obvious difference between the two...
Greetings!
Uli
--
http://mail.python.org/mailma
Am 23.04.2013 09:13, schrieb inshu chauhan:
This statement is giving me the following error
Statement:
for p, k, j in zip(sorted(segments.iterkeys(), class_count.iterkeys(),
pixel_count.iterkeys())):
Error:
Traceback (most recent call last):
File "C:\Users\inshu\Desktop\Training_segs_trial2.
Am 23.04.2013 10:26, schrieb Chris “Kwpolska” Warrick:
On Tue, Apr 23, 2013 at 9:46 AM, Ulrich Eckhardt
wrote:
Am 23.04.2013 06:00, schrieb Steven D'Aprano:
If it comes down to micro-optimizations to shave a few microseconds off,
consider using string % formatting rather than the f
Martin P. Hellwig wrote:
> Xah Lee wrote:
>
> Nice rant, btw in most EU countries the software creator can not
> withdraw the responsibility of his/her/it creation, regardless of what
> the disclaimer says. The law is the leading authority and not some
> Disclaimer/EULA, that's why most US EULA
Xah Lee wrote:
> • The reason fucking languages like C and family mask technically
Contrary to popular opinion, languages don't multiply. Certainly they
don't have sex. Most (human) languages merely have something called
gender, and words don't interact. C has a bastard child called C++,
tru
Xah Lee wrote:
> here's a site: http://www.longbets.org/bets that takes socially
> important predictions. I might have to enter one or two.
>
> i longed for such a accountable predictions for a long time. Usually,
> some fucking fart will do predictions, but the problem is that it's not
[...]
OMG
gt;>> type(z[0])
>>> print "%35.25e" %z[0]
1.23456789123456790e+000
This cuts the digits just like the 32bit case.
Can anyone please help me get more digits?
Thank you very much in advance,
Ulrich
--
http://mail.python.org/mailman/listinfo/python-list
Shah Sultan Alam wrote:
> I have file with contents retrieved from mysql DB.
> which has a time field with type defined bigint(20)
> I want to parse that field into timestamp format(-MM-DD HH:MM:SS
> GMT) using python code.
Try time.strftime.
> The value I found for that field is 212099016004
thomasvang...@gmail.com wrote:
> C:\python30> patch -p0 < fileio_buffer.patch
> The patch command is not recognized..
You need the 'patch' program first. Further, you will need a C compiler. If
you don't know how to compile from sources, I would postpone patching
sources to after learning that.
>
psaff...@googlemail.com wrote:
> I'm building a pipeline involving a number of shell tools. In each
> case, I create a temporary file using tempfile.mkstmp() and invoke a
> command ("cmd < /tmp/tmpfile") on it using subprocess.Popen.
>
> At the end of each section, I call close() on the file handl
Hi!
The unittest module will invoke sys.exit() after running the tests in order
to signal success or failure. However, I sometimes don't want to exit the
interpreter but instead e.g. inspect some state or just keep the window
open. Normally, using '-i' as commandline argument works, but not in the
[EMAIL PROTECTED] wrote:
> I've tried starting with something like this, but I assume it is
> expecting the source to be in unicode already?
>
> e.g. (pretend the second half are EBCDIC characters)
>
> sAll = "This bit is ASCII, "
Why pretend? You can use this:
"abcde\x81\x82\x83\x84"
> sSou
Jaume Bonet wrote:
> When I test the code from C++ each time I delete a vector the consumed
> memory decreases, but it does not happen when the module is called
> from python.
What is a "vector" for you? Do you mean std::vector? A vector allocated
using malloc()? A vector allocated using new? Just
Gilles Ganault wrote:
> I'm getting this error while downloading and parsing web pages:
>
> =
> title = m.group(1)
> UnicodeDecodeError: 'ascii' codec can't decode byte 0xe9 in position
> 48: ordinal not in range(128)
> =
>
> From what I understand, it's because some strings are Unic
Seid Mohammed wrote:
> I am new to python.
Welcome! :)
abebe = 'አበበ በሶ በላ'
abebe
> '\xe1\x8a\xa0\xe1\x89\xa0\xe1\x89\xa0 \xe1\x89\xa0\xe1\x88\xb6
> \xe1\x89\xa0\xe1\x88\x8b'
print abebe
> አበበ በሶ በላ
abeba = ['አበበ','በሶ','በላ']
abeba
> ['\xe1\x8a\xa0\xe1\x89\xa0\xe1\x89\xa0',
luca72 wrote:
> hello i have this problem:
> UnicodeEncodeError: 'ascii' codec can't encode character u'\xe9' in
> position 8: ordinal not in range(128)
This is the result of transcoding a Unicode string to ASCII, where the
Unicode string contains a character that is not representable in ASCII.
Th
201 - 300 of 489 matches
Mail list logo