[issue44760] Turtle Documentation - Contents Hyperlink conflict

2021-08-04 Thread Harry


Change by Harry :


--
keywords: +patch
pull_requests: +26093
stage: needs patch -> patch review
pull_request: https://github.com/python/cpython/pull/27592

___
Python tracker 
<https://bugs.python.org/issue44760>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44760] Turtle Documentation - Contents Hyperlink conflict

2021-08-04 Thread Harry


Harry  added the comment:

The conflict comes from the fact that the documentation is written from the 
perspective of the procedure-oriented interface

"All methods of TurtleScreen/Screen also exist as functions, i.e. as part of 
the procedure-oriented interface"

The conflict in the documentation comes from the fact that there is a conflict 
in the code as-well. The way the conflict is resolved in the code is that:

"This TurtleScreen method is available as a global function only under the name 
clearscreen. The global function clear is a different one derived from the 
Turtle method clear."

I propose that we noindex the TurtleScreen.clear() method, and index the 
Turtle.clear() method instead which more accurately reflects the behaviour of 
the turtle module itself. A link to the TurtleScreen.clear() method will still 
be available through its alias TurtleScreen.clearscreen().

------
nosy: +Harry-Lees

___
Python tracker 
<https://bugs.python.org/issue44760>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44186] TimedRotatingFileHandler overwrite log

2021-08-01 Thread Harry


Harry  added the comment:

The issue appears when the TimedRotatingHandler rolls over to a filename that 
already exists. Running your bash script, the handler correctly rolls over so 
you end up with the expected behaviour. This issue arises in the case that 
there is already a file with the target name, that file will be overwritten 
when the handler rolls over.

This can be seen clearly if you modify test.sh to contain

python3 log_44186.py foo
python3 log_44186.py bar
python3 log_44186.py baz

results are below:

$ python3 --version
Python 3.9.5
$ bash ./test.sh
10 14 51
TEST > [INFO] [2021-08-01 10:14:51] : foo 2021-08-01T10:14:51.521266
10 14 51
TEST > [INFO] [2021-08-01 10:14:51] : bar 2021-08-01T10:14:51.577802
10 14 51
TEST > [INFO] [2021-08-01 10:14:51] : baz 2021-08-01T10:14:51.634795
$ ls | grep .log
test.log
test.log.2021-07-31
$ cat test.log
baz 2021-08-01T10:14:51.634795
$ cat test.log.2021-07-31 
bar 2021-08-01T10:14:51.577802

as you can see, the logs from foo have been overwritten.

A very similar result can be seen if you manually create a file and then run 
the test script.

$ python3 --version
Python 3.9.5
$ echo "logging test" > test.log.2021-07-31
$ python3 log_44186.py foo
10 33 25
TEST > [INFO] [2021-08-01 10:33:25] : foo 2021-08-01T10:33:25.003750
$ cat test.log
foo 2021-08-01T10:33:25.003750
$ cat test.log.2021-07-31
$

once again, you can see that the handler overwrote the target file (this time 
leaving it blank as there were no logs to write).

--

___
Python tracker 
<https://bugs.python.org/issue44186>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44543] Remove depreciated logging.warn() method

2021-07-01 Thread Harry


New submission from Harry :

The logging.warn() method as an alias for logging.warning() is a mysterious 
function in the logging module, as far as I can tell it was depreciated the 
minute it was added, originally only added for backwards compatibility.

