rpms/python-twill/F-10 python-twill.spec, NONE, 1.1 twill-0.9-noforks.patch, NONE, 1.1 .cvsignore, 1.1, 1.2 sources, 1.1, 1.2

Matthias Saou thias at fedoraproject.org
Tue Apr 14 16:29:24 UTC 2009


Author: thias

Update of /cvs/extras/rpms/python-twill/F-10
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv27402/F-10

Modified Files:
	.cvsignore sources 
Added Files:
	python-twill.spec twill-0.9-noforks.patch 
Log Message:
Initial import of 0.9.



--- NEW FILE python-twill.spec ---
%{!?python_sitelib: %global python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}

Summary: Simple scripting language for Web browsing
Name: python-twill
Version: 0.9
Release: 2%{?dist}
Group: Applications/Internet
License: MIT
URL: http://twill.idyll.org/
Source: http://darcs.idyll.org/~t/projects/twill-%{version}.tar.gz
# Don't use the included mechanize, pyparsing, ClientForm or subprocess
Patch0: twill-0.9-noforks.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
Requires: python-clientform
Requires: python-mechanize
Requires: pyparsing
BuildRequires: python-devel
BuildRequires: python-setuptools
BuildArch: noarch

%description
twill is a simple language that allows users to browse the Web from a
command-line interface. With twill, you can navigate through Web sites that
use forms, cookies, and most standard Web features.


%prep
%setup -q -n twill-%{version}
%patch0 -p1 -b .noforks
%{__rm} -rf twill/other_packages/_mechanize_dist/


%build
%{__python} setup.py build


%install
%{__rm} -rf %{buildroot}
%{__python} setup.py install -O1 --skip-build --root %{buildroot}


%clean
%{__rm} -rf %{buildroot}



%files
%defattr(-,root,root,-)
%doc README.txt doc/LICENSE.txt doc/ANNOUNCE-*.txt
%doc doc/index.txt doc/examples.txt doc/browsing.txt doc/commands.txt
%doc doc/ChangeLog doc/developer.txt doc/advocacy/simple-example.txt
%doc doc/extensions.txt doc/python-api.txt doc/other.txt doc/testing.txt
%{python_sitelib}/twill/
%{python_sitelib}/twill-*.egg-info/
%{_bindir}/twill-fork
%{_bindir}/twill-sh


%changelog
* Tue Apr 14 2009 Matthias Saou <http://freshrpms.net/> 0.9-2
- Add -b .noforks to the patch0 line.
- Remove no longer needed --single-version-externally-managed option.

