rtainly get a
boatload of email every day from people offering to help me deal with it.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
erver 2003
have been "rebased" in such a way that they chop up the virtual address
space more than XP. Even though there is more virtual memory available, it
is fragmented.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
to be?
The base64 algorithm converts 3 incoming bytes to 4 encoded bytes. When
you decode base64, the input string MUST be a multiple of 4 bytes. Equal
signs are used to pad the strings to 4n bytes.
The web site you used might be doing that alignment for you.
--
Tim Roberts, [EMAIL PROTECTED]
P
string, int found
>> I want to change list to a=['1','2','3'] but i don't want to use FOR
>> because my list very very big.
>
>What is your worry: memory or time? The result string will be very
>very very big.
It's an interesting mental
les that will read a Word file a
little more directly.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
think about this. I don't know what
>these processors are compatible with at the binary level.
Binary compatibility isn't so important. Python can be built from source.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
he exe in D:\ and did not create a Python25 directory.
Where did you get the installer? I've installed Python on Windows many,
many times, and have never seen this issue.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
ation of Excel spreadsheets and
>> Word documents, interract with Access data bases, and so forth.
>>
>You might download and install Mark Hammond's PythonWin.
(Ummm, win32com.client is PART of Mark Hammond's PythonWin, now called
PyWin32.)
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
bsolutely invaluable for
those occasions.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
rivers if the source code
lives in a path with spaces.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
3_oct : constant := 8#27#;
x23_dec : constant := 10#23#;
x23_hex : constant := 16#17#;
The opportunities for obfuscated coding by writing all constants in base 7
boggle the mind.
I'm not convinced you need delimiters on both ends; I think 16'fffe_3777
would be just as good.
Alth
t amongst the Brits who cut their teeth on 24 bit ICT/ICL
>equipment...
As a long-time Control Data employee, I know that 60-bit words and 18-bit
addresses meant that I could do octal arithmetic nearly as fast as decimal.
On the other hand, Python doesn't run on the 6000s...
--
Tim Rober
ythonwin? If so, then what you are looking at
is not a "shell screen" in any way. It's a simulation, and I don't know of
any way to clear it.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
lly, I chose Python (and wxPython), and both the client and
I are quite happy with the result.
(Actually, I did a Tcl binding for them as well, and just writing the text
scripts reinforced my dislike for it...)
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
dent that I wasn't being serious.
>
>Ooh, now I'm curious.
Seriously? You didn't know that $#x in perl returns the length of the
array @x, minus 1?
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
ked it enough that they've asked for another.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
be relative if the symbolic link is relative, and absolute if the
symbolic link is absolute.
ln -s ../../over/there here1
ln -s /home/timr/spot here2
"here1" is a relative link. "here2" is an absolute link.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
n by "used during a lot of trials and errors"? sys.path is
recreated from scratch every time Python starts. It doesn't accumulate
over time, other than from new packages that you install.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
ngs\User\My Documents\My Python files\wxDemos'. And AnalogClock.py
>does work when residing in that directory.
wxDemos contains the demos. The "wx" module lives in
site-packages\wx-2.8-msw-ansi. Did you leave that in?
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
utation twice, once to
compute the minimum, once to compute the maximum. When you're done, you
can be confident that the true answer lies within the interval.
For people just getting into it, it can be shocking to realize just how
wide the interval can become after some computations.
--
Tim R
peed of light actually was in
furlongs per fortnight.
Now I need to figure out how to work that into a cocktail party
conversation. "Hey, the deficit isn't the only thing that is approaching
1.8 trillion..."
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
ice. You either need to switch to a one of the web
frameworks (like CherryPy or Django or WebWare or one of the hundreds of
others), or move to PHP.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
"Lad" <[EMAIL PROTECTED]> wrote:
>
>What is a good way to read binary data from HUGE file and write it
>to another file?
How huge? I regularly process 100-megabyte MPEG files in Python, both by
reading the whole thing in as a string, and by using "mmap" t
27;] = 'hello'
>py> os.popen('echo $asdfasdf').read()
>'hello\n'
For completeness, let us anticipate the followup question and point out
that "permanent" here means "for this process and any processes that it
spawns". Once the Python session ends, the "asdfasdf" will be lost.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
>
>http://docs.python.org/ref/Booleans.html
>
>In 'expression' rule - what does 'if', 'else' mean? I guess 'if' and
>'else' must be keywords, not non-terminals.
Yes, those refer to literal keywords.
I'd judge both of those as erro
>Here is a prove:-
>>>> import win32com
>
>Traceback (most recent call last):
> File "", line 1, in
>import win32com
>ImportError: No module named win32com
>>>>
>
>you try in your computer
It works just fine in my computer, because I
ating different GUIDs every time you register the thing. If
so, you need to unregister the old version before you register a new one.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
s Driver (*.mdb)};DBQ=x.mdb" )
cmd = win32com.client.Dispatch('ADODB.Command')
cmd.ActiveConnection = conn
cmd.CommandText = "SELECT firstname,lastname FROM users;"
rs = cmd.Execute()[0]
while not rs.EOF:
# Use elements of rs
rs.MoveNext()
There are samples on
guage has identifiers
>such as __device__, __global__, __shared__, etc. Is it a coincidence?
>Probably it is. :)
Well, identifiers starting with an underline are reserved for
implementation use in ISO standard C++, so the chicken and egg question is
an interesting one..
--
Tim Roberts,
", and
that DOES require registering the .py extension and adding .py to the
PATHEXT environment variable.
A very useful thing to do, by the way. I have many command line tools for
which I have forgotten whether they are batch files, small executables, or
Python scripts. And that's
not an expert here ;-)
Yes, that's strictly for COM. And the "App Paths" registry key you
mentioned is only for Explorer things, like the Start menu's "Run" box. It
doesn't apply to the command line. Try typing "wordpad" in a cmd shell,
then try it
If you wrote this:
f.close
(as reformed VB programmers tend to write) it would run without error or
warning, but the file would not actually be closed. The data would be hung
up the buffer, and the file would be 0 length.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
have already been discovered.
It's fine to say "those ideas have been proposed and rejected, see the
PEPs", but I hope this group retains the tolerance that I have long
admired.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
t sending it,
but that's all you can find out. Plus, remember that web proxies can
interfere with this.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
of modules on both Linux and Windows.
>>
> Try installing anything .NETish on Linux?
Unfortunately, depending on your viewpoint, it works just fine, thanks to
the hard work that has gone into the Mono project.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
sk
today only includes 9 x 10**12 bits. Also consider that, by rough
estimate, there are approximately 10**80 atoms in the known universe
today...
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
d PL/I. They are attempting to pack in every
feature that has ever been requested by every person in the known universe.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
, with
tmpl = Template( file='page.tmpl' )
>2. How do I output the HTML to a file? I tried the following:
>
>FILE = open(filename, "wt")
>FILE.writelines(output)
>FILE.close()
>
>I get an error though that states that writelines() requires an
>interabl
pend(pocmonitors_cur.fetchone())
>pocmonitors_cur.close()
>db.close()
What are you trying to do here? If you just want to turn the query results
into a list, you can just do:
pocmonitors = pocmonitors_cur.fetchall()
>output = Template(file='C:\Python25\Lib\site-packages\PSN
>\SafetyNet.tmpl', searchList=[nameSpace])
This string also needs to be escaped.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
assume that p7zip will be installed in /usr/bin/7za. That's not good.
On many of my systems, I install all new packages into /usr/local/bin. Some
people use /opt. You should really check the PATH to look for 7za.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
ad, because that's where window events are delivered.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
ibe if models.comment() were a normal function
that returns a single object, instead of a class name, as I have assumed.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
not that old). I was also wondering about
>the reason for this limitation (maybe the design is ~20 years old).
The IEEE-754 standard was adopted in 1985. Before that (and after that,
too), many people used whatever bit layout they wanted for floating point
numbers.
--
Tim Roberts, [
. Why not just store the raw code
snippets?
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
through that.
>I'll have to refactor my code somewhat to force it to use the '-MM-
>DD' format.
Another possible solution is to use a real database.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
cause the number 2 was not in the list.
Dictionaries do not have a "remove" method. You have to use the "del"
statement.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
e floating point, that's only 2
megabytes. Piece of cake. With 1,000 in each group, it's 8 megabytes.
Still no sweat.
What are you going to do with these distances? Why do you need them all in
memory?
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
he NTVDM (the Virtual
DOS Machine).
32-bit console apps (which Python is) simply cannot use ANSI escape
sequences. You have to use the Win32 APIs to do color. There are
curses-like libraries available for Python. Or:
http://www.effbot.org/zone/console-handbook.htm
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
sult anywhere, the [3,4] list now has no names bound to it, and will get
cleaned up.
fooB(x)
Like before, this is passing the two-element [1,2] list into fooB, where it
gets bound to "y" inside fooB. Again, it has two names bound to it. Then,
when you do
y[0] = 3
you are changing
input.py module, this will eventually call
FileInput.next(), which eventually calls FileInput.readline(), which
eventually calls stdin.readlines(_bufsize). The default buffer size is
8,192 bytes.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
-rw-r--r-- 1 pofuk pofuk 105 2007-12-19 21:59 login.py
Do you want to KNOW the permissions, or do you really want to get the
output of "ls -l"?
What you probably want is os.walk. You can call stat or os.path.isdir to
get information about the files you discover.
--
Tim R
iew, what disqualifies python24.dll as a "system file"? The fact
that it wasn't produced by Microsoft?
>Installing application DLLs in the system directory is something that
>should only be done for backwards compatiblity.
Deployment of Python applications is much easier wh
cording to the Pipex web page, if you got their low-end hosting package
based on Linux, you get PHP4, PHP5, or Perl. No Python.
Perhaps you should have checked your requirements before you spent money on
a web host. There are many good, inexpensive web hosting companies that do
allow Python
darned well
better figure out where they're coming from! Did you add any fields? Did you add an image map?
On the other hand, why do you want to remove them?
--
- Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
=)
I tried to follow the thread backwards and find out what proposed change in
the "class" construct would render "make" unnecessary, but I couldn't find
it. Can you summarize, Steven?
--
- Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
sibility is to parse your .bat files by hand, and make the
changes to your os.environ. Your subprocesses inherit that.
.BAT files are easy to parse, especially if they're just a bunch of 'set'
statements.
--
- Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
pyfileobj
>implementation of hacking through the file and writing a new one is
>significantly faster... any clue as to why this is? I figure I'm
>missing something here.
>
>Does os.system launch a cmd shell every time?
Yes. That's in the documentation.
--
- Tim Roberts
ould have worked:
event_list = [f1, f2, etc]
As it is, event_list is a list of strings, not a list of functions.
Then, when you want to call it, remember that it has to be treated like a
function:
for ev in event_list:
if ev(t):
pass
If you REALLY need the list of functions to
example code also didn't
>turn up anything.
The native Windows radio button cannot do multiline labels. You'll have to
do the first line in the radio button, and the second line as a
wx.StaticText.
--
- Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http
nd a
timestamp, then scan backwards from the end of the file until you find a
timestamp, and subtract.
You can also try to extract the bitrate from an early header and use
arithmetic to get a good estimate.
--
- Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.pytho
at your VGA font happens to display them as the same glyph.
>6) Would it be correct to infer that the print statement is aware of
>characters beyond the 128 characters in the ascii character set?
Certainly. It knows about whatever the current character set is.
--
- Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
Dennis Lee Bieber <[EMAIL PROTECTED]> wrote:
>On Sun, 07 May 2006 00:09:06 GMT, Tim Roberts <[EMAIL PROTECTED]> declaimed
>the following in comp.lang.python:
>
>> [EMAIL PROTECTED] wrote:
>>
>> >6) Would it be correct to infer that the print statement
"help", "copyright", "credits" or "license" for more information.
>>> round(2.99543322,3)
2.9951
>>> print round(2.99543322,3)
2.995
>>>
--
- Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
cial code: "\\u0254". However, I don't see
what good that would do you. The \u escape is a Python source code thing.
>I'm sure this is straightforward but I can't get it to work.
I think it is working exactly as you want.
--
- Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
, there's really no difference between the first two, and this would
work just as well:
s = """foo""" + '''bar'''
The third line only works for string constants, not for string variables.
IMHO, it would be the preferred method
:\DIR2
That will create DIR2 if it does not already exist.
>I could fix this with a nested if statement, but it "feels" like
>windows should be creating this folder automatically if it doesn't
>exist.
What "feels" right is rarely a good reference for a command's
eLoadMovie and the another one belongs to the handler for the
>second event?
No. wxCallAfter basically posts another message to the message queue,
which will be handled after all the existing messages have been dispatched.
Windows message handling is quite synchronous.
--
- Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
However, that doesn't answer the question, because even Python 1.5 should
have a module called "math".
--
- Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
ndard library.
Modules that are part of a single project should be in a common directory
for that project. Modules that are of general interest to you for multiple
projects should be in \Python24\Lib\site-packages.
--
- Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
one CRT DLL and freeing in another can cause
problems, but in Python, I don't think that can happen. Proper Python
add-ins call Python APIs to create and destroy objects, so only the Python
runtime will manage the memory.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
wide.
However, that requires injecting the hook DLL into every process with a
Windows, and you certainly don't want to do that in Python. Write a
minimal C DLL to be the hook, and have it send messages to your Python
process.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
d as
well. Would this be an appropriate construct to add to itertools?
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
code reads like English
prose. It's certainly possible to code "write-only" sequences by abusing
comprehensions and generators, but obfuscations like that are the exception
rather than the rule.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
test.
Bull crap. You don't HEAR about them because of that same security
clearance issue, but some of the most complicated and certainly some of the
LARGEST computing systems in the world come out of the DoD. You don't
create reliable large systems using a corral full of bright-eyed col
en a very, very distant point of view with narrowly
>squinted eyes.
Do you really think so? It seems clear to me that the syntax of PHP was
heavily influenced by Perl. PHP lacks the @array and %hash weirdnesses,
but most PHP code will work just fine as Perl.
--
Tim Roberts, [EMAIL PROTECTED]
Pro
r
for .py files? Did you create a PythonHandler referring to hello.py?
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
tly from frame to frame. You'll have
to look for a range.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
t. Your description
isn't specific enough; there are several ways to do it, some right, some
wrong...
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
re talking about raw number crunching. This is exactly the kind of
case where you should write some C or C++ code and call it from Python.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
"Delaney, Timothy (Tim)" <[EMAIL PROTECTED]> wrote:
>
>You know you've been working at a large company for too long when you
>see that subject and think "ISO-certified Python?"
That's exactly what I thought, too. After reading the post I assume he
a
t;more"? The Python shell does that
for the "help" command, but maybe you could post a more precise example of
what you want.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
variables do, what the
states mean, etc. It's easy to do; you just start the text with # signs.
# This function allows you to ...
# These variables define the connection state as the connection is
# made.
They're great. You should try them.
--
Tim Roberts, [EMAIL PROTECTED]
Pr
Oct 18 2006, 08:34:43) [MSC v.1310 32 bit (Intel)] on
win32
Type "help", "copyright", "credits" or "license" for more information.
>>> id(True)
504958236
>>> a = True
>>> id(a)
504958236
>>> id(False)
504958224
>>&g
eter DLL,
and any DLLs they might need, and shove them in a single file (.zip, in the
py2exe case). The parts get extracted for execution.
The distribution will still contain the .pyc files, and there are tools
that can decompile a .pyc without much trouble.
--
Tim Roberts, [EMAIL PROTECTED]
he intermediate language created by the Python
"compiler".
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
llection of interesting public domain Python
scripts for numerical analysis and linear programming problems and puzzles.
http://www.ics.uci.edu/~eppstein/
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
net session, the user is going to press CR when its through with a
line. Thus, I would think he needs either \r\r or \n\n.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
hould be getting back a 'OK' or 'ERROR'. But I
>am not seeing it. I feel like I am missing something. Not sure what
>would be the or is it the telnet application itself.
Are you talking to a modem here? Are you sure you don't need +++ to get
its attention before sending AT commands?
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
.execute("SELECT * FROM names WHERE name=%s", ('S',) )
Note that the extra comma is required in Python to make a one-element
tuple.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
)
>
>The error is coming from this line;
>sock.bind ((MCAST_ADDR, MCAST_PORT))
>
>Can anyone please help me solve this problem?
Where did you get the multicast module? Are you trying to do TCP
multicast? What is the address you are trying to use?
--
Tim Roberts, [EMAIL PROTECTED]
g around python's mmap module, but I
>can't figure how to use it without files.
So, let it use a temporary file. What's the harm? An anonymous mmap
region is still mapped to the swap file. Might as well give it a name.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boe
sub,sub,sub]
> >>> full
>[[1, 2, 3], [1, 2, 3], [1, 2, 3]]
> >>> sub[0] = 123
> >>> full
>[[123, 2, 3], [123, 2, 3], [123, 2, 3]]
And:
>>> full[0][2] = 99
>>> sub
[123, 2, 99]
>>> full
[[123, 2, 99], [123, 2, 99], [123, 2, 99]]
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
> if (os.path.isfile('c:\\src\\kasjdfl.txt'))
>SyntaxError: invalid syntax
>
>any idea what is incorrect in my syntax
You know that this is not C, and that the parentheses are not needed in the
"if" statement? In my opinion, they interfere with readability.
-
es. The same kind of issue
occurs with mod_python and the multitude Python web frameworks, and many of
them detect changed files and automatically restart. If you really need a
clean environment, then you need a new interpreter.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
"credits" or "license" for more information.
>>> L = [1,2,3]
>>> id(L)
10351000
>>> L += [4]
>>> id(L)
10351000
>>>
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
_extract_bookmarks_from_url_history
>timestamp = datetime.datetime.strptime(month_string, '%b ‘
>%y')
>AttributeError: type object 'datetime.datetime' has no attribute
>'strptime'
I suppose it is cruel of me, but I find it hilarious that you looked at
t
gt;(B)
> pf= '?, ?, ?, ?'
>sqlxb= 'INSERT INTO DTABLE2 VALUES ( %s ) ' % pf
>curs.execute( sqlxb, values )
>
>Any intution on why (A) is slower?
I think you misunderstood. (B) is *ALWAYS* the proper way of doing
parameterized SQL queries. Unconditiona
he port
>3). Free the port before external program execution.
What's the point? Why can't the actual user of the port create the port,
and then notify the other side of the port number?
And why don't you just specify a port number of 0 and let the system assign
you a free po
it were a directory. It's a very handy feature for distributing
premade packages.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
I know. Why?
>
>"The master said so" isn't an entirely satisfying answer.
Nevertheless, it IS the answer for many questions in the Python world.
That's the advantage of being Benevolent Dictator For Life.
--
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.
--
http://mail.python.org/mailman/listinfo/python-list
501 - 600 of 968 matches
Mail list logo