@@ -35,16 +35,16 @@ Scrapely has a powerful API, including a template format that can be edited
3535externally, that you can use to build very capable scrapers.
3636
3737What follows is a quick example of the simplest possible usage, that you can
38- run in the Python shell. This example is also available in the ``example.py ``
39- script, located at the root of the repository.
38+ run in a Python shell.
4039
4140Start by importing and instantiating the Scraper class::
4241
4342 >>> from scrapely import Scraper
4443 >>> s = Scraper()
4544
4645Then, proceed to train the scraper by adding some page and the data you expect
47- to scrape from there::
46+ to scrape from there (note that all keys and values in the data you pass must
47+ be strings)::
4848
4949 >>> url1 = 'http://pypi.python.org/pypi/w3lib'
5050 >>> data = {'name': 'w3lib 1.0', 'author': 'Scrapy project', 'description': 'Library of web-related functions'}
@@ -156,6 +156,12 @@ And then install scrapely with::
156156
157157 aptitude install python-scrapely
158158
159+ Tests
160+ =====
161+
162+ `nose `_ is the preferred way to run tests. Just run: ``nosetests `` from the
163+ root directory.
164+
159165Architecture
160166============
161167
@@ -183,7 +189,8 @@ the other hand, the extraction code is reliable and production-ready. So, if
183189you want to use Scrapely in production, you should use train() with caution and
184190make sure it annotates the area of the page you intent being annotated.
185191
186- Alternatively, you can use the Scrapely tool to annotate pages.
192+ Alternatively, you can use the Scrapely command line tool to annotate pages,
193+ which provides more manual control for higher accuracy.
187194
188195License
189196=======
@@ -197,3 +204,4 @@ Scrapely library is licensed under the BSD license.
197204.. _same Github account : https://github.com/scrapy
198205.. _slybot : https://github.com/scrapy/slybot
199206.. _selectors : http://doc.scrapy.org/en/latest/topics/selectors.html
207+ .. _nose : http://readthedocs.org/docs/nose/en/latest/
0 commit comments