Kevin,

   Thanks for the answer.

On 9/18/06, Kevin Dangoor <[EMAIL PROTECTED]> wrote:
>
> I believe the problem is that it's expecting a compiled template at
> self.template. Take a look at Widget.display() and you'll see what
> it's trying to do when you call form().

   As you could imagine, I'm just creating my first widget.
   I'm trying to be as strict as it's possible to TurboGears' way of
doing a Widget. So, I found the load_kid_template widgets.meta method
thar returns template_c, and put it at the end of my code, as this:

                (self.template_c, self.template) =
widgets.meta.load_kid_template(template)

   This one raise a strange error:

   (... snip ...)

  File "/home/aires/hotelx/hotelx/reserva/myWidgets.py", line 69, in __init__
    (self.template_c, self.template) = widgets.meta.load_kid_template(template)
  File 
"/usr/lib/python2.4/site-packages/TurboGears-0.9a8-py2.4.egg/turbogears/widgets/meta.py",
line 197, in load_kid_template
    return (kid.load_template(t, name=modname).Template, t)
  File "/usr/lib/python2.4/site-packages/kid-0.9.3-py2.4.egg/kid/__init__.py",
line 120, in load_template
    code = compiler.compile(fo, filename, encoding)
  File "/usr/lib/python2.4/site-packages/kid-0.9.3-py2.4.egg/kid/compiler.py",
line 48, in compile
    py = kid.parser.parse(source, encoding, filename=filename)
  File "/usr/lib/python2.4/site-packages/kid-0.9.3-py2.4.egg/kid/parser.py",
line 46, in parse
    return parser.parse()
  File "/usr/lib/python2.4/site-packages/kid-0.9.3-py2.4.egg/kid/parser.py",
line 76, in parse
    self.proc_stream(self.module_code)
  File "/usr/lib/python2.4/site-packages/kid-0.9.3-py2.4.egg/kid/parser.py",
line 133, in proc_stream
    for (ev, item) in self.stream:
  File "/usr/lib/python2.4/site-packages/kid-0.9.3-py2.4.egg/kid/pull.py",
line 168, in _track
    for p in stream:
  File "/usr/lib/python2.4/site-packages/kid-0.9.3-py2.4.egg/kid/pull.py",
line 210, in _coalesce
    for ev, item in stream:
  File "/usr/lib/python2.4/site-packages/kid-0.9.3-py2.4.egg/kid/pull.py",
line 374, in __iter__
    for (ev, stuff) in self._expat_stream():
  File "/usr/lib/python2.4/site-packages/kid-0.9.3-py2.4.egg/kid/pull.py",
line 346, in _expat_stream
    feed(data)
  File "/usr/lib/python2.4/site-packages/kid-0.9.3-py2.4.egg/kid/pull.py",
line 414, in feed
    raise e

   Any clue about what's the error? I'm trying to scratch kid dir, but
until now have no idea what's going on... :(


Sincerely,

-- 
-><-
Fernando Aires
[EMAIL PROTECTED]
"Em tudo Amar e Servir"
-><-

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"TurboGears" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/turbogears
-~----------~----~----~----~------~----~------~--~---

Reply via email to