[twill] checking for bad links.

C. Titus Brown ctb at msu.edu
Sun Sep 28 15:48:53 PDT 2008


On Fri, Sep 26, 2008 at 01:50:39PM -0700, jeremiah wrote:
-> Thanks Sheryl. I'll try that.
-> 
-> Also, another question..
-> 
-> I'm trying to automate a login script in python using twill. when i do
-> this via cmd line in twill, everything works as expected and I get the
-> appropriate sessions/cookies. However, these same variables won't return
-> when i run the python script? Do I need to pass/return them some how?
-> 
-> Here's what I'm doing...
-> 
-> >>twill-sh
-> >> extend_with filename
-> >>login someusername somepassword
-> >>show_cookies #coorect vars don't print
-> 
-> File...
-> 
-> #!/usr/bin/python
-> from twill.commands import *
-> def login(u, p):
->         go('http://someurl')
->         fv(1, 'username', u)
->         fv(1, 'password', p)
->         submit
-> 
-> Appreciate your help!

Try making that 'submit()' :)

--titus



More information about the twill mailing list