473,396 Members | 2,038 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

uTidyLib --I'm lost

I'm tryinh to switch from mx.tidy to uTidyLin and it isn't going well.
So far I can't even import TidyLib. Below is what I get when trying to
import into Idle. I'm using Python 2.1.
from tidylib.lib import parse, parseString

Traceback (most recent call last):
File "<pyshell#2>", line 1, in ?
from tidylib.lib import parse, parseString
File "K:\Python21\tidylib\lib.py", line 47
yield n
^
Can someone please clue me in.

-----------------------
James A Roush
jar @ mminternet.com
-----------------------
Jul 18 '05 #1
3 1572
"yield" is a new keyword, related to support for generator functions.
It is supported in Python 2.2 with "from __future__ import generators"
and in 2.3 by default. Python 2.1 doesn't support the "yield" keyword.
In short, you need to upgrade your Python to use this module.

Jeff

Jul 18 '05 #2
In article <ma*********************************@python.org> ,
je****@unpythonic.net says...
"yield" is a new keyword, related to support for generator functions.
It is supported in Python 2.2 with "from __future__ import generators"
and in 2.3 by default. Python 2.1 doesn't support the "yield" keyword.
In short, you need to upgrade your Python to use this module.

Jeff

Oh. I guess it's to upgrade my Python Installation. Thanks
--
-----------------------
James A Roush
jar @ mminternet.com
-----------------------
Jul 18 '05 #3
At some point, james roush <ja*@mminternet.com> wrote:
I'm tryinh to switch from mx.tidy to uTidyLin and it isn't going well.
So far I can't even import TidyLib. Below is what I get when trying to
import into Idle. I'm using Python 2.1.
from tidylib.lib import parse, parseString

Traceback (most recent call last):
File "<pyshell#2>", line 1, in ?
from tidylib.lib import parse, parseString
File "K:\Python21\tidylib\lib.py", line 47
yield n
^


because yield (and generators) weren't added until python 2.2. (you'll need
to upgrade.)

--
|>|\/|<
/--------------------------------------------------------------------------\
|David M. Cooke
|cookedm(at)physics(dot)mcmaster(dot)ca
Jul 18 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Wade Leftwich | last post by:
I've installed utidylib on Python 2.3, Win2K, using uTidylib-0.1.win32.exe from http://sourceforge.net/projects/utidylib . When I try to import tidy, I get: """ >>> import tidy Traceback...
8
by: Gernot Frisch | last post by:
Hi, I get these errors, but I'm totally lost. It's a large cpp file and I don't know where to search for the error, since it does not point to any of my code lines. Can someone suggest where to...
2
by: garyusenet | last post by:
I am working with an application which is based on .net framework, and comes with an SDK. I've installed MS VB 2005 express edition. it seems to open most of the files in the sdk, but it gives...
3
by: nogoer | last post by:
Im having an issue with an ecommerce app i just moved to ipower.com hosting. The session is getting lost after 45 seconds. It happens like clockwork as ive timed it at least a dozen times. Ill log...
0
by: SM | last post by:
Hello, I have a xml file that contains the CD library of one artist. I want to extract all the tracks from a specific CD. I was able to extract the title of all the cd's but not the tracks of one...
6
by: carlos123 | last post by:
Ok i just want to thank you for checking this out and helping me out. This is the problem, well not really problem, but this is what i want to do. I have a bunch of textfields, when the "save"...
0
by: Claire | last post by:
I have built several very simple setup projects where I just install a single application. I am using the installation tools that come with Visual Studio 2005. This setup I want to build has 2...
1
by: Boris | last post by:
Hello I'm using debian linux, Python 2.4.4, and utidylib (http:// utidylib.berlios.de/). I wrote simple functions to get a web page, convert it from windows-1251 to utf8 and then I'd like to...
17
by: nickels | last post by:
-Alright im supposed to make a program that tests for perfect numbers. I have to use 2 methods and 3 methods if you count the main method. -My first method has to return a boolean value of true...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.