Up until 3.3 it was undocumented, and after that it was Depreciated and was set 
to be removed in 3.4 (https://bugs.python.org/issue13235). At this point, I 
believe this function only serves to create confusion as an obscure alternative 
to logging.warning() and should probably be removed in 3.11.

--
components: Library (Lib)
messages: 396813
nosy: Harry-Lees
priority: normal
severity: normal
status: open
title: Remove depreciated logging.warn() method
type: enhancement
versions: Python 3.11

___
Python tracker 
<https://bugs.python.org/issue44543>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44186] TimedRotatingFileHandler overwrite log

2021-06-05 Thread Harry


Change by Harry :


--
keywords: +patch
pull_requests: +25140
stage:  -> patch review
pull_request: https://github.com/python/cpython/pull/26553

___
Python tracker 
<https://bugs.python.org/issue44186>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44186] TimedRotatingFileHandler overwrite log

2021-06-04 Thread Harry


Harry  added the comment:

This bug seems to come from the fact that the file rollover occurs it removes 
any files with same name as the destination file.

I believe this bug occurs on all "when" options, but the midnight option 
truncates the filename so only the date so it's much more likely to be a 
collision in filename so it's much easier to notice that it's happening.

One way of fixing this is to check if the destination file already exists, and 
if it does, append the logs to the end of the file instead of overwriting it.

Another potential fix is to check if the destination file already exists, and 
if it does rename it to something else, or even to choose a different name for 
the destination file of the log e.g. if the filename would be log.2021-05-05 
but there is a collision, call the file log.2021-05-05(1).

Personally I prefer the last option, it seems like the best way to avoid any 
future issues that could arise from appending. I can open a PR for this in the 
morning.

--
nosy: +Harry-Lees

___
Python tracker 
<https://bugs.python.org/issue44186>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43648] Remove redundant datefmt option in logging file config

2021-03-28 Thread Harry


Change by Harry :


--
keywords: +patch
pull_requests: +23800
stage:  -> patch review
pull_request: https://github.com/python/cpython/pull/25051

___
Python tracker 
<https://bugs.python.org/issue43648>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43648] Remove redundant datefmt option in logging file config

2021-03-28 Thread Harry


New submission from Harry :

In the logging.conf section of the docs, there is a redundant datefmt option

https://docs.python.org/3.10/howto/logging.html#configuring-logging

--
assignee: docs@python
components: Documentation
messages: 389637
nosy: Harry-Lees, docs@python
priority: normal
severity: normal
status: open
title: Remove redundant datefmt option in logging file config
versions: Python 3.10

___
Python tracker 
<https://bugs.python.org/issue43648>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



.python_history file

2019-07-29 Thread Harry Grey
Hy to Everyone
first of all : Sorry for my english

what do you think about introducing a feature that allows you to group
by date
and after to filter the istruction that are written in the
.python_history file:
maybe with a new structure for .python_history: 

"""
###DATE-OF-SOME-DAY-START###


###DATE-OF-SOME-DAY-END###

"""

and maybe developing a new tool, or a core functionality of python
interpreter callable as an argument in the cmd, that allow you to parse
the .python_history file in given date:

With a tool:

PhYstory -d 16 -m 03 -y 2019

or like python Functionality:

python -hist 16-03-2019/17-03-2019

and why not? why not have a the chance to enable and disable, at will,
writing in the .python_history:

""
>>> skip_hist
>>>
>>> # Make some unusefull instruction
>>> # Ignored in the history
>>> class TryClass:
>>> # Some Code
>>> 
>>>
>>> tc = TryClass()
>>> keep_hist
>>> # make some interesting code
>>> # and keep it in the history file.
"""

Thanks

DG.
-- 
https://mail.python.org/mailman/listinfo/python-list


[issue37620] str.split(sep=None, maxsplit=-1,any=False)

2019-07-19 Thread Harry Coin

Harry Coin  added the comment:

I suspect the number of times the str.split builtin was examined for use 
and rejected in favor of the much more complex and 'heavy' re module 
far, far exceeds the number of times it found use with more than one 
character in the split string.

The str.split documentation 'feels like' the python equivalent of the 
linux 'tr' utility that treats the separator characters as a set instead 
of a sequence.   Notice the default and the help(str.split) 
documentation tends to encourage that intuition as no sep= has a very 
different behavior:  no argument 'removes any whitespace and discards 
empty strings from the result'.  That leads one to suspect each 
character in a string would do the same.

Mostly it's a use-case driven obviousness, you'd think python would 
naturally do that in str.split. So very many cases seek to resolve a 
string into a list of the interesting bits without regard to any mix of 
separators  (tabs, spaces, etc to increase the readability of the file).

I think it would be a heavily used enhancement to add the 'any=True' 
parameter.

Or,  in the alternative, allow the argument to sep to be an iterable so 
that:

'ab, cd'.split(sep=' ,') -->  ['ab, cd']

but

'ab, cd'.split(sep=[' ',',']) -> ['ab', 'cd']

On 7/19/19 1:34 PM, Serhiy Storchaka wrote:
> Serhiy Storchaka  added the comment:
>
> An alternative is to use regular expressions.
>
>>>> re.split('[\t ]+', 'ab\t cd ef')
> ['ab', 'cd', 'ef']
> .
>
> --
> nosy: +serhiy.storchaka
>
> ___
> Python tracker 
> <https://bugs.python.org/issue37620>
> ___

--

___
Python tracker 
<https://bugs.python.org/issue37620>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue37620] str.split(sep=None, maxsplit=-1,any=False)

2019-07-18 Thread Harry Coin


New submission from Harry Coin :

When first I read the str.split documentation I parsed it to mean
'ab\t cd ef'.split(sep=' \t') --> ['ab','cd','ef']
Especially as the given example in the docs with the <> would have led to the 
given result read the way I read it.

I suggest adding a parameter 'any=False' which by default gives the current 
behavior.  But when True treats each character in the sep string as a delimiter 
and eliminates any combination of them from the resulting list.

The use cases are many, for example parsing the /etc/hosts file where we see an 
address, some white space that could be any combination of \t and ' ' followed 
by more text. 

One could imagine 'abc  \tdef, hgi,jlk'.split(', \t',any=True) -> 
['abc','def','hgi','jlk'] being used quite often.

--
components: Library (Lib)
messages: 348116
nosy: hcoin
priority: normal
severity: normal
status: open
title: str.split(sep=None, maxsplit=-1,any=False)
type: enhancement

___
Python tracker 
<https://bugs.python.org/issue37620>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue36296] distutils.version.StrictVersion objects cannot be compared with distutils.version.LooseVersionobjects

2019-03-15 Thread Harry Seeber

Harry Seeber  added the comment:

I'm using these classes directly to parse semantic-ish versions in metadata
for Munki packages (a package manager for MacOS). Looks like this packaging
library is what I should use. Thanks you!

On Thu, Mar 14, 2019 at 5:32 PM Éric Araujo  wrote:

>
> Éric Araujo  added the comment:
>
> Hello!  Are you seeing this problem when building or installing some
> package, or are you using the classes directly?
>
> If it’s the latter, I would recommand you to use
> https://pypi.org/project/packaging/ rather than distutils, which is not
> meant to be used as a generic library.
>
> --
>
> ___
> Python tracker 
> <https://bugs.python.org/issue36296>
> ___
>

-- 

Harry Seeber

IT Support | Gusto <http://gusto.com/>

Gusto | all-in-one platform for HR, payroll, and benefits

noun (guhs-toh)

great enjoyment, energy, and enthusiasm

ex: Harry's cat Edgar pounces upon butterflies #withGusto

--

___
Python tracker 
<https://bugs.python.org/issue36296>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue36296] distutils.version.StrictVersion objects cannot be compared with distutils.version.LooseVersionobjects

2019-03-14 Thread Harry Seeber


New submission from Harry Seeber :

The self.version used in Version._cmp is a List in LooseVersion's 
implementation, a Tuple in StrictVersion's implementation. Attempting to 
compare Strict & Loose versions results in a TypeError.

I'd like to PR a fix, but I'd like to know if I'm being stupid first :)

--
components: Distutils
messages: 337957
nosy: Harry Seeber, dstufft, eric.araujo
priority: normal
severity: normal
status: open
title: distutils.version.StrictVersion objects cannot be compared with 
distutils.version.LooseVersionobjects
versions: Python 3.6

___
Python tracker 
<https://bugs.python.org/issue36296>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue24658] open().write() fails on 2 GB+ data (OS X)

2016-11-06 Thread Harry Li

Changes by Harry Li <harryl.byr...@gmail.com>:


--
nosy: +Harry Li

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue24658>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue24738] os.link issues on Windows ReFS

2015-07-27 Thread Harry Lam (WaXHeLL)

New submission from Harry Lam (WaXHeLL):

Storage Spaces (RAID volumes) under Windows 8.1 / Server 2012 R2 use ReFS which 
does not support hard links.

If the Users directory has been moved to a ReFS volume, it causes any script 
that uses os.link to hang (pip is one of the notable examples). As a side 
effect -- this also makes it so that Python can not be uninstalled if pip is 
installed. The script must be terminated with a ctrl-c.

Tested under 3.5.0b3 as well as 3.4.3 (x64 as well as x32).

Traceback from ctrl-c on 'pip list':

I:\pip list
Traceback (most recent call last):
  File C:\Program Files\Python 3.5\lib\site-packages\pip\_vendor\lockfile\linkl
ockfile.py, line 30, in acquire
os.link(self.unique_name, self.lock_file)
OSError: [WinError 50] The request is not supported: 'I:\\Users\\[[USER NAME 
REMOVED]]\\AppData\
\Local\\pip\\Cache\\[[COMPUTER NAME REMOVED]]-1d14.781968199621979134564595' - 
'I:\\Users\
\[[USER NAME REMOVED]]\\AppData\\Local\\pip\\Cache\\selfcheck.json.lock'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File C:\Program Files\Python 3.5\lib\runpy.py, line 170, in _run_module_as_m
ain
__main__, mod_spec)
  File C:\Program Files\Python 3.5\lib\runpy.py, line 85, in _run_code
exec(code, run_globals)
  File C:\Program Files\Python 3.5\Scripts\pip.exe\__main__.py, line 9, in mo
dule
  File C:\Program Files\Python 3.5\lib\site-packages\pip\__init__.py, line 217
, in main
return command.main(cmd_args)
  File C:\Program Files\Python 3.5\lib\site-packages\pip\basecommand.py, line
220, in main
pip_version_check(session)
  File C:\Program Files\Python 3.5\lib\site-packages\pip\utils\outdated.py, li
ne 134, in pip_version_check
state.save(pypi_version, current_time)
  File C:\Program Files\Python 3.5\lib\site-packages\pip\utils\outdated.py, li
ne 71, in save
with lockfile.LockFile(self.statefile_path):
  File C:\Program Files\Python 3.5\lib\site-packages\pip\_vendor\lockfile\__ini
t__.py, line 238, in __enter__
self.acquire()
  File C:\Program Files\Python 3.5\lib\site-packages\pip\_vendor\lockfile\linkl
ockfile.py, line 49, in acquire
time.sleep(timeout is not None and timeout/10 or 0.1)
KeyboardInterrupt

--
components: Windows
messages: 247496
nosy: Harry Lam (WaXHeLL), paul.moore, steve.dower, tim.golden, zach.ware
priority: normal
severity: normal
status: open
title: os.link issues on Windows  ReFS
type: crash
versions: Python 3.4, Python 3.5

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue24738
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue24738] os.link() issues on Windows ReFS

2015-07-27 Thread Harry Lam

Harry Lam added the comment:

Slight bit of clarification:

This doesn't affect all scripts -- just those which don't have proper Except 
OSError handling. In pip's case, a timeout is not passed to the acquire() 
function when it is first being called and causes this issue with hanging.

--
title: os.link issues on Windows  ReFS - os.link() issues on Windows  ReFS

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue24738
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



How to recovery the default Library/Python/ folder on Mac?

2014-03-08 Thread Harry Wood

How to recovery the default Library/Python/  folder on Mac? 


I delete it by some mistakes..., I have tried the following steps:

- Step 1. Download and install Python DMG from Python.org .

   Result: There are no Python folders under Library after I installed the 
Python DMG.

- Step 2. I tried to use  brew install python  in Terminal.
   Result: $ brew uninstall python 
 Error: No such keg: 


What should I need to do now? Please give me some specific directions, Thanks.
-- 
https://mail.python.org/mailman/listinfo/python-list


How to create a voting website by Python and Flask?

2014-03-03 Thread Harry Wood
How to create a voting website by Python and Flask? I studying Python and Flask 
for some months, and

 - Now I have some Python  Flask basic skills.
 - I need some advices like following example: 
Step 1: You could writing an voting application by Python Step 2: You could 
build a website by Flask ...
Thanks very much!
-- 
https://mail.python.org/mailman/listinfo/python-list


Converting folders of jpegs to single pdf per folder

2014-01-16 Thread Harry Spier
Dear list members,

I have a directory that contains about a hundred subdirectories named
J0001,J0002,J0003 . . . etc.
Each of these subdirectories contains about a hundred JPEGs named P001.jpg,
P002.jpg, P003.jpg etc.

I need to write a python script that will cycle thru each directory and
convert ALL JPEGs in each directory into a single PDF file and save these
PDF files (one per directory) to an output file.

Any pointers on how to do this with a Python script would be appreciated.
Reading on the internet it appears that using ImageMagick wouldn't work
because of using too much memory. Can this be done using the Python Image
Library or some other library? Any sample code would also be appreciated.

Thanks,
Harry Spier
-- 
https://mail.python.org/mailman/listinfo/python-list


Which Python Framework for REST API and Facebook Wrapper?

2013-09-28 Thread harry . andrei
I will be designing a REST based API for a cross-platform back end that will 
serve both desktop Facebook users as well as mobile users. It will handle 
operations such as user creation, retrieval of user and other data, payment 
verification and in the case of the desktop side, handle the html/css template 
customization. The database back end is MySQL and I do need a cache system.

Currently we were using Codeigniter (PHP) for our codebase but as CI seems on 
the way out, I do not wish to start a new project based on it. I was looking at 
Laravel for PHP, but, Python is very attractive to me as a language and since 
the introduction of WSGI, I am confident it can make a difference in 
performance and code maintainability over PHP while being able to plug in to 
our dedicated server infrastructure. 

Since I am not experienced with Python frameworks (though learning curve is not 
much of an issue for me) I look to the community to understand which Python 
framework can rival or surpass Codeigniter in terms of performance in heavy 
traffic backend solutions (over 1M requests per day, with up to 100 req/sec at 
peak). I really want to make the switch from PHP to Python as I believe that 
Python can solve more problems with less code and faster execution time, not to 
mention freedom from brackets and semicolons.
-- 
https://mail.python.org/mailman/listinfo/python-list


[issue18190] RuntimeError raised with re.search + re.DOTALL on empty string

2013-06-11 Thread Harry Bock

New submission from Harry Bock:

In Python 2.7.5, running re.search on regular expressions beginning with '.+' 
will raise RuntimeError if:
 * the string being matched is empty
 * the flags include re.DOTALL/re.S

 re.search(.+a, , flags=re.S)
  File C:\Python27\lib\site-packages\IPython\core\interactiveshell.py, line 
2731, in run_code
exec code_obj in self.user_global_ns, self.user_ns
  File ipython-input-16-fefa32a418ba, line 1, in module
myre.search()
RuntimeError: internal error in regular expression engine

This does not occur if the input string is not empty, or if re.match is used 
instead of re.search, or if the re.S flag is omitted.

The bug does not occur on previous versions of Python 2.x, including 2.7.4.

--
components: Regular Expressions
messages: 190966
nosy: ezio.melotti, hbock, mrabarnett
priority: normal
severity: normal
status: open
title: RuntimeError raised with re.search + re.DOTALL on empty string
type: behavior
versions: Python 2.7

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue18190
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



Re: A computer programmer, web developer and network admin resume

2013-05-22 Thread Harry Percival
oh wow.  great one, thanks for that tim :)


On 22 May 2013 14:03, Tim Chase python.l...@tim.thechases.com wrote:

 On 2013-05-22 16:39, Chris Angelico wrote:
  On Wed, May 22, 2013 at 12:32 PM, Tim Chase
  python.l...@tim.thechases.com wrote:
   On 2013-05-22 01:15, i...@databaseprograms.biz wrote:
   A computer programmer, web developer and network administrator
  
   ...walk into a bar...
  
   So what's the punchline?
 
  ;steps up to the mike
 
  So yeah, as I was saying, a programmer, a web dev, and a BOFH walk
  into a bar. The other two buy the BOFH a drink, because they're not
  stupid, and anyway, so this luser walks up to them with a resume in
  his hand.
 
  , says the luser.
 
  So what's the punchline? says the computer programmer.
 
  The stand-up comic steps up to the mike, and he says, So yeah, as I
  was saying, a programmer, a web dev, and a BOFH walk into a stable
  time loop...

 So a pirate programmer walks into a bar with a bird on his shoulder.
 The bird repeatedly squawks pieces of nine! pieces of nine!.  The
 bartender looks at him and asks what's up with the bird? to which
 the pirate says Arrr, he's got a parroty error.  The bartender
 replies, Ah, I thought he was a bit off.

 -tkc



 --
 http://mail.python.org/mailman/listinfo/python-list




-- 
--
Harry J.W. Percival
--
Twitter: @hjwp
Mobile:  +44 (0) 78877 02511
Skype: harry.percival
-- 
http://mail.python.org/mailman/listinfo/python-list


suggestions for best practices lite for small site deployment with testing

2013-05-21 Thread Harry Percival
Hi everyone,

We've been having a bit of a discussion of this topic over on the Python-UK
list (http://mail.python.org/pipermail/python-uk/2013-May/thread.html#2949),
and I was a bit shy about mailing out to the big, bad, worldwide Python
list, but I'm forcing myself!

So I'm writing a book, for O'Reilly, on TDD with Python, and I'm looking
for some help and suggestions on my current chapter (well, I'm looking for
help and suggestions in general too!  i need all the help i can get.).

http://www.obeythetestinggoat.com/what-to-say-about-deployment.html

So far I've taken the user through building a basic site, and now I want to
get them to deploy it.  It's very early days, but minimum-viable-product
and all that, deploying early + often is a good habit to get into.

cf the blog post above for a bit of background.  I'm currently leaning away
from talking about the various PaaS offerings, they being too many +
varied, and I have a bit of a conflict of interest since I work at
PythonAnywere.  Instead, I'm currently thinking we'll spin up a small linux
box, put apache on it, and run both the staging and live site from  there.
All good stuff to learn...  Hopefully some of the lessons will be
applicable to PaaSes anyway.

So, some questions:
provisioning = spinning up a server, installing apache, setting up
virtualhost config.  confirm I should encourage people to automate this?
Am leaning towards just using fabric, is bringing in another tool
(chef/puppet/salt) overkill?

deployment = updating the source code, database migration, static files.
What are your favourite ways of doing this?  Shell scripts? Git push
hooks?  I'm thinking fabric, again...

Also: testing -- if the above two steps are automated using fabric, they'll
be *functionally* tested because we'll run the functional test suite
against the staging site.  Any thoughts on whether + how to *unit* test
deployment scripts?

Take a look at the blog post, and let me know what you think?  Bear in
mind, at this stage, I'm looking for best practices lite -- at this
stage, it's a tiny website, I can always bring in some more complexity
later on.  The idea is to get people introduced to the idea of deployment,
how you automated, and where testing comes in.  We don't have to talk about
CDNs or zero-downtime or multi-server configuration management yet...

Thanks in advance for any thoughts!
Harry

-- 
--
Harry J.W. Percival
--
Twitter: @hjwp
Mobile:  +44 (0) 78877 02511
Skype: harry.percival
-- 
http://mail.python.org/mailman/listinfo/python-list


[issue17770] MSI installer default behaviour inconsistent

2013-04-16 Thread Harry Johnston

New submission from Harry Johnston:

When installing python-2.7.4.msi via the GUI, the default setting for the 
installation type is All Users.

When installing it passively, e.g.

msiexec /package python-2.7.4.msi /passive

the default installation type is Just For Me, or at least that is how it is 
behaving - no entry is added to Uninstall Programs, the Start Menu entries are 
created for the current user only, and registry entries are created in HKCU 
instead of HKLM.

This makes enterprise deployments difficult.

I'm running Windows 7 x64 SP1.

--
components: Installation
messages: 187133
nosy: Harry.Johnston
priority: normal
severity: normal
status: open
title: MSI installer default behaviour inconsistent
type: behavior
versions: Python 2.7

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue17770
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue17770] MSI installer default behaviour inconsistent

2013-04-16 Thread Harry Johnston

Harry Johnston added the comment:

Never mind, I found where this is documented.  Still seems odd to me, but it's 
not a bug.

--
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue17770
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



PythonAnywhere - a web-based Python console, IDE and hosting environment

2011-11-19 Thread Harry Percival
Hideley-ho Python People!

So we've finally overcome just-one-more-feature-itis and decided it's
time to announce ourselves to the world. So, without further ado, but
with much pomp and fanfare, may we proudly present:

http://www.pythonanywhere.com PythonAnywhere!

A web-based python console, development environment, and hosting
service, all rolled into one, and featuring a snake made out of Python
chevrons. Oh yes.

You can find out more from our screencasts, on the front page (be sure
to check out the alternative versions too), but in brief:

- it's a web-based console, with Pythons 2.6, 2.7, 3.2, IPython, pypy...
and Bash!
- it's got a syntax-highlighting web-based editor, and each user gets
500MB of storage
- and we offer FREE web hosting for WSGI apps, with sqlite or MySQL
backends.

Hmmm. Browser-based Python... What the heck is the point of that, I hear
the cynics amongst you ask. WELL:

- you can suspend and resume console sessions from any browser or PC

- you can access and run your Python code anywhere you go, without
needing to install anything - a friend's house, an internet cafe in
Thailand, your jailhouse library's computer, wherever it may be.

- you can schedule automated tasks to run on our servers, any time of
day or night, without needing to waste your own electrickery.

- and you can host and deploy web apps, without having to worry about
installing packages, configuring web servers, firewalls, or, indeed,
*paying for it*.


So come check it out!  I absolutely, positively, cast-iron-guarantee
that, not only will you not be disappointed, but you will be literally*
blown away.  If you're not, I hereby authorise you, without any
reservation, to tweet angrily about it.

http://www.pythonanywhere.com/

See you soon!

~:===

Harry

* not literally.


-- 
Harry Percival
Developer
ha...@resolversystems.com
+44 (0) 20 3051 2751

PythonAnywhere - full python dev  hosting, in your browser
http://www.pythonanywhere.com/

17a Clerkenwell Road, London EC1M 5RD, UK
VAT No.: GB 893 5643 79
Registered in England and Wales as company number 5467329.
Registered address: 843 Finchley Road, London NW11 8NA, UK
-- 
http://mail.python.org/mailman/listinfo/python-announce-list

Support the Python Software Foundation:
http://www.python.org/psf/donations/


help need to write a python spell checker

2010-05-15 Thread harry k
Write a spell checking tool that will identify all misspelled word in a text 
file using a provided dictionary.


The program will accept either one or two command line parameters.
1.  The first command line parameter is the name of the text file that will 
be checked.
2.  The optional second command line parameter is the name of the 
dictionary file – a file of words with one word per line.  The default 
dictionary file is ref.txt.
The program will write out the misspelled words, one per line, in alphabetical 
order.

Extend the spell checking tool so that as well as identifying all misspelled 
words,  the program will list the line numbers in the file where the incorrect 
spelling occurs.

The program will write out the misspelled words (one per line, in alphabetical 
order), followed by a tab character, followed by the list of line numbers that 
word is misspelled in,in ascending order, on the same line, separated by a 
single space.


Extend the spell-checking tool so that the program will also print out a list 
of possible correct spellings for the words.

The program will write out the misspelled words (one per line, in alphabetic 
order), followed (on the same line) by a single space, followed by the list of 
line numbers in ascending order, each separated by a single space, followed by 
a single space, then the list of possible correct spellings, each separated by 
a single space.

Find the alternate spellings by considering:
a.  Words in the dictionary that are the same length but:
a.  Have a pair of characters interchanged
b.  Differ by one character from the misspelled word
b.  Words that are one character longer or one character shorter, but 
otherwise match the misspelled word.

-- 
http://mail.python.org/mailman/listinfo/python-list


Testoob: How do you use testoob.collector_from_globals / collector_from_modules?

2009-07-27 Thread Harry Ebbers
Hi,

For a project I'm creating unittests using testoob. When all tests are
in a single file there is no problem

if __name__ == '__main__':
testoob.main()
 does the trick as usual.

But for a number of python-applications they have asked me to group
unittests in different files, based on common functionality (e.g. GUI,
main-application, etcetera).

Ican get it to work by importing all unittestclasses in the following
way and than use the normal if __name__ == '__main__' construction

(from GUI import GUItests
from APP import APPtests

if __name__ == '__main__':
testoob.main())

But looking at the future I would like to use testsuites.

On the internet I found the functions testoob.collector_from_globals
and collector_from_modules which one can use to 'easily' create
testsuites which can be used with testoob. But no examples on how to
use them can be found.

Can anybody supply me with a working example?

TIA

Harry Ebbers
-- 
http://mail.python.org/mailman/listinfo/python-list


command line of a process.exe on another host

2009-06-11 Thread Harry

HI ,
I have number of process run on different windows servers which run's with 
different command line parameters. for example process.exe -inputddd 
statusurl: http://sss.com ., These parameters can vary from host to host. 
using Psexec I know the PID and process name which are running on these 
machines, but how I can read the command line parameters of these process. 
Is there a way to read these command line of the proess via python pls?


any feedback appreciated..

thanks
Hari

--
http://mail.python.org/mailman/listinfo/python-list


Upcoming Conference

2008-11-12 Thread Harry
Upcoming conference please visit http://zeus.cp.eng.chula.ac.th/~g49snk
--
http://mail.python.org/mailman/listinfo/python-list


Python FTP - NameError: name 'mydpa' is not defined

2008-07-28 Thread Harry
Hi there. I am trying to download a file(sn.last) from a public FTP 
server with the following code:

from ftplib import FTP
ftp=FTP('tgftp.nws.noaa.gov')
ftp.login()
ftp.cwd('SL.us008001/DF.of/DC.radar/DS.81dpr/SI.kbuf')
ftp.retrbinar('RETR sn.last', open(mydpa,'wb').write)
ftp.quit()

but got an error message, which I think is normal:

Traceback (most recent call last):
  File pyshell#13, line 1, in module
ftp.retrbinary('RETR sn.last', open(mydpa,'wb').write)
NameError: name 'mydpa' is not defined

I don't know much about python, but just try to use the code to 
download data. I don't know where the file will be saved to. Is the 
mydata a file name or a folder name? where will it be saved to even 
if it's working? Please help be fixed the problem step by step? I am 
using 2.5.2 by the way.

I really appreciate your help. Thanks.


--
http://mail.python.org/mailman/listinfo/python-list


TypeError: unsupported operand type(s) for /: 'NoneType' and 'NoneType'

2008-05-01 Thread Jordan Harry
I'm trying to write a simple program to calculate permutations.  I created a 
file called mod.py and put the following in it:
 
def factorial(n):
a = n
b = n
while a0 and b1:
n = (n)*(b-1)
b = b-1
 
def perm(n, r):
a = factorial(n)
b = factorial(n-r)
q = a / b
print q

Then I went back to IDLE and input the following:
 
 import mod
 mod.perm(5, 4)
 
I recieved the following error message:
 
Traceback (most recent call last):
  File pyshell#1, line 1, in module
mod.perm(5, 4)
  File C:\Python25\mod.py, line 27, in perm
q = a / b
TypeError: unsupported operand type(s) for /: 'NoneType' and 'NoneType'
 
I have no idea how to fix it.  I'm pretty new to Python.  I have IDLE 1.2.2 and 
Python 2.5.2,
 
Please help.
--
http://mail.python.org/mailman/listinfo/python-list


Error: UnboundLocalError: local variable 'PfFlag' referenced before assignment

2007-11-30 Thread Wang, Harry
$$ TestCase ID : 001
Step : deleteDvc,206268
Result Eval type : XmlChk
Step : deleteDvc,206269
Result Eval type : XmlChk
Traceback (most recent call last):
  File C:\UDR2\UDRxmlGateway.py, line 388, in module
ParseAll()
  File C:\UDR2\UDRxmlGateway.py, line 371, in ParseAll
if (PfFlag == 1):
UnboundLocalError: local variable 'PfFlag' referenced before assignment
 
 
PfFlag gets assigned in a for loop in line 365
for i in range(PfFlagArrSize):
if (PfFlagArr[i] == 1):
--- PfFlag = int(1)
break
else:
PfFlag = int(-1)

No idea what is going on here
 
Harry C. Wang
Sr. Test Engineer (Automation)
Phone 206 - 268 - 7502
temporary e-mail: [EMAIL PROTECTED] 
Personal e-mail: [EMAIL PROTECTED] 
Ciber EmpID # 36219
-- 
http://mail.python.org/mailman/listinfo/python-list


gnosis XML objectify

2007-11-26 Thread Wang, Harry
The gnosis xml libs should not be version specific, but when I try to use 
Python 2.5, I am getting not well formed (invalid token) errors. 

Harry

-- 
http://mail.python.org/mailman/listinfo/python-list


RE: gnosis XML objectify

2007-11-26 Thread Wang, Harry
Full Traceback enclosed:
 
Test Suite Started @ 2007-11-26 11:34:46.617000
Traceback (most recent call last):
  File C:\UDR2\UDRxmlGateway.py, line 370, in module
ParseAll()
  File C:\UDR2\UDRxmlGateway.py, line 286, in ParseAll
py_obj = gnosis.xml.objectify.XML_Objectify(InputFile).make_instance()
  File C:\python25\Lib\site-packages\gnosis\xml\objectify\_objectify.py, line 
160, in make_instance
o = self.ParseFile(self._fh)
  File C:\python25\Lib\site-packages\gnosis\xml\objectify\_objectify.py, line 
190, in ParseFile
self._myparser.ParseFile(file)
xml.parsers.expat.ExpatError: not well-formed (invalid token): line 68, column 0
 
Harry C. Wang
Sr. Test Engineer (Automation)
AOL Mobile
Phone 206 - 268 - 7502
temporary e-mail: [EMAIL PROTECTED] 
Personal e-mail: [EMAIL PROTECTED] 



From: [EMAIL PROTECTED] on behalf of [EMAIL PROTECTED]
Sent: Mon 11/26/2007 12:19 PM
To: python-list@python.org
Subject: Re: gnosis XML objectify



On Nov 26, 1:46 pm, Wang, Harry [EMAIL PROTECTED] wrote:
 The gnosis xml libs should not be version specific, but when I try to use 
 Python 2.5, I am getting not well formed (invalid token) errors.

 Harry

When does this happen? When you import the module? When you pass it
some xml? Do you have a full traceback?

Mike
--
http://mail.python.org/mailman/listinfo/python-list


-- 
http://mail.python.org/mailman/listinfo/python-list


RE: gnosis XML objectify

2007-11-26 Thread Wang, Harry
I can't tell where in the XML file it throws the error.
 
Here is the snippet of the Python code:
def ParseAll():
py_obj = gnosis.xml.objectify.XML_Objectify(InputFile).make_instance()

Harry C. Wang
Sr. Test Engineer (Automation)
AOL Mobile
Phone 206 - 268 - 7502
temporary e-mail: [EMAIL PROTECTED] 
Personal e-mail: [EMAIL PROTECTED] 



From: [EMAIL PROTECTED] on behalf of Sébastien Boisgérault
Sent: Mon 11/26/2007 12:21 PM
To: python-list@python.org
Subject: Re: gnosis XML objectify



On Nov 26, 8:46 pm, Wang, Harry [EMAIL PROTECTED] wrote:
 The gnosis xml libs should not be version specific, but when I try to use 
 Python 2.5, I am getting not well formed (invalid token) errors.

 Harry

Could you show us a simple example that exhibits this behavior
please ?

SB
--
http://mail.python.org/mailman/listinfo/python-list


-- 
http://mail.python.org/mailman/listinfo/python-list


gnosis XML objectify

2007-11-26 Thread Wang, Harry
Problem solved.   
 
I left out a right closing tag () in the XML, but I am having another 
problem. 
 
Harry C. Wang
Sr. Test Engineer (Automation)
AOL Mobile
Phone 206 - 268 - 7502
temporary e-mail: [EMAIL PROTECTED] 
Personal e-mail: [EMAIL PROTECTED] 
-- 
http://mail.python.org/mailman/listinfo/python-list


Environment Variables

2007-11-17 Thread Wang, Harry
Need some suggestions as to how to set environment variable in Windows XP.
 
Got XML which has a timestamp in Eastern Standard time, but would like to strip 
it out for comparison with expected result. 
 
Harry C. Wang
Automated Tester
AOL Mobile
-- 
http://mail.python.org/mailman/listinfo/python-list


Py2.5.1 on Ubuntu AMD X2, unicode problems

2007-09-11 Thread Harry George
I'm building 2.5.1 from source, using the ubuntu(7.0.4)-provided gcc
4.1.2.  Based on google searches and nints found, here is the process:


#---edit configure; test of wchar_t---
#include ncursesw.h
#include wchar.h
#-

cd Lib/test
rm test_multibyte*
cd ../..

#---edit Include/unicodeobject.h---
/* FIXME: MvL's new implementation assumes that Py_UNICODE_SIZE is
   properly set, but the default rules below doesn't set it.  I'll
   sort this out some other day -- [EMAIL PROTECTED] */
#define Py_UNICODE_SIZE 4
#ifndef Py_UNICODE_SIZE
#

LDFLAGS='-L/usr/lib -lncursesw -L/usr/local/ssl/lib -lssl -lcrypto ' \
./configure --prefix=/usr/local \
--with-gcc=/usr/bin/gcc \
--enable-shared \
--enable-unicode=usc4 \

#---edit Modules/Setup---
(all the std ones)
SSL=/usr/local/ssl
_ssl _ssl.c \
-DUSE_SSL -I$(SSL)/include -I$(SSL)/include/openssl \
-L$(SSL)/lib -lssl -lcrypto

#---end edits---

gmake altinstall


I'm getting a failure during final libpython binding, on undefined
PyUnicodeUCS4_AsWideChar.  All the other PyUnicodeUCS4... functions
are being found.  It specifically says it is checking on the libpython
in /usr/local/lib (not somewhere in the source code build dirtree), so
that is a possible oddity.  Checking with nm on the lib shows
AsWideChar is in fact undefined.


1. If I onfigure with unicode=ucs2, does all this go away and I get a
working system (efficient or not) on my 64-bit machine?

2. Can you point to a configure (and maybe patch) process which leads
to a clean make altinstall.


-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Python Database Apps

2007-09-11 Thread Harry George
Tom Brown [EMAIL PROTECTED] writes:

 On Monday 10 September 2007 19:52, [EMAIL PROTECTED] wrote:
 Kindof a poll, kindof curiosity...

 What is your favorite python - database combination?  I'm looking to
 make an app that has a local DB and a server side DB.  I'm looking at
 python and sqlite local side and sql server side.

 Any suggestions

 I have had a lot of good luck with PostgreSQL. It is easy to install and use. 
 It is also very stable. It maybe overkill for a client side database. The 
 psycopg package makes interfacing to PostgreSQL very easy and there is a 
 package for Linux and Windows to make cross-platform development a breeze.

 -Tom

I use postgresql as well.  I wonder if Pythonistas do so out of
concern for rigor, clarity, and scalability.  It works fine for a
quick one-off effort and still works fine after scaling to a DBMS
server supporting lots of clients, and running 10's of GBs of data.

If an app comes already designed for mysql, oracle, sqlite, db2, dbm,
etc I'll use those.  But for my own projects, it is postgresql, with
maybe SQLAlchemy (I'm back and forth on that.  Mostly stay with
straight SQL).

Of course, as long as you write DBI2 compliant code, your app doesn't
much care which DBMS you use.  The postgresql payoff is in admin
functionality and scaling and full ACID.

-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: SSL Issue

2007-09-06 Thread Harry George
Jurian Botha [EMAIL PROTECTED] writes:

 Sorry if this is a real dumb question, but I'm totally stumped.

 I'm trying to connect to a https url in order to do some xml-rpc method
 calls, but I'm getting the following error:

 Error Type: sslerror
 Error Value: (6, 'TLS/SSL connection has been closed')

 What could be causing this error, any clues would be greatly appreciated.

 Thanks
 -- 
 View this message in context: 
 http://www.nabble.com/SSL-Issue-tf4388062.html#a12510772
 Sent from the Python - python-list mailing list archive at Nabble.com.


I don't have a complete story, but here are some hints:

1. The message is from:
http://www.openssl.org/docs/ssl/SSL_get_error.html
(see ZERO RETURN)
probably as filtered by 
PyOpenSSL, which has its own issues:
http://mail.python.org/pipermail/python-dev/2007-August/074322.html

2. Chances are that your certificates are out of whack, or you are
misusing the SSL context parameters, or are not telling the HTTP
Connection object about the SSL Connection properly.

3. Debugging at the python layer is easier (put print statements in
M2Crypto's SSL/Context and SSL/Connection) but if necessary, dive into
openssl:
http://www.mail-archive.com/[EMAIL PROTECTED]/msg49287.html

4. You can check for the hello handshake using WireShark.

5. I haven't found a tutorial for full Python client/server over HTTPS
with verification of both client and server certificates.  If that is
where you are going, let me know what works.




-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Sip4.7

2007-09-06 Thread Harry George
luca72 [EMAIL PROTECTED] writes:

 Hello
 i have python2.5 with sip4.6 installed on a linux machine, i need to
 install sip4.7 but i get a lot of error like this:

 sip.h:525: error: expected specifier-qualifier-list before
 'PyMethodDef'
 sip.h:609: error: expected specifier-qualifier-list before
 'sipForceConvertToFunc'
 sip.h:666: error: expected specifier-qualifier-list before 'PyObject'
 sip.h:902: error: expected specifier-qualifier-list before
 'PyTypeObject
 sipint.h:81: error: expected '=', ',', ';', 'asm' or '__attribute__'
 before '*' token
 sipint.h:86: error: expected '=', ',', ';', 'asm' or '__attribute__'
 before '*' token
 sipint.h:87: error: expected '=', ',', ';', 'asm' or '__attribute__'
 before '*' token
 siplib.c:39: error: expected ')' before '*' token
 siplib.c:41: error: expected ')' before '*' token
 siplib.c:43: error: expected ')' before '*' token
 siplib.c:45: error: expected ')' before '*' token
 siplib.c:48: error: expected ')' before '*' token
 plib.c:285: error: expected specifier-qualifier-list before 'PyObject'
 siplib.c:290: error: expected '=', ',', ';', 'asm' or '__attribute__'
 before 'sipWrapperType_Type'

 Have you some idea why?

 Regards

 Luca


On Linux, py2.5 installed, sip 4.6 installed:

I just tried it using gcc/g++ 3.4.6 and and then a fresh start with
gcc/g++ 4.2.0.  Both worked fine.  If you have an older gcc/g++ that
might give the effect.

Notice that I have a wrapper to set paths for qt4, and a wrapper to
run python2.5.1.  These are for convenience and should not impact
results, unless of course you aren't makeing qt4 visible to the sip
compile process.

[sip-4.7]$ qt4 py25 configure.py
This is SIP 4.7 for Python 2.5.1 on linux2.
The SIP code generator will be installed in /usr/local/bin.
The SIP module will be installed in /usr/local/lib/python2.5/site-packages.
The SIP header file will be installed in /usr/local/include/python2.5.
The default directory to install .sip files in is /usr/local/share/sip.
The platform/compiler configuration is linux-g++.
Creating sipconfig.py...
Creating top level Makefile...
Creating sip code generator Makefile...
Creating sip module Makefile...
[EMAIL PROTECTED] sip-4.7]$ gmake
gmake[1]: Entering directory `/usr2/src/qt/sip-4.7/sipgen'
gcc -c -pipe -O2 -w -I. -o main.o main.c
gcc -c -pipe -O2 -w -I. -o transform.o transform.c
gcc -c -pipe -O2 -w -I. -o gencode.o gencode.c
gcc -c -pipe -O2 -w -I. -o export.o export.c
gcc -c -pipe -O2 -w -I. -o heap.o heap.c
gcc -c -pipe -O2 -w -I. -o parser.o parser.c
gcc -c -pipe -O2 -w -I. -o lexer.o lexer.c
g++  -o sip main.o transform.o gencode.o export.o heap.o parser.o lexer.o 
gmake[1]: Leaving directory `/usr2/src/qt/sip-4.7/sipgen'
gmake[1]: Entering directory `/usr2/src/qt/sip-4.7/siplib'
gcc -c -pipe -fPIC -O2 -w -I. -I/usr/local/include/python2.5 -o siplib.o 
siplib.c
gcc -c -pipe -fPIC -O2 -w -I. -I/usr/local/include/python2.5 -o qtlib.o qtlib.c
gcc -c -pipe -fPIC -O2 -w -I. -I/usr/local/include/python2.5 -o threads.o 
threads.c
gcc -c -pipe -fPIC -O2 -w -I. -I/usr/local/include/python2.5 -o objmap.o 
objmap.c
g++ -c -pipe -fPIC -O2 -w -I. -I/usr/local/include/python2.5 -o bool.o bool.cpp
g++ -shared -Wl,--version-script=sip.exp -o sip.so siplib.o qtlib.o threads.o 
objmap.o bool.o 
gmake[1]: Leaving directory `/usr2/src/qt/sip-4.7/siplib'


-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Issue with CSV

2007-07-19 Thread Harry George
Rohan [EMAIL PROTECTED] writes:

 Hello,
 I'm working on a script which collects some data and puts into a csv
 file which could be exported to excel.
 so far so good, I'm able to do what I described.
 When I run the script for the second time after a certain period of
 time the results should appear next to the results of the last run,
 I'm unable to make a new column when the script is run after the first
 time.
 Ideally I would like to have an output which looks like this.
 1/20   1/27
 we.pywe.py
 gh.pygj.py   - Indicating tht the file has changed
 fg.pyfg.py

 Please help me out.
 Thanks


We'd need to see code to tell what you are doing wrong.   The solution is 
pretty obvious:   

1. Model the needed structure, which is a 2D matrix of script x date.
Assuming the above output is the nromal case, this can be done with a
list of rows, each of which has a list of entries by date.

2. Write reader code which reads a csv and loads it into this structure.

3. Write writer code which writes this structure out to csv.

4. Write orchestration code to a) read the old csv, b) check the
loaded structure's data against the new data-on-disk to find changed
files, c) update the structure appropriately, d) write out the
resulting new csv.

-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: VB frontend to Python COM backend

2007-07-06 Thread Harry George
nik [EMAIL PROTECTED] writes:

 I have a VB6 application that I would like to attach to a python
 communications application.

 I have come across several discussions on using VB with a Python COM
 back-end, but no starting point. I haven't had anymore luck with
 google at finding out what this method is called and where to find
 more information or examples on it. I would really appreciate it if
 someone could point me in the right direction for using python objects
 from VB.

 Thank you,
 Nik


Search for python win32 book.   You want Python Programming on Win32
 By Mark J.. Hammond, Andy Robinson.  It covers exactly this case.

-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: eggs considered harmful

2007-06-26 Thread Harry George
[EMAIL PROTECTED] (John J. Lee) writes:

 Harry George [EMAIL PROTECTED] writes:
 [EMAIL PROTECTED] (John J. Lee) writes:
 [...]
 2. You can run your own private egg repository.  IIRC, it's as simple
 as a directory of eggs and a plain old web server with directory
 listings turned on.  You then run easy_install -f URL package_name
 instead of easy_install package_name .  The distutils-sig archives
 will have more on this.

 Again, not speaking for anyone else: With 500 OSS packages, all of
 which play by the same tarball rules, we don't have resources to
 handle eggs differently.

 You said earlier:

 The rules are that a) a very few authorized downloaders obtain
 tarballs and put them in a depot and b) other users get tarballs from
 the depot and build from source.

 Not sure how this differs significantly from running a repository,
 in the sense I use it above.


 John

Significant differences:

depot: Place(s) where tarballs can be stored, and can then be
reached via http.  

private egg repository: Tuned to the needs of Python eggs.  E.g.,
not scattered over several directories or several versions.

Thus a depot of self-contained packages can handle:

1. Multiple releases of the depot live at the same time.

2. Packages factored into CD-sized directories (not all in one -f location)

3. Multiple versions of Python, without having a new egg for each.


4. Multiple target platforms.  Various *NIX and MS Win and Mac systems
-- each at their own OS versions and own compiler versions.  All
without having platform-specific and compiler-specific eggs.

5. Different package version selections based on compatibility with
other (non-Python) packages.  E.g., to tune for GIS systems vs 3D
animation systems vs numerical analysis systems vs web server systems.

6. Refresh process which does not need to fiddle with egg-ness, or
even know about Python.  Everything is a tarball.


-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Setuptools, build and install dependencies

2007-06-25 Thread Harry George
Robert Kern [EMAIL PROTECTED] writes:

 Harry George wrote:

 We need to know the dependencies, install them in dependency order,
 and expect the next package to find them.  configure does this for
 hundreds of packages.  cmake, scons, and others also tackle this
 problem.  Python's old setup.py seems to be able to do it.  

 No, generic setup.py scripts don't do anything of that kind.


Ok, setup.py itself may not do the work, but from the end users'
perspective it works that way.  Setup.py runs a configure and a make,
which in turn find the right already-installed libraries.  The point
is, setup.py plays well in such an environment.


 -- 
 Robert Kern

 I have come to believe that the whole world is an enigma, a harmless enigma
  that is made terrible by our own mad attempt to interpret it as though it had
  an underlying truth.
   -- Umberto Eco


-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: eggs considered harmful

2007-06-22 Thread Harry George
[EMAIL PROTECTED] (John J. Lee) writes:

 Harry George [EMAIL PROTECTED] writes:
 [...]
  These are unacceptable behaviors.  I am therefore dropping ZODB3, and
  am considering dropping TurboGears and ZSI.  If the egg paradigm
  spreads, yet more packages will be dropped (or will never get a chance
  to compete for addition).
  
  I've asked before, and I'll ask again: If you are doing a Python
  project, please make a self-sufficient tarball available as well.  You
  can have dependencies, as long as they are documented and can be
  obtained by separate manual download. 
 
 1. Given the presumptuous tone of your own message, I guess I'm not in
 danger of coming across as more rude than you when I point out that
 your requirements are just that: your own.  The rest of the world
 won't *always* bend over backwards to support just exactly what you'd
 most prefer.
 

You deleted the ...at least here, which was intended to make clear I
was NOT speaking for the world at large, though possibly for a large
chunk of corporate life.  Also, this wasn't out of the lbue.  I ha ve
previously discussed this with several development teasm privately,
but the trend appears to be accelerating

 2. You can run your own private egg repository.  IIRC, it's as simple
 as a directory of eggs and a plain old web server with directory
 listings turned on.  You then run easy_install -f URL package_name
 instead of easy_install package_name .  The distutils-sig archives
 will have more on this.

Again, not speaking for anyone else: With 500 OSS packages, all of
which play by the same tarball rules, we don't have resources to
handle eggs differently.

 
 3. Alternatively, you could create bundled packages that include
 dependencies (perhaps zc.buildout can do that for you, even? not sure)
 

No resources for special handling.  

 
 John




-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: eggs considered harmful

2007-06-22 Thread Harry George
Robert Kern [EMAIL PROTECTED] writes:

 Harry George wrote:
  ...at least around here.
  
  I run a corporate Open Source Software Toolkit, which makes hundreds
  of libraries and apps available to thousands of technical employees.
  The rules are that a) a very few authorized downloaders obtain
  tarballs and put them in a depot and b) other users get tarballs from
  the depot and build from source.
  
  Historically, python packages played well in this context.  Install
  was a simple download, untar, setup.py build/install.
  
  Eggs and with other setuptools-inspired install processes break this
  paradigm.  The tarballs are incomplete in the first place.  The builds
  sometimes wander off to the internet looking for more downloads.  The
  installs sometimes wander off to the internet looking for
  compatibility conditions.  (Or rather they try to do so and fail
  because I don't let themn through the firewall.)
 
 Have you considered establishing a policy that these setuptools-using packages
 should be installed using the --single-version-externally-managed option to 
 the
 install command? This does not check for dependencies.

I didn't know that one.  I'll try it.  Thanks.

 
 Alternately, you can provide a company repository of the tarballs and their
 depedencies tarballs. Your users can use the easy_install option --find-links 
 to
 point to that URL such that they do not have to go outside of the firewall to
 install everything.
 

This is a possibility.  The tarballs can be seen in a directory
listing.  They are in different subdirs (for different bundles of
functionality), so I'll need -f to look several places.

  These are unacceptable behaviors.  I am therefore dropping ZODB3, and
  am considering dropping TurboGears and ZSI.  If the egg paradigm
  spreads, yet more packages will be dropped (or will never get a chance
  to compete for addition).
 
 I'm sorry to hear that.

Me too.  We worked long and hard to get Python established as a
standard language for corporate systems development, we have a host of
projects that need ZSI, and I look forward to making further inroads
into C++, Java, and VB development camps.  Didn't really need a
roadblock at this point.

 
  I've asked before, and I'll ask again: If you are doing a Python
  project, please make a self-sufficient tarball available as well.  You
  can have dependencies, as long as they are documented and can be
  obtained by separate manual download. 
 
 Given the options I outlined above, you can easily satisfy these requirements
 for the vast majority of setuptools-using packages that are out there. There 
 are
 a handful of packages that only distribute the eggs and not the source 
 tarballs,
 but those are rare.
 

I agree pure eggs are rare.  The fact that they increased this past
quarter was what concerned me.  ZODB even looks like a normal tarball,
builds ok, but uses a easy-install-style lookup during install.


 -- 
 Robert Kern
 
 I have come to believe that the whole world is an enigma, a harmless enigma
  that is made terrible by our own mad attempt to interpret it as though it had
  an underlying truth.
   -- Umberto Eco
 

-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Setuptools, build and install dependencies (was: eggs considered harmful)

2007-06-22 Thread Harry George
Ben Finney [EMAIL PROTECTED] writes:

 Harry George [EMAIL PROTECTED] writes:
 
  Historically, python packages played well in this context.  Install
  was a simple download, untar, setup.py build/install.
 
  Eggs and with other setuptools-inspired install processes break this
  paradigm.  The tarballs are incomplete in the first place.  The builds
  sometimes wander off to the internet looking for more downloads.  The
  installs sometimes wander off to the internet looking for
  compatibility conditions.  (Or rather they try to do so and fail
  because I don't let themn through the firewall.)
 
 If you provide the build and install script with all the dependencies
 already present (in the current directory), my experience is that
 setuptools does not do any network actions.
 
 -- 
  \   Self-respect: The secure feeling that no one, as yet, is |
   `\ suspicious.  -- Henry L. Mencken |
 _o__)  |
 Ben Finney

Thanks for the idea.  It doesn't work so well in our context, since
many dependencies are installed long before a particular egg is
attempted.  

We need to know the dependencies, install them in dependency order,
and expect the next package to find them.  configure does this for
hundreds of packages.  cmake, scons, and others also tackle this
problem.  Python's old setup.py seems to be able to do it.  

However, as I understand it, setuptools can't detect previously
installed python packages if they were not installed via eggs.  Thus,
my ZSI install was failing on PyXML=8.3, even though PyXML 8.4 is
installed.  I can't afford to drag copies of all the dependent source
tarballs into an egg's currdir just so it can find them.  (We have 6 GB
of tarballs -- who knows how much untarred source that would be.)

I just found hints that you should not attempt to install ZSI form
tarball, but should rather install from an egg.  So I was able to
install ZSI for py2.4.

Unfortunately, that means I would have to carry
python-version-dependent renditions of every egg.  We have people
running on py23, py24, and py25, thus tripling the number of
tarballs/eggs to manage.  This is the very reason we went to a
*source* based repository.

-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


eggs considered harmful

2007-06-21 Thread Harry George
...at least around here.

I run a corporate Open Source Software Toolkit, which makes hundreds
of libraries and apps available to thousands of technical employees.
The rules are that a) a very few authorized downloaders obtain
tarballs and put them in a depot and b) other users get tarballs from
the depot and build from source.

Historically, python packages played well in this context.  Install
was a simple download, untar, setup.py build/install.

Eggs and with other setuptools-inspired install processes break this
paradigm.  The tarballs are incomplete in the first place.  The builds
sometimes wander off to the internet looking for more downloads.  The
installs sometimes wander off to the internet looking for
compatibility conditions.  (Or rather they try to do so and fail
because I don't let themn through the firewall.)

These are unacceptable behaviors.  I am therefore dropping ZODB3, and
am considering dropping TurboGears and ZSI.  If the egg paradigm
spreads, yet more packages will be dropped (or will never get a chance
to compete for addition).

I've asked before, and I'll ask again: If you are doing a Python
project, please make a self-sufficient tarball available as well.  You
can have dependencies, as long as they are documented and can be
obtained by separate manual download. 

Thanks for listening. 

-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: The Modernization of Emacs

2007-06-19 Thread Harry George
Galen Boyer [EMAIL PROTECTED] writes:

 On Mon, 18 Jun 2007, [EMAIL PROTECTED] wrote:
 
  The problem with this line of thinking is that it aims to make Emacs
  appeal to people -- I think it is rather the other way around.
  Certain people appeal to Emacs:  certain kinds of people like Emacs
  and the way it is set up, and they change it to suit their needs.
 
 Emacs will always be for people who like to be able to constantly fiddle
 with their environments which continues to increase the efficiency with
 which they perform their tasks, increasing the # of tasks they can
 perform and therefore increasing the # of peers it would take to equal
 the amount of work they alone perform.  Most other environments will be
 for those just trying to perform their tasks and staying even with the
 average proficiency chart.
 
 -- 
 Galen Boyer

constantly fiddle

I've used emacs since the 1980's.  I've used it for text, xml, html
markups, programming in many languages, and natural languages.  In a
few cases I've fiddled with the environment.  I've even written a
mode.  But it has never been constantly.  One does the setup, and
then uses it day after day, year after year... until you have a new
need, in which case you re-tune your settings and then go back to
work.

trying to perform their tasks...average proficiency

Aye, there's the rub.  As Fred Brooks and others repeatedly point out,
there is little room in programming for average proficiency.

I don't mind folks using any editor they want, as long as they are
proficient.  In those cases, I have no problem doing Extreme
Programming with them -- code a bit, save, the other guy codes a bit.
But when someone uses vi and then forgets how to do block moves, or
uses eclipse and bogs down the session, or uses MS Notepad and can't
enforce language-specific indents, I get frustrated.

-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


RE: Using python for a CAD program

2007-05-29 Thread George, Harry G
I haven't followed up.   When I last looked, I found the problem space
is too large for one person (or project) to do it all.  So the job is to
glue together lots of good OSS tools -- which is a very pythonic task.
The absolute requirement for Knowledge-Based-Engineering is an API which
allows a script to do anything a human can do.   E.g.:

1. For 3D mechanical CAD, there is OpenCascade, with the pythonic
freecad frontend.
http://www.opencascade.org/
http://juergen-riegel.net/FreeCAD/Docu/index.php?title=Main_Page

OpenCascade requires registration and is big download.

2. For 2D mechanical CAD, there is PythonCAD  
http://www.pythoncad.org/
The explicit intent to provide full scriptability (anything a human can
do via the GUI, a script can do via the API).   

3. For EE schematics and simulation, there is OpenCollector and
specifically gEDA suite.   
http://opencollector.org/
http://www.geda.seul.org/
Not pythonic, but people have written glueware scripts in python to tie
the pieces together.

4. For fancy 3D objects and animations, Blender has the power and is
scriptable in python.   It comes from the world of animations, but the
math doesn't care if you do EE 3D models instead.
http://www.blender.org/

5. We should all be concerned over SGI selling the OpenGL patents to
Microsoft, so at least look to Mesa, and perhaps to alternative 3D
libraries.

6. I don't do GUIs much, but I understand form others that PyQT's
slot-and-signal architecture is well-respected, that *many* OSS projects
use PyGTK, and that folks who use wxPython are looking at wax as a
more pythonic layer.I finesse the whole issue by claimintg GUIs are
for humans to do the work.   I write code so computers can do the work.
:-).



 -Original Message-
 From: Dan Fabrizio [mailto:[EMAIL PROTECTED] 
 Sent: Saturday, May 26, 2007 3:46 PM
 To: python-list@python.org; George, Harry G
 Subject: Using python for a CAD program
 
 Hello,
 
 I saw your post from last year about using python for a EE 
 CAD program. What were your conclusions?  I'm thinking about 
 converting a Java CAD program I developed to Python with 
 wxPython and C.  I want to use C for the database storage and 
 manipulation and wxPython for the GUI and user scriptable interface.
 
 I have also done something like with Tcl/Tk and C but think 
 Python is much more modern and wxPython widgets look very 
 professional and OO programming is very important to me.
 
 What did you decide to do?   What language and what GUI 
 libraries did you
 pick?  
 
 I would appreciate any suggestions or advice.
 Regards,
  
 
 Dan Fabrizio
 ASIC Engineer
 Aviom Inc. 1157 Pheonixville Pike. 
 West Chester, Pa. 19380
 Phone 610 738 9005 ext. 292
 Fax   610 738 9950 
  
 
 
 
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Python ODBC

2007-04-30 Thread Harry George
[EMAIL PROTECTED] writes:

 On Apr 29, 11:34 am, Harlin Seritt [EMAIL PROTECTED] wrote:
  Is there a Python odbc module that will work on Linux? I have a jdbc
  connection to a DB2 server. I am looking hopefully for an open source
  solution and not a commercial one.
 
  Thanks,
 
  Harlin
 
 I would think the odbc module would work. We've used SQLRelay here at
 work too. Here's a link on the database modules for Python:
 
 http://www.python.org/topics/database/modules.html
 
 And here's a few links on db2 with Python:
 
 http://www-128.ibm.com/developerworks/db2/library/tutorials/db2linux/db2proj/updated/python_db2_interface.htm
 http://sourceforge.net/projects/pydb2/
 http://www-128.ibm.com/developerworks/edu/i-dw-db2pylnx-i.html
 
 Hope that helps.
 
 Mike
 

I've looked into it, but never got all the
way to a solution.  As I understand it:

1. The DBMS needs to support ODBC.   DB2 does, so ok.

2. You need a client side framework and driver.  Those are provided on
   MS Win platforms.  On *NIX platforms, unixodbc and iodbc are the
   main players.

   http://www.unixodbc.org/
   http://www.iodbc.org/

3. For *NIX you need python bindings.  This is where mxODBC has
   operated (e.g., with iodbc).  But there is an OSS effort at:
   https://sourceforge.net/projects/pyodb



-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Command-line option equiv of PYTHONPATH

2007-04-27 Thread Harry George
Antoon Pardon [EMAIL PROTECTED] writes:

 On 2007-04-27, James Stroud [EMAIL PROTECTED] wrote:
  Rajesh wrote:
  Hi,
  
  The '-Ipath' option adds the path to the list of directories that
  contains modules that can be included in a script. I can use it as #!/
  usr/bin/perl -Ipath_to_my_modules thereby not asking the user of
  the script to set the path_to_my_modules in their environment.
  
  Is there any equivalent command-line option to the python binary or a
  command-line version of PYTHONPATH?
  
  Regards
  Rajesh
 
  Why not just modify sys.path within the actual script?
 
 Maybe because he has multiple versions of modules he wants to test his
 script against.
 
 -- 
 Antoon Pardon


Here are some approaches we've used:

1. Write a small script which sets PYTHONPATH and then calls the app.
   Make a different script for each setup you need.

2. Use a small script to set a couple of envvars, which in turn are
   used to find the right config file, which has all the config
   decisions you want.

archtool_path= os.getenv('ARCHTOOL_PATH')
archtool_cfg = os.getenv('ARCHTOOL_CFG')
sys.path.insert(0,archtool_path)
import archtool
exec import archtool.%s as cfg % archtool_cfg


-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Numeric Soup

2007-03-28 Thread Harry George
Erik Johnson [EMAIL PROTECTED] writes:

 Robert Kern [EMAIL PROTECTED] wrote in message
 news:[EMAIL PROTECTED]
 
  http://www.scipy.org/History_of_SciPy
 
  numpy is the current array package and supercedes Numeric and numarray.
 scipy
  provides a bunch of computational routines (linear algebra, optimization,
  statistics, signal processing, etc.) built on top of numpy.
 
 Thank you.
 
 

Also see gsl and its python binding.
http://www.gnu.org/software/gsl/
http://sourceforge.net/projects/pygsl

-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Help in Placing Object in Memory

2007-03-27 Thread Harry George
Clement [EMAIL PROTECTED] writes:

 I am newbie to Python.. i want to know something..
 
 can i place an object in disk instead of placing in Main Memory...?
 
 If possible, can you please explain with some scripts...?
 
 can two python script share a common object?
 

For the CPU to use the object, it needs to be in RAM.  But it is
possible to save the RAM image onto disk, and then bring it back
later.  The common approach is called pickling, though there are
several variants on this:

 http://docs.python.org/lib/persistence.html


-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Scripting Visio using Python

2007-02-14 Thread Harry George
Paul Watson [EMAIL PROTECTED] writes:

 I would like to create some additional shapes in Microsoft Visio using
 the Python language.  It would appear that Visio can use any CLR
 language.  Has anyone done this?  Can I use the Python package from
 python.org, or must I use IronPython?

An alternative might be to work (cross-platform) wit the vxd (XML)
file format.  A good reader/writer for that would be handy.

-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: My python programs need a GUI, wxPython or PyQt4?

2007-01-24 Thread Harry George
Joshua J. Kugler [EMAIL PROTECTED] writes:

 Daniel wrote:
 
  I've downloaded both the wxPython and the PyQt4 package, and by the
  first impression I must say that the PyQt4 system had a very
  compelling presentation. From what I can understand from the feedback
  I've gotten so far is that the wxPython is a better choice when it
  comes to compability (with linux), and it's free even if I want to
  create applications and sell them.
  So, from what I understand I will have to go with PyQt4 since (from
  my understanding):
  1. I will not sell the applications I'm working with since they will
  only be used by the internal QA at a computer game company.
 
 Even that is getting on shaky ground, at least according to Troll Tech. 
 See: http://www.trolltech.com/developer/knowledgebase/190/  So, write it
 for internal use, and put up for distribution on your personal web site
 (pending company approval, of course).
 
 j
 
 -- 
 Joshua Kugler
 Lead System Admin -- Senior Programmer
 http://www.eeinternet.com
 PGP Key: http://pgp.mit.edu/  ID 0xDB26D7CE
 
 -- 
 Posted via a free Usenet account from http://www.teranews.com
 

There are several OSS suppliers that use GPL, and then try to define
its meaning.  They are welcome to comment on their understanding of
the GPL, but they do not have the authority to actually define its
legal ramifications.  Check with your company legal staff.

Having said that, I have been troubled by trolltech's approach from
the beginning, and therefore stay away from it.  PyGTK and wdxPython
are solid GUIs, without the legal uncertainty.


-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list

Re: Python does not play well with others

2007-01-24 Thread Harry George
John Nagle [EMAIL PROTECTED] writes:

The major complaint I have about Python is that the packages
 which connect it to other software components all seem to have
 serious problems.  As long as you don't need to talk to anything
 outside the Python world, you're fine.  But once you do, things
 go downhill.  MySQLdb has version and platform compatibility
 problems.  So does M2Crypto.  The built-in SSL support is weak.
 Even basic sockets don't quite work right; the socket module
 encapsulates the timeout mechanism but doesn't get it right.
 
In the Perl, Java, PHP, and C/C++ worlds, the equivalent
 functions just work.   That's because, in those worlds, either the
 development team for the language or the development team
 for the subsystem takes responsibility for making them work.
 Only Python doesn't do that.
 
Python has been around long enough that this should have
 been fixed by now.
 
   John Nagle

You experience isn't shared by everyone.  Some of us find Python the
most functional and portable of the candidates you mention.

Perl - excellent modules and bindings for just about everything you
can think of, but the whole thing is painful to watch.  Once you've
done a few code reviews on 10,000 line perl packages where even the
authors have no idea what the code is doing, you tend to look
elesewhere.

Java - a world of its own.  They reinvent the wheel instead of linking
to existing libraries.  In the process you get libraries upon
libraries upon libraries.  Even if there isn't a performance hit, you
(as a human) can get lost.  And the language is just too verbose to
live with.

PHP - are we talking web scripts or serious programs?  Are you doing
numerical analysis, NLP, computational chemistry, or bit twiddling in
PHP?

C - the portable assembler.  Solid, trusted, tunable performance,
bindings for everything.  Of course memory bugs can stop your project
in its tracks for indeterminant periods.

C++ - objects tacked onto C; but that didn't work so invent a whole
world of templates and rewrite everything again, but now trickier than
C to bind to other languages.  Good work can be done in C++, but that
is a testimony to the programmers and not to the language.

Python - it just works.  Same scripts run on every platform.  Bindings
available to every C/C++/FORTRAN library I've needed so far.  Often
the bindings are not complete, but oddly enough the binding developers
have chosen to do just the functions I need, so who cares.  A clean
architecture for adding more function bindings if I'm so inclined.

-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: My python programs need a GUI, wxPython or PyQt4?

2007-01-24 Thread Harry George
Chris Mellon [EMAIL PROTECTED] writes:

 On 1/24/07, Giovanni Bajo [EMAIL PROTECTED] wrote:
[snip]
 
  That page is legal babble, trying to trick you into buying (or making your
  boss buy) a commercial license. The Qt Open Source edition *IS* GPL and thus
  it falls under all the normal GPL clauses and uses, irrespective of what
  Trolltech may or may not think.
 
  For instance, see this FAQ:
  http://www.gnu.org/licenses/gpl-faq.html#GPLRequireSourcePostedPublic
 
  which makes pretty clear that a company/organization is basically the 
  same
  of an individual. Releasing a software within a company for internal 
  usage
  is by no means the same of releasing it to the public. Basically, for what
  the GPL is concerned, it is *not* a release or a distribution at all.
 
 
 I should point out that the FSFs position in this regard is not
 supported by copyright law and that the fact that Trolltech takes a
 different position is something that you should consider strongly. If
 the FSFs position were true, there would be no need for per-seat
 licensing of commercial software (because internal distribution
 wouldn't be). US copyright law does not draw a distinction between
 internal distribution and any other kind, and I'm not aware of any
 case law that does so either. This distinction is also not codified in
 the GPL itself anywhere, so it's not a necessary condition of the
 license - it is an interpretation by the FSF and that is all.
[snip]

It is all interpretation -- even after some cases have wandered
through the courts.  Mostly the trolltech statements indicate their
intent to sue.  That right there tells me I want to go elsewhere.


-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


RE: Python does not play well with others

2007-01-24 Thread George, Harry G
As always, IMHO...

P-code begat JVM, which begat .NET/Mono-CLI, wherein lives C#.   Thus it
is a deliberately isolated world, much given to reinventing wheels (or
rather recoding them) instead of binding to existing libraries.  So C#
might be a useful tool for anyone forced to live inside that world, but
more or less irrelevant for those who have to interact with the real
world. 

At work my tasks include hooking together lots of COTS tools, on lots of
platforms.  C# doesn't even play the game.

At home my hobbies include lots of different subjects, randomly passing
from one to another, using strictly Open Source Software, and enjoying
the process.  .NET/Mono and C# don't pass either the lots or the
enjoy tests.   

 -Original Message-
 From: egbert [mailto:[EMAIL PROTECTED] 
 Sent: Wednesday, January 24, 2007 10:05 AM
 To: George, Harry G
 Cc: python-list@python.org
 Subject: Re: Python does not play well with others
 
 On Wed, Jan 24, 2007 at 06:24:37AM +, Harry George wrote:
  
  Perl - excellent modules and bindings for just about everything ...
  Java - a world of its own.  They reinvent the wheel instead of ...
  PHP - are we talking web scripts or serious programs?  Are you ...
  C - the portable assembler.  Solid, trusted, tunable ...
  C++ - objects tacked onto C; but that didn't work so invent ...
  Python - it just works.  Same scripts run on every platform ... 
 
 What about C# ?
 e
 --
 Egbert Bouwman - Keizersgracht 197 II - 1016 DS  Amsterdam - 
 020 6257991 
 ==
 ==
 
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: on PySol's popularity

2006-12-19 Thread Harry George
Fredrik Lundh [EMAIL PROTECTED] writes:

 Tshepang Lekhonkhobe wrote:
 
  On Python docs, on faq/installed.html, it's mentioned that PySol is
  the most common Python application.
 
 not really; that page says that installing PySol is a common way to
 get a Python installation installed without noticing, not that PySol
 is in itself the most common Python application.
 
 and the entire python.org FAQ is horribly outdated.  we're working on
 a replacement, which is currently hosted here:
 
 http://effbot.org/pyfaq/installed-why-is-python-installed-on-my-machine.htm
 
 /F
 

A plug for PySol.

My wife is totally non-techno.  She doesn't get the notions of
windows, or minimize/maximize, or clicking on the icon down on the
toolbar.  But she does get PySol.  When I recently upgraded, I had to
reinstall Python2.2 in order to use the old PySol binaries (couldn't
get the build-from-source to work).

Linux and Python got a fan due to PySol. It should be considered a
cultural treasure, and if a bit of funding would help keep it rolling
into the future, that might be worthwhile.

-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Pyparsing troubles

2006-12-11 Thread Harry George
[EMAIL PROTECTED] writes:

 Hello,
 I have written a small pyparsing parser to recognize dates in the style
 november 1st. I wrote something to the effect of:
 
 expression = task + date
 
 and tried to parse Doctor's appointment on november 1st, hoping that
 task would be Doctor's appointment and date would be on november
 1st (the parser does match on november 1st to date). I have set
 task as Regex(.*?), ZeroOrMore(Word(alphas)), etc, but I can't get it
 to match, it matches everything to task and ignores date until it gets
 to the end of the string.
 
 Can anyone help?
 

As described, this is a Natural Language Programming (NLP) problem,
which means you will have a lot more trouble with understanding what
you want to do than in coding it.  Also, dates are notoriously tough
to parse, because of so many variants, so there are libraries to do
just that.

If you want to tackle it systematically:

1. Get a corpus of texts which illustrate the ways the users might
   state the date.  E.g., 2006-11-01, 1-Nov-06, November 1,
   Nov. first, first of November, 10 days prior to Veterans Day,
   next week, .

2. If you can control the input, much better.  Either by a form which
   forces specific values for day, month, year, hour, minute, or by
   requiring IETF format (-mm-ddThh:mm:ss).

3. Determine the syntax rules for each example.  If possible, abstract
   these to general rules which work on more than one example.

4. At this point, you should know enough to decide if it is a:

a) Regular expression, parseable with a regexp engine

b) Context Free Grammar (CFG), parseable with a LL(1) or LALR(1) parser.

c) Context Dependent Grammar, parseable with an ad hoc parser with special 
rules.

d) Free text, not parseable in the normal sense, but perhaps
understandable with statistical analysis NLP techniques.

f) Hodgepodge not amenable to machine analysis.

5. Then we could look at using pyparser.  But we'd have to see
   the pyparser code you tried.

-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: merits of Lisp vs Python

2006-12-11 Thread Harry George
[EMAIL PROTECTED] [EMAIL PROTECTED] writes:

 Kay Schluehr wrote:
 
  is rapidly replacing Perl, and Ruby is simultaneously and even more
  rapidly replacing Python. 

Really?  Given its small base, the percentage increases in Ruby use
(for any reason) can look quite impressive.  I've see data suggesting
Ruby is replacing Perl and maybe Java.  But I've yet to see data which
shows people dropping Python and moving to Ruby. Where do I find that
data?


-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: free, python XML merger?

2006-12-11 Thread Harry George
mistersulu [EMAIL PROTECTED] writes:

 All:
 
 We're looking for a python module which allows for quick merging of two
 XML files.  Both files follow the same schema.  One file contains the
 default values and structure, and the second file contains overriding
 data for the same tags.
 
 Thanks in advance,
 sulu
 

Sounds like a general XML problem, to be solved with cElementTree
perhaps.  Can you provide the schema and small examples of the input
files and the desired output file?

-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: I think Python is a OO and lite version of matlab

2006-12-08 Thread Harry George
Fredrik Lundh [EMAIL PROTECTED] writes:

 Allen wrote:
 
  It is not make sense to compare earth and basketball.
 
 why not?  they're both round, so surely they must have been inspired
 by each other.  the question is if humanity invented balls before we
 figured out that the earth is round, or if it's the other way around...
 
 /F
 

In keeping with the computer science flavor, we can say that no one
invented earth or balls to be round.  Rouindness is an emergent
behavior of a substance which has shape-forming adhesion and
shape-changing fluidity, and is subject to radially symmetric
shape-impacting processes.  Magma and gravity for the earth, leather
and air pressure for inflated balls, sand and accretion for beach
cannonballs, and snow and hand pressure for snowballs.

-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: merits of Lisp vs Python

2006-12-08 Thread Harry George
Mark Tarver [EMAIL PROTECTED] writes:

 Paul Rubin wrote:
  Mark Tarver [EMAIL PROTECTED] writes:
   How do you compare Python to Lisp?  What specific advantages do you
   think that one has over the other?
 
 http://google.com/search?q=python+lispbtnI=I'm+feeling+lucky
 
 Thanks;  a quick read of your reference to Norvig's analysis
 
 http://norvig.com/python-lisp.html
 
 seems to show that Python is a cut down (no macros) version of Lisp
 with a worse performance.  The only substantial advantage I can see is
 that GUI, and Web libraries are standard.  This confirms my suspicion
 that Lisp is losing out to newbies because of its
 lack of standard support for the things many people want to do.
 
 Mark
 

It is not just a newbie thing.  Even people who are reasonably fluent
in Lisp use Python for many tasks, and some make python the default
with Lisp as a special case.  It would probably be fair to say that
the more you know about a variety of languages, the more you
appreciate Python.


-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Pimping the 'cgi' module

2006-12-04 Thread Harry George
robert [EMAIL PROTECTED] writes:

 Harry George wrote:
  When I came from Perl, I too missed perl-isms and specifically CGI.pm, so 
  wrote my own:
  http://www.seanet.com/~hgg9140/comp/index.html
  http://www.seanet.com/~hgg9140/comp/pyperlish/doc/manual.html
  http://www.seanet.com/~hgg9140/comp/cgipm/doc/index.html
  Others on this newsgroup said I'd be better off just doing it in raw
  python.  After a while, I realized that was true.  You do
  triple-quoted templates with normal python idioms.  Throw in
  some persistence mechanisms to deal with maintaining state across
  transactions, and you are in business.
  Since then I've looked at Zope, Plone, TurboGears, Django, and (for
  standalone apps) Dabo.  TurboGears is mostly a set of recommendations
  on what 3rd party packages to use, with a wee bit of glueware.  So far
  nothing feels as simple as just doing it in python.
 
 
 Thats the fragmented journey, almost any web programmer has to go when coming 
 to python. A clear standard, even a clear intro, for simple tasks,  like 
 doing state mng, db, error handling, etc. is not there on an easy path.
 
 For a level above cgi, what do you think about cherrypy ?  
 http://docs.cherrypy.org/
 
 Robert

I have only done hello, world stuff in cherrypy.  We do everything
from apache, so the server part of cherrypy wouldn't be needed, and
getting to it from a mod_rewrite would just be extra hassle.

Mostly we do model-view-controller, were the view may be batch,
commandline, desktop gui, GUI, SOAP, etc. If it works with a simple
coded-by-hand CGI, that's all we do.

-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Pimping the 'cgi' module (was: Re: python gaining popularity according to a study)

2006-11-30 Thread Harry George
, and (for
standalone apps) Dabo.  TurboGears is mostly a set of recommendations
on what 3rd party packages to use, with a wee bit of glueware.  So far
nothing feels as simple as just doing it in python.

-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list

Re: Will GPL Java eat into Python marketshare?

2006-11-16 Thread Harry George
Fredrik Lundh [EMAIL PROTECTED] writes:

 Maurice LING wrote:
 
  I admit that it is very very unlikely. I guess it is just a wild
  dream of mine to run Java bytecodes and Python bytecodes on Python
  VM. I do have a wild vision that we can import java libraries (as
  jar files) into CPython.
 
 http://sourceforge.net/projects/jpype
 
 /F
 


Personally, I've never gotten jpype to work.  Is it just me, or is it
a troublesome install?


-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Will GPL Java eat into Python marketshare?

2006-11-16 Thread Harry George
Dennis Lee Bieber [EMAIL PROTECTED] writes:

 On Wed, 15 Nov 2006 22:41:19 GMT, Maurice LING [EMAIL PROTECTED]
 declaimed the following in comp.lang.python:
 
  
  I'm hoping for a more optimistic outcome that this may open a 
  possibility for tigher interoperability between java programs and python 
  programs. That is, run java class files or java codes natively on python 
  VM. Is this still a blue sky dream?
 
   Most unlikely to happen... I don't really see anyone going to the
 effort to change the javac back-end to target a totally different
 runtime engine. 
 -- 
   WulfraedDennis Lee Bieber   KD6MOG
   [EMAIL PROTECTED]   [EMAIL PROTECTED]
   HTTP://wlfraed.home.netcom.com/
   (Bestiaria Support Staff:   [EMAIL PROTECTED])
   HTTP://www.bestiaria.com/

I once wrote a partial JVM in Modula-3 (strictly a researchware
effort), so I can imagine it being done technically.  But why?

The big problem with Java-and-Python is not the VMs underneath.  It is
the fact that Java has layers upon layers upon layers of idiosyncratic
libraries and idioms.  When you write bindings to that world (even if
the bindings are generated automagically), you have to *think* in
those same layers.  The Python-oriented developer suddenly has to use
a dozen imports in order to do things already done better in
Pythonesque libraries.

-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Will GPL Java eat into Python marketshare?

2006-11-15 Thread Harry George
walterbyrd [EMAIL PROTECTED] writes:

 Some think it will.
 
 Up untill now, Java has never been standard across different versions
 of Linux and Unix. Some think that is one reason that some developers
 have avoided Java in favor of Python. Now that Java has been GPL'd that
 might change.
 
 IMO: it won't make much difference. But I don't really know.
 

Short answer: People use Python instead of Java because people (at
least intelligent people) tend to avoid pain.

Long answer: Changing licenses doesn't magically change Java's
architecture.  It is still a closed world of reinvent-the-wheel,
my-way-or-the-highway.  Which is antithetical to Python's promiscuous
interface-with-anything approach.

-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Python development time is faster.

2006-11-13 Thread Harry George
Chris Brat [EMAIL PROTECTED] writes:

 I've seen a few posts, columns and articles which state that one of the
 advantages of Python is that code can be developed x times faster than
 languages such as Insert popular language name here.
 
 Does anyone have any comments on that statement from personal
 experience?
 How is this comparison measured?
 
 
 Thanks
 Chris
 

Personal experience takes two forms.

1. Broad experience with languages, such that doing a single project
   in a new language gives a sense of the relative power and
   ease-of-use.  Everyone I know who is a strong Python supporter took
   that route.  There was an Ahh-Ha experience part way into the first
   project.  This includes folks who could charitably be called
   curmudgeons, and people who are truely fluent in, say, C++ or Lisp.

   For these people the main success factor is that it just works.
   You spend time on new functionality, or experimenting with
   alternative algorithms, not on debugging.  Of course, we work in a
   regression-test-driven world, so we don't pile up a lot of untested
   code and then hope for the best.  Python facilitates that
   test-early-test-often approach with its modularity and fast
   edit-run cycle.

2. Write the same thing in 2 or more languages.  Due to machine
   migrations and project redirections I have done that with
   perl-and-python, java-and-python, modula3-and-python,
   lisp-and-python.  In all cases, python was the second language, so
   there is some learning curve to be adjusted for (i.e., I understood
   the semantics better).  However, since I've done some
   perl-and-perl, and lisp-and-lisp, I can maybe make that adjustment.

   The result was that python was relatively faster-to-develop.  I
   can't give a specific speedup factor, but I sure can say Python is
   now my default language.  The success factors were:

   a) Once you get the hang of the language (a weekend?), you can
   write without reference to the manuals.  Or if you do reference, it
   is a quick lookup.  No struggling to figure out how to code
   something.  Or to decypher what a line of code actually does.

   b) The project doesn't bog down as you add features.  The language
   can accomodate new paradigms, patterns, or major functionality.  If
   you do need to refactor, that is easy too.  

   c) Peer code reviews are easy -- both you and the reviewers can
   understand the code's intent at a glance.


-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


manual eggs downloads?

2006-11-10 Thread Harry George
eggs are wonderful for no-hassle get-all-the-dependencies.  However,
they can trigger hands-off downloads from various sites.  This is Bad
News for corporate environments in which every download is carefully
pre-approved.

A tarball with a subdirectory of third_party packages is ok.  A web
page simple listing the third party sites and the recommended
downloads is ok.  Automatically downloading is not ok.

Is there some way in the eggs mechanism to just get a list of the
proposed downloads, and let the user take the actions manually?

-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Python tools for managing static websites?

2006-10-31 Thread Harry George
Walter Dörwald [EMAIL PROTECTED] writes:

 Chris Pearl wrote:
 
  Are there Python tools to help webmasters manage static websites?
  
  [...]
 
 You might give XIST a try: http://www.livinglogic.de/Python/xist/
 
 Basically XIST is an HTML generator, that can be extended to generate
 the HTML you need for your site. The website
 http://www.livinglogic.de/Python/ itself was generated with XIST. You
 can find the source for the website here:
 http://www.livinglogic.de/viewcvs/index.cgi/LivingLogic/WWW-Python/site/
 
 Hope that helps!
 
 Bye,
Walter Dörwald

1. If the static page can be autogenerated (e.g., from a data file or
   from an analysis), the best bet is to just write the html directly.
   Typically do as triple quoted text blocks with named variable
   substitutions, then print them with the substitutions filled.  The
   chunks are dictated by the structure of the problem (e.g.,
   functions for beginning and end of html page, for beginning and end
   of a form, for repeating rows in a table, etc.)  Just structure the
   app reasonably and put in the chnks where needed.

   NOTE -  When I first moved from Perl to Python, I thought I'd need
   CGI.pm, so I did cgipm.py:
   http://www.seanet.com/~hgg9140/comp/index.html
   http://www.seanet.com/~hgg9140/comp/cgipm/doc/manual.html

   However, I (and others in this newsgroup) recommend the
   write-directly approach instead.

2. If there must be human-in-the-loop, then it is good to use a markup
   language which can be converted to html (or to other backends).
   Perrl's POD format is one, and I've done that as a Pdx.

   http://www.seanet.com/~hgg9140/comp/index.html
   http://www.seanet.com/~hgg9140/comp/pdx/doc/manual.html


-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list

Re: What's the best IDE?

2006-10-26 Thread Harry George
John Salerno [EMAIL PROTECTED] writes:

 Neil Cerutti wrote:
  On 2006-10-26, John Salerno [EMAIL PROTECTED] wrote:
  [EMAIL PROTECTED] wrote:
  as I have yet to try Vim - maybe I'll try tomarrow.
  Warning: Vim isn't something you just try tomorrow  :)
  You can become proficient enough for basic editing in about 20
  minutes with the built-in tutorial.
  Getting it to work seemlessly with Python code will take
  considerably longer.
 
 
 Yeah, it was all the customizing that I could never figure out.

years ago this worked for people I was supporting:
 set softtabstop=4 shiftwidth=4 expandtab

Personally, I'm an emacs guy, so I wouldn't know.

-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Python to use a non open source bug tracker? - Trac?

2006-10-04 Thread Harry George
Fredrik Lundh [EMAIL PROTECTED] writes:

 Steve Holden wrote:
 
  But sadly people are much happier complaining on c.l.py than exerting
  themselves to support the community with an open source issue tracker.
 
 you're not on the infrastructure list, I hear.  python.org could still need a
 few more roundup volunteers, but it's not like nobody's prepared to con-
 tribute manhours.  don't underestimate the community.
 
 /F 
 
 
 

I'm not on the infrastructure list either.  But I wonder why it is
Roundup or else non-python COTS?  I gave up on Roundup a while ago
due to too many crashes.  I'm now using Trac:

a) Open Source
b) Python
c) Adequate functionality (for me at least)

http://trac.edgewall.org/

I'm not trying to sell Trac, but I would like to know what drove the
developers away from it.

-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Python form Unix to Windows

2006-08-17 Thread Harry George
Simon Forman [EMAIL PROTECTED] writes:
[snip]
 Simplest way: Run the app in windows, see what breaks (probably less
 than you might think), fix it.
 
 I have written large apps that required less than a dozen, or no,
 changes to move between windows and *nix.  YMMV
 
 Peace,
 ~Simon
 

I agree with this-- just try it.  When I've helped others move code, I
found the biggest problem was when they had hardcoded file paths instead of
using os.path mechanisms.

-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: excel in unix?

2006-08-11 Thread Harry George
[EMAIL PROTECTED] [EMAIL PROTECTED] writes:

 [EMAIL PROTECTED] wrote:
  hi
  is it possible to create excel files using python in Unix env?
  if so, what module should i use?
  thanks
 
 Depending on the complexity of your data you might find the csv module
 useful.  It allows you to write comma separated value (.csv) files that
 Excel reads just fine.
 

We use the csv module a lot.  I've also investigated the old DIF and
SLK formats for slightly more functoinality.  But the coming
standards-based world, if you need more than csv, start writing to to
the OpenOffice.org formats, either with your own code or via PyUNO.
Then use OOo itself or a MS-sponsored ODF reader to translate to Excel
format.  This should be a maintainable approach over time (but a lot
more complex than just csv).

-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Python Projects Continuous Integration

2006-07-28 Thread Harry George
Dave Potts [EMAIL PROTECTED] writes:

 Hi,
 
 I'm just starting a development project in Python having spent time in
 the Java world.  I was wondering what tool advice you could give me
 about setting up a continuous integration environment for the python
 code: get the latest source, run all the tests, package up, produce the
 docs, tag the code repository.  I'm used to things like Maven and
 CruiseControl in the Java world.
 
 Cheers,
 
 Dave.
 

First, sorry to hear you have had to use Java. You should recover
after a few months in Python.  Second, welcome to Python.  Third, some
of us emacs as our IDE.

I presume you often have several packages open at once, each with its
own regression tests, own documentation, and own CVS or SVN module.
You may also have multiple coding languages going at once (e.g.,
Python, C, C++, FORTRAN, Lisp, PROLOG).  Doing this in emacs:

1. Make a separate instance for each package being edited.  In the
   instance make separate frames for a) code buffers, b) test case
   buffers, c) doc buffers.  In the test frame, make a shell window
   where you can run go_test, thus running your testsuite for that
   package.  In the doc frame, make a shell window where you can run
   go_doc.  (Must of couse have written those go_ scripts, also done
   in emacs of course.).  

   If there are too many things happening for one desktop, run each
   package in a separate desktop (you are working in an OS which has
   virtual screens, right?).

2. Do CVS checkin/checkout in tool of your choice.  Emacs can do it. I
   prefer tkcvs, with editor set to emacs and diff set to emacs's'
   ediff.  Personal preference.

3. Do documentation in the tool of your choice.  Emacs can support
   pretty much any natural language, and has markups for just about
   any markup mechanism (SGML, XHTML, etc.).  I use my own Pdx, edited
   in emacs, and thus autogenerate HTML, PDF, LaTeX, etc.  Again,
   personal preference.  At a minimum, use some mechanism which allow
   autogeneration of documentation, auto inclusion of code snippets,
   and hyperlinking.  Since the go_doc is run in an emacs shell, use
   alt-P-return to rerun the line.  Redocumenting is thus a 2
   keystroke effort.

4. Do testing using a batch go_test script, running a suite built from
   unittest.  As needed, write debug statements to another buffer in
   that frame, where you can use full emacs functionallity to search
   it.  Since the go_test is run in an emacs shell, use alt-P-return
   to rerun the line.  Retesting is thus a 2 keystroke effort.

5. Oh, yes, coding.  Emacs's python-mode.el works fine.  Colorize or
   not as you see fit.  There are ways to set up code-completion, but
   personally I never do it.  You can setup etags but I never do --
   emacs search and grep-find do what I need.  Personal preference.

6. Use exactly the same setup for language after language, decade
   after decade, platform after platform.  Use your brain cells form
   something useful, like learning new technologies and new
   algorithms.


-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: json implementation

2006-07-25 Thread Harry George
jon cashman [EMAIL PROTECTED] writes:

 Hi everyone,
 
 Is there a doc comparing different json implementation (example:
 python-json, simplejson)? Does anyone have a strong recommendation
 to make? Any problem/issue for a particular implementation?
 
 Thanks.
 
 - jon
 
 _
 Is your PC infected? Get a FREE online computer virus scan from
 McAfee®
 Security. http://clinic.mcafee.com/clinic/ibuy/campaign.asp?cid=3963
 

I don't know personally, but TurboGears uses json-py.
https://sourceforge.net/projects/json-py/
  
-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list

Re: Project organisation

2006-07-19 Thread Harry George
rony steelandt [EMAIL PROTECTED] writes:

 Imagine I have x projects and they all use util.py
 
 What would be the best way to organise this
 
 1.
 c --\project1\*.py
   |
   |-\project2\*.py
   |
   --\globals\util.py
 
 This organisation has the problem that if I have to modify something to
 util.py that I need in project2, I'll have to retest project1 to make sure
 it still works (that could be project 1..n). 
 
 2.
 A copy of util.py in each project directory ? The advantage is that I can
 modify each util.py in function of the need of the project but it looks
 clutered, having n versions of util.py.
 
 What is the best solution ? or is there another even better solution ?
 
 Rony
 

Is util.py supposed to do the same thing wherever it is used?  No
one can answer that for you.  Your comments suggested mostly the same,
but some differences.  In that is the case, then use one main util.py
for the common items, and do a local util.py for the locally-specific
items.  Given proper attention to paths, there should be no confusion.

I wouldn't bury the common util.py in a package called globals.
That could get really confusing.  You might make it a standalone
package, or maybe use utilities or common.


-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: [OT] Prolog and Regular Expressions, Was: Re: perspective on ruby

2006-06-29 Thread Harry George
Kenneth McDonald [EMAIL PROTECTED] writes:
[snip]
 
 That said, it'd be nice if there were some easy way to access a Prolog
 engine from Python. When Prolog is appropriate, it's _really_
 appropriate.
 
 
 Cheers,
 Ken
 

http://christophe.delord.free.fr/en/pylog/
http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/303057
http://www.ibiblio.org/obp/py4fun/prolog/prolog2.html
http://sourceforge.net/projects/pyprolog/

Also, before these showed up, we locally did prolog-calls-python and
python-calls-prolog (all from a C++ CAD engine) by using the embedding
libraries and bindings.

-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Python question

2006-06-25 Thread Harry
Hi All,
  It is nice to join the python group. Can someone please help me with
a python question?
I have the following object which is like a list of tuples
What command do I use to get the value corresponding to 'min'?
This object seems to be non-indexable


row= [('name', 'x1'), ('min', 15.449041129349528), ('max',
991.6337818245629), ('range', 976.18474069521335), ('mean',
496.82174193958127), ('stddev', 304.78275004920454), ('variance',
92892.524727555894), ('mode', '46.5818482111'), ('unique_count', '99'),
('count', 99.0), ('count_missing', 0.0), ('sum_weight', 99.0)]

Thanks,
Harry

-- 
http://mail.python.org/mailman/listinfo/python-list


Re: How to link foreign keys primary keys using python?

2006-06-09 Thread Harry George
sonal [EMAIL PROTECTED] writes:

 Hi all,
 I hv started with python just recently... and have been assigned to
 make an utility which would be used for data validations...
,snip]
 plz help me... till get my hands on python... :)
 

1. This sure looks like a school assignment.  

2. till get my... Do you actually not have python installed yet?  It
   is hopeless to tackle this problem if you haven't done a few simple
   hello, world tasks.  

3. Do you have a data model?  In this case, you need to think
   carefully about what a RDBMS, PK, and FK are.  In otherwords, a
   metamodel.  Generally, once you understand the data structures you
   should implement them pretty much verbatim in a model module.
   Then do reader/writer modules so you can load that model from your
   data sources and dump out to your data sinks.

4. Do you have a testsuite and test harness?  Put together your test
   harness, then develop for the simplest case, then add complexity.
   E.g., no FK, FK with 1 attr, FK with multiple attrs, FKs with
   shared attrs.


-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Open Source Charting Tool

2006-06-05 Thread Harry George
A.M [EMAIL PROTECTED] writes:

 Hi,
 
 
 
 I developed a HTML reporting tool that renders Oracle data to HTML and 
 Oracle.
 
 
 
 At this point I have to add charts (3d bars and pie charts) to this 
 application. I don't think that I have to do it from scratch.
 
 
 
 Is there any open source charting tool that help me create charts in JPG or 
 gif format?
 
 
 
 Thanks,
 
 Alan
 
 

See pygdchart
http://www.nullcube.com/software/pygdchart.html

-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: How do you practice Python?

2006-06-01 Thread Harry George
Ray [EMAIL PROTECTED] writes:

 bruno at modulix wrote:
   In our field, we don't always get to program in the language we'd like
   to program. So... how do you practice Python in this case? Say you're
   doing J2EE right now.
 
  Hopefully not !
 
 I am :-(
 
   How do you practice Python to keep your skills
   sharp?
 
  How *would* I do ? Well, perhaps I'd use Jython ?
 
 Um, I mean, what if you have to use something other than
 Python/Jython/IronPython? :) How do you keep your Python skill sharp?
 
  --
  bruno desthuilliers
  python -c print '@'.join(['.'.join([w[::-1] for w in p.split('.')]) for
  p in '[EMAIL PROTECTED]'.split('@')])
 

Do projects at home.  Either find an existing OSS project, or roll
your own.  Once you have the basics of the language, the skills are
domain-specific: XML, GUIs, CAD, gaming, multithreading, numerical
analysis, natural language progromming, etc.

If you do an existing project, then you benefit from peer reviews and
other informal learning opportunities.

-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Programming language productivity

2006-05-19 Thread Harry George
malv [EMAIL PROTECTED] writes:

[snip]
 Once you get involved in larger projects, the dynamic nature of the
 programming tool becomes much more important. I mean by this, the
 ability to stop running code, modify or add to it and continue without
 having to re-establish the state of the program. This may sound trivial
 to many, but in major applications setting up the state again can take
 a considerable processing time. Such feature should be available from
 within the debugging tools.
 
 In fact, languages like Smalltalk, Lisp and even VB offer this
 possibility.
 Ruby coming up strongly these days also has this dynamic reload
 capability.
 To sum up, I like Python very much but I don't understand how come this
 basic flaw has not been taken care of. It is sufficient to search for
 reload to see how many people have struggled with it over the years.
 I hate the idea of having to take up Ruby to really find out how it
 could serve me better in this most critical productivity area.
 

What is major project?  

We have 50 people working on a project, over 5 years, in Python.  Much
of the regresison test can be done by rebuilding context in RAM (no
need to persist).  That is immediate (whole test suite runs in a few
seconds).  Sometimes we have to reestablish context by clearing the
database and then reloading objects from test_input XML files.  That
is slow (perhaps an over night job).  I've yet to experience a context
where language features are the rate limiting step.

On the other hand, I have definitely experienced language as a rate
limiting factor in a) peer code reviews, b) debugging, c) ramping up
new team members.  Python wins those battles everytime.

-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Using python for a CAD program

2006-05-16 Thread Harry George
.  Nothing wrong with reinventing a
few wheels, but I always like to start with a literature search.  It
wasn't clear if you had done so.  At a minimum, take a look at:

1. OSS EE suites:
http://www.opencollector.org/
http://www.geda.seul.org/

I don't see rewriting ngspice or Icarus Verilog -- people of people
doing that.  Putting a good DBMS behind gscheme on the other hand
makes sense.  Also, I write Python scripts around geda and there has
been discussion of embedding Python.


2. Databases: 

Locally, we have struggled with various DBMSs.  It seems OO is
mandatory, so I look to Postgresql with inheritance, or (smaller
scale) ZODB.  I really wouldn't want to grow one from B+ trees.

http://www.postgresql.org/
http://www.zope.org/Products/StandaloneZODB

3. 2D CAD and game engines:
http://directory.fsf.org/PythonCAD.html
http://pygame.seul.org/news.html

4. 3D CAD

Locally we write Python code against several commercial CAD packages
(I agree with your assessment).  For an OSS effort, the only game in
town seems to be: 
http://www.opencascade.org/
http://free-cad.sourceforge.net/

5. Knowledge Based Engineering (KBE) inference engines:

Python already gives you lazy evaluation and memoizing, but a
prolog-based backward chaining engine helps too.  We wrote
CAD-engine-calls-python-and-prolog and
python-and-prolog-calls-CAD-engine scripts.
 
http://sourceforge.net/projects/pyprolog/
http://christophe.delord.free.fr/en/pylog/
http://arts.anu.edu.au/linguistics/People/AveryAndrews/Software/AmziPy/Doc/manual.pyfrompro.html
http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/303057

6. Simulation

http://simpy.sourceforge.net/

Also need FEM for electromagnetic analysis, and CFD for heat
dissapation.


-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Tabs versus Spaces in Source Code

2006-05-15 Thread Harry George
Edward Elliott [EMAIL PROTECTED] writes:

 Eli Gottlieb wrote:
 
  Actually, spaces are better for indenting code.  The exact amount of
  space taken up by one space character will always (or at least tend to
  be) the same, while every combination of keyboard driver, operating
  system, text editor, content/file format, and character encoding all
  change precisely what the tab key does.
 
 What you see as tabs' weakness is their strength.  They encode '1 level of
 indentation', not a fixed width.  Of course tabs are rendered differently
 by different editors -- that's the point.  If you like indentation to be 2
 or 3 or 7 chars wide, you can view your preference without forcing it on
 the rest of the world.  It's a logical rather than a fixed encoding.
 
 

[snip]

This has been discussed repeatedly, and the answer is If you only
work alone, never use anyone else's code and no one ever uses your
codes, then do as you please.  Otherwise use tab-is-4-spaces.

When you do Agile Programming with people using emacs, vim, nedit,
xedit, wordpad, eclipse, and who knows what else, the 4-spaces rule is
necessary for survival.

The reason is simple: People get confused, and accidentally get the
wrong tab indents when they move among editors or among settings on
the same editor.  In most languages this is an irritation, requiring
some cleanup.  In Python it is a disaster requiring re-inventing the
coded algorithms.


-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: An Atlas of Graphs with Python

2006-05-02 Thread Harry George
Paddy [EMAIL PROTECTED] writes:

 A little off topic I'm afraid Giandomenico,
 But I had to smile. Here is someone working in the field of
 linguistics, who wants a programming solution, in the language Python.
 (It's Larry Wall,  creator of Perl that cites his linguistic
 foundations).
 
 -- Pad.
 

I used Python for computational linguistics coursework, but not since.  Google 
for nlp python.  E.g.: 

http://nltk.sourceforge.net/
http://www.logilab.org/projects/hmm
http://www.cs.berkeley.edu/~russell/aima/python/nlp.html


-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Looking for resources for making the jump from Java to Python easier and more productive

2006-04-24 Thread Harry George
Lawrence D'Oliveiro [EMAIL PROTECTED] writes:

 In article [EMAIL PROTECTED],
  ToddLMorgan [EMAIL PROTECTED] wrote:
 
 Are there python specific equivalents to the common Patterns,
 Anti-Patterns and Refactoring books that are so prevalent as
 reccomended reading in C++ and Java?
 
 I don't think they exist. Such books are targeted more towards 
 development in a corporate environment, where every proposal has to go 
 through multiple layers of management, and nothing is ever done by 
 individuals working alone, always by teams working on separate parts 
 of the project. And also where the end-users don't really get much say 
 in how things are supposed to work. It's only in such a high-overhead, 
 top-down, cover-your-ass environment that such books are looked on as 
 being at all useful. Possibly on the grounds that nobody ever got fired 
 for buying them.
 
 I'd say languages like Python and Perl are the absolute antithesis of 
 this sort of development culture.

On antithesis comment:

Python can be used for Agile Programming, with the end user there at
the monitor.  But it can also be used for heavy duty development
regimens with data models, specifications, development teams working
multiple shifts or working worldwide, separate test-and-release teams,
etc.

On response to the OP:

The most important thing you bring to the table is knowledge of data
formats, algorithms, OO programming, and test-driven design. E.g.,
XML, HTML, LDAP, SQL, pipes, stacks, queues, threads, dictionaries,
lexers, parsers, regular expressions, matrix transformations, GUI
dialogs, etc.  Many of us consider Python a secret weapon in learning
new paradigms and technologies

The most important things you need to leave behind:

1.  Intuition about what is already available vs what you have to
write.  Java tries to reinvent the whole compsci world.  Python just
says Nice C/C++/FORTRAN library; I think I'll use it via a binding.
If it is codable, it is probably scriptable in Python.

2. Temptation to reinvent entire stacks of libraries to replicate the
Java module import structure.  This is a real problem in migrating
existing code.  You have to take deep breath and ask What is the
fundamental task, and how would a programmer do that in Python?
Entire library trees melt away when you do this.

3. Fear you are missing something when you get done.  Python takes
c. 1/3 as many LOC as Java for the same task. At first I kept saying:
This wee bit of code couldn't posssibly do the whole job, could it?
If you have a good regression test suite, you are done when it works.
If you need help getting on board unittests, see mkpythonproj:
http://www.seanet.com/~hgg9140/comp/index.html#L006


-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Speed abilities

2006-04-18 Thread Harry George
Coyoteboy [EMAIL PROTECTED] writes:

 Ive read a few comments, the usual about it being slower,sometimes vastly 
 slower than a C++ written item but I was wondering if its 'slow' 
 incomparison with what I need. I'm looking at taking two arrays of 12 bytes 
 over an ethernet connection, comparing them, recieving correction data 
 (single byte) from another module over a pipe at approximately 900Hz and 
 using all these with a fairly complex set of algorithms to generate a new 
 set of 12 byte data. This has to be done in a very short time, preferably 
 the same rate of throughput as the 900Hz. Am i asking too much of Python? I 
 find C++/MFC fairly complex and python looked like a great alternative if it 
 hadnt been 'flagged' as slow.
 
 Cheers
 J 
 
 

There is no way to tell from this info.  This is a real-time problem.

If you assume 1GHZ CPU, 10 clks/instruction, 1 instructions/event
then you require 0.001 sec/event.  900Hz event rate means you only
have 0.0011 sec/event available, which is the same order of magnitude.
Chances are, variation in the event rate or in the OS response time
would violate this small safety factor, even if the assumptions were
dead on.

So you need a faster machine or fewer instructions.  Some instructions
will be used in the OS and interface stack, no matter what language
you use.  Some will be used in your fairly complex set of
algorithms.  You may have used up your 1 instructions without
getting around to Python.   Even assembler might be too slow.

If you did implement in Python and found it was too slow by a moderate
factor (e.g., you could only handle 500Hz event rate), then you can
stay in python to explore alternative implementations.  E.g., multiple
processors in parallel, more efficient algorithms, ctypes or pyrex to
speed up the python.

In terms of the overall project notion-to-delivery duration,
implementing in Python might be the right first step on your way to an
assembler implementation.  


-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: DO NOT USE JAVA BECAUSE IT IS NOT OPEN SOURCE

2006-04-10 Thread Harry George
geletine [EMAIL PROTECTED] writes:

 Nobody has mentioned that c was proprietary until richard stallman
 wrote gcc in 1987, c is a great for system programming. Just because
 something is originally proprietary does not mean its technically
 rubbish, there are plenty of merits in java escially for new
 programmers or anyone who wants to get a program going very quickly.
 Gcj at the moment can do most tasks apart from swing gui, i believe Awt
 is well supported.
 
 To further my position, without the proprietary(it was licenced on a
 liberal account at the time) UNIX created in bell labs, they would
 possibly not be linux.
 
 Miguel de Icaza started implemening mono as he too saw technical
 advantages  in .net, he is freeing the language in my opinion.
 
 Technology is just as important as polictics, hopefully i am well
 understood
 

With or without licensing issues, Java causes technical heartburn to
those accustomed to Python.  Adding to that the fact that OSS
developers are sceptical of Sun's strategies (the message changes as
Java's fortunes rise and fall), and you get a significant pushback.

I read Mono as a challenge to Microsoft: You claim this is open? Ok,
we'll implement it and then see where the submarine patents pop up.

Why would I want to let one company's abstract model sit between my
code and every piece of hardware I wish to touch?

-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: best way to install python modules on linux

2006-04-10 Thread Harry George
Fabian Braennstroem [EMAIL PROTECTED] writes:

 Hi,
 
 I am pretty new to python and will use it mainly in
 combination with scientific packages. I am running ubuntu
 breezy right now and see that some packages are out of date.
 Do you have any suggestion, how I can get/keep the latest
 python modules (e.g. scipy, numpy,...) on my ubuntu system?
 I.e. does there exist any script/program, which downloads
 and installs automatically the latest stable releases of selected
 modules? It would be nice, if the program can remove the
 installed modules, too!?
 
 Or would it be easier to stick to apt/deb and create own
 packages ...
 
 
 Greetings!
  Fabian
 

I find it helpful to leave the as-delivered Python (e.g.,
/usr/bin/python) as-is.  It is being used to run your basic Linux
system.  Screwing around with it can have nasty side effects.  Instead
I build a new one at /usr/local, give it a unique name, and
upgrade/hack that one to my heart's content.  E.g., if the base system
is using Python 2.2, you can be running Python 2.4 as
/usr/local/bin/py24, and add all the numerical packages you wish at
use/local/lib/python2.4/site-packages.  Also, make sure root doesn't
have /usr/local/bin on its PATH (which is a good rule anyway).




-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Python source cross reference doc generator?

2006-03-11 Thread Harry Fuecks
Hi All,

Wondering if a tool exists to generate cross reference documentation
for Python code bases?

Particularly after something like phpxref -
http://phpxref.sourceforge.net/ : written in Perl, scans a bunch of
PHP scripts and generates HTML output that allows you to see all the
classes / methods / functions / variables defined and (what I'm
interested in) where they are referenced. Essentially something like
API docs but with the addition of being able to see who's using a
particular method

Is there anything like this for Python? Have done much looking without success.

Many thanks.
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: python debugging question

2006-03-09 Thread Harry George
[EMAIL PROTECTED] writes:

 I am a python newbie. I have writen some 500 lines of code. There are 4
 classes and in all 5 files.
 
 Now, I am trying to run the program. I am getting wrong values for the
 simulation results.
 Is there any debugging facilities in python which would let me go step
 by step and check the values of the variables at every step. I have
 done something like this in MS Visual Stdio 6.0 sometime back.
 
 For python, I am using SPE.
 
 what is a good way of debugging such large and iterative programs ? Any
 tips.
 
 Every help is appreciated.
 
 Thanks
 
If you use my mkpythonproj:
http://www.seanet.com/~hgg9140/comp/index.html#L006
then you will have a test suite and a debug ftn ready to go.

For a brand new project, where you are exploring and don't know what
the test cases might be, you can just do the debug calls. Once you
know where you are headed (or if you got rqmts at the start) then
crank up some test cases and run that testsuite everytime you add a
few lines of code.

Start exploring or testing at the hello, world level, and gradually
add functionality (tests and code) as you go.  This is MUCH easier
than writing a lot of code and then trying to debug it.  You only need
to understand a few lines at a time.

In tens of thousands of lines of python code, I think I've used a
debugger (pdb) maybe once.  We have some apps here that are one-off
quick hacks and others that are multi-person, multi-year efforts.
They all live by their test suites.

-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Learning different languages

2006-03-08 Thread Harry George
gene tani [EMAIL PROTECTED] writes:

 Rich wrote:
  Hi,
 
  (this is a probably a bit OT here, but comp.lang seems rather
  desolated, so I'm not sure I would get an answer there. And right now
  I'm in the middle of learning Python anyway so...)
 
  Anyway, my question is: what experience you people have with working
  with different languages at the same time?
 
 http://www.infoworld.com/article/06/02/22/75452_09OPstrategic_1.html
 

re the article:

To say Java and Python could use the same libraries misses a) dynamic
programming in python and b) the re-invent-the-wheel ethos of the whole
Java world.  Python shares libraries with all other languages when it
does bindings to std libraries.  Java almost never does this,
preferring instead to roll-its-own.  In its effort to beat MS at is
own lockin game, Java deliberately does not play well with others.
(Not that I'm fond of MS and its .NET lockins either.)

re the OP: 

I find I have to concentrate on one language for a while (several
programs) to ramp up on the syntax, semantics, idioms, and libraries.
Then I'm safe to wander off and learn other languages.  When it comes
time to do a project, I use one main language unless it really is a
bad match, in which case I write in one of the others.  My one
language has variously been over the years Pascal, Modula-2, Modula-3,
perl, and Python.  Even though I've written substantially in COBOL,
FORTRAN, Lisp, Prolog, and Java, I wouldn't use these for a default
language.

-- 
Harry George
PLM Engineering Architecture
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Python and Java

2006-03-07 Thread Harry George
JKPeck [EMAIL PROTECTED] writes:

 Suppose you have an application written in Java, and you want to enable
 other applications or processes written in Python to communicate with
 it, i.e., to use Python as a scripting language for the application.
 On Windows you could do this with COM and various addons such as
 J-Integra and Mark Hammond's libraries.
 
 How would you do this if you want a mechanism that is portable across
 Windows, Linux, Mac, and Unix?
 
 Any ideas?  Jython would be a natural candidate, but it is stuck at
 Python 2.1 and seems to have an uncertain future.
 
 Thanks in advance.

If you need real CPython (e.g., need add-on libraries compiled in C),
then XMLRPC is a clean way to make the connection.
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Fromatting an xml file

2006-02-03 Thread Harry George
sir_alex [EMAIL PROTECTED] writes:

 Hi! I have a little problem writing xml files formatted in a way like
 the following:
 
 rootnode
  nodebla/node
  nodebla/node
 /rootnode
 
 Every new node element should have a tabulation before it, but when I
 use xml.dom.minidom I use writexml, which considers as a new node also
 the text (in my little example, bla phrases), so the best result I
 achieved has been the following
 
 rootnode
 node
  bla
 /node
 /rootnode
 
 but I don't want the text to be written on newlines... is there a good
 solution? Thanks!
 

Based on recommendations from this newsgroup, I write XML directly,
instead of going through DOM.  That in turn requires a mechanism for
tabbed indents, so I wrote tabbedwriter:

http://www.seanet.com/~hgg9140/comp/index.html
http://www.seanet.com/~hgg9140/comp/tabbedwriter/doc/tabbedwriter.help


-- 
[EMAIL PROTECTED] 6-6M21 BCA CompArch Design Engineering
Phone: (425) 294-4718
-- 
http://mail.python.org/mailman/listinfo/python-list


  1   2   >