* Sun Apr 12 2009 Matthias Saou <http://freshrpms.net/> 0.9-1
- The original submission was abandoned (#253355), so take it from here.

* Wed Dec 24 2008 Matthias Saou <http://freshrpms.net/> 0.9-0.3
- Include patch and requirements to get rid of all the forked included
  python code and use proper packages instead.

* Tue Oct 21 2008 Matthias Saou <http://freshrpms.net/> 0.9-0.2
- Update to 0.9 final.
- Rename from twill to python-twill.

* Sat Aug 18 2007 Luke Macken <lmacken at redhat.com> - 0.9-0.1.b1
- Initial creation


twill-0.9-noforks.patch:

--- NEW FILE twill-0.9-noforks.patch ---
diff -Naupr twill-0.9.orig/setup.py twill-0.9/setup.py
--- twill-0.9.orig/setup.py	2007-12-28 07:45:16.000000000 +0100
+++ twill-0.9/setup.py	2008-12-24 19:32:02.325394252 +0100
@@ -18,8 +18,7 @@ setup(name = 'twill',
       author_email = 'titus at idyll.org',
       license='MIT',
 
-      packages = ['twill', 'twill.other_packages',
-                  'twill.other_packages._mechanize_dist',
+      packages = ['twill',
                   'twill.extensions',
                   'twill.extensions.match_parse'],
 
diff -Naupr twill-0.9.orig/tests/test-broken-html.py twill-0.9/tests/test-broken-html.py
--- twill-0.9.orig/tests/test-broken-html.py	2007-12-28 07:45:16.000000000 +0100
+++ twill-0.9/tests/test-broken-html.py	2008-12-24 19:23:06.941372178 +0100
@@ -3,7 +3,7 @@
 parser) can parse.
 """
 
-from _mechanize_dist import ClientForm
+import ClientForm
 
 import twilltestlib
 from twill import commands
diff -Naupr twill-0.9.orig/tests/test-checkbox.py twill-0.9/tests/test-checkbox.py
--- twill-0.9.orig/tests/test-checkbox.py	2007-12-28 07:45:16.000000000 +0100
+++ twill-0.9/tests/test-checkbox.py	2008-12-24 19:30:16.306371790 +0100
@@ -2,7 +2,8 @@ import twilltestlib
 import twill
 from twill import namespaces, commands
 from twill.errors import TwillAssertionError
-from _mechanize_dist import BrowserStateError, ClientForm
+from mechanize import BrowserStateError
+import ClientForm
 
 def setup_module():
     global url
diff -Naupr twill-0.9.orig/tests/test-encoding.py twill-0.9/tests/test-encoding.py
--- twill-0.9.orig/tests/test-encoding.py	2007-12-28 07:45:16.000000000 +0100
+++ twill-0.9/tests/test-encoding.py	2008-12-24 19:23:49.458246929 +0100
@@ -1,5 +1,5 @@
 import twilltestlib
-from _mechanize_dist import ClientForm
+import ClientForm
 from cStringIO import StringIO
 
 def test_form_parse():
diff -Naupr twill-0.9.orig/tests/test-form.py twill-0.9/tests/test-form.py
--- twill-0.9.orig/tests/test-form.py	2007-12-28 07:45:16.000000000 +0100
+++ twill-0.9/tests/test-form.py	2008-12-24 19:30:25.913371670 +0100
@@ -2,7 +2,8 @@ import twilltestlib
 import twill
 from twill import namespaces, commands
 from twill.errors import TwillAssertionError
-from _mechanize_dist import BrowserStateError, ClientForm
+from mechanize import BrowserStateError
+import ClientForm
 
 def test():
     url = twilltestlib.get_url()
diff -Naupr twill-0.9.orig/twill/_browser.py twill-0.9/twill/_browser.py
--- twill-0.9.orig/twill/_browser.py	2007-12-28 07:45:16.000000000 +0100
+++ twill-0.9/twill/_browser.py	2008-12-24 19:30:42.412271633 +0100
@@ -3,13 +3,13 @@ A subclass of the mechanize browser patc
 """
 
 # wwwsearch imports
-from _mechanize_dist import Browser as MechanizeBrowser
+from mechanize import Browser as MechanizeBrowser
 
 import wsgi_intercept
 from utils import FixedHTTPBasicAuthHandler, FunctioningHTTPRefreshProcessor
 
 def build_http_handler():
-    from _mechanize_dist._urllib2 import HTTPHandler
+    from mechanize._urllib2 import HTTPHandler
 
     class MyHTTPHandler(HTTPHandler):
         def http_open(self, req):
diff -Naupr twill-0.9.orig/twill/browser.py twill-0.9/twill/browser.py
--- twill-0.9.orig/twill/browser.py	2007-12-28 07:45:16.000000000 +0100
+++ twill-0.9/twill/browser.py	2008-12-24 19:31:02.618371499 +0100
@@ -10,8 +10,9 @@ OUT=None
 import re
 
 # wwwsearch imports
-import _mechanize_dist as mechanize
-from _mechanize_dist import BrowserStateError, LinkNotFoundError, ClientForm
+import mechanize
+from mechanize import BrowserStateError, LinkNotFoundError
+import ClientForm
 
 # twill package imports
 from _browser import PatchedMechanizeBrowser
diff -Naupr twill-0.9.orig/twill/commands.py twill-0.9/twill/commands.py
--- twill-0.9.orig/twill/commands.py	2007-12-28 07:45:16.000000000 +0100
+++ twill-0.9/twill/commands.py	2008-12-24 19:31:18.490371194 +0100
@@ -4,9 +4,9 @@ twill-sh.
 """
 
 import sys
-import _mechanize_dist as mechanize
-from _mechanize_dist import ClientForm
-from _mechanize_dist._headersutil import is_html
+import mechanize
+import ClientForm
+from mechanize._headersutil import is_html
 
 OUT=None
 ERR=sys.stderr
diff -Naupr twill-0.9.orig/twill/__init__.py twill-0.9/twill/__init__.py
--- twill-0.9.orig/twill/__init__.py	2007-12-28 07:45:16.000000000 +0100
+++ twill-0.9/twill/__init__.py	2008-12-24 19:34:35.701247369 +0100
@@ -43,11 +43,6 @@ thisdir = os.path.dirname(__file__)
 extensions = os.path.join(thisdir, 'extensions')
 sys.path.append(extensions)
 
-# add other_packages in at the *beginning*, so that the correct
-# (patched) versions of pyparsing and mechanize get imported.
-wwwsearchlib = os.path.join(thisdir, 'other_packages')
-sys.path.insert(0, wwwsearchlib)
-
 # the two core components of twill:
 from shell import TwillCommandLoop
 from parse import execute_file, execute_string
diff -Naupr twill-0.9.orig/twill/utils.py twill-0.9/twill/utils.py
--- twill-0.9.orig/twill/utils.py	2007-12-28 07:45:16.000000000 +0100
+++ twill-0.9/twill/utils.py	2008-12-24 19:31:34.078371767 +0100
@@ -11,11 +11,11 @@ import base64
 
 import subprocess
 
-import _mechanize_dist as mechanize
-from _mechanize_dist import ClientForm
-from _mechanize_dist._util import time
-from _mechanize_dist._http import HTTPRefreshProcessor
-from _mechanize_dist import BrowserStateError
+import mechanize
+import ClientForm
+from mechanize._util import time
+from mechanize._http import HTTPRefreshProcessor
+from mechanize import BrowserStateError
 
 class ResultWrapper:
     """


Index: .cvsignore
===================================================================
RCS file: /cvs/extras/rpms/python-twill/F-10/.cvsignore,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- .cvsignore	14 Apr 2009 16:16:25 -0000	1.1
+++ .cvsignore	14 Apr 2009 16:28:53 -0000	1.2
@@ -0,0 +1 @@
+twill-0.9.tar.gz


Index: sources
===================================================================
RCS file: /cvs/extras/rpms/python-twill/F-10/sources,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- sources	14 Apr 2009 16:16:25 -0000	1.1
+++ sources	14 Apr 2009 16:28:53 -0000	1.2
@@ -0,0 +1 @@
+c362307616696f4838e9456c42b70fdc  twill-0.9.tar.gz




More information about the scm-commits mailing list