------------------------------------------------------------------------ r315 | ottrey | 2004-11-28 14:08:52 +1100 (Sun, 28 Nov 2004) | 3 lines Releasing version 0.5.1 of library. (Unfortunately the translation files keep changing with every commit - can we stop that somehow?) ------------------------------------------------------------------------ r298 | dan_fritz | 2004-11-23 20:19:10 +1100 (Tue, 23 Nov 2004) | 1 line A tab managed to sneak into last commit (297), this will correct the indentation ------------------------------------------------------------------------ r297 | dan_fritz | 2004-11-23 20:04:11 +1100 (Tue, 23 Nov 2004) | 1 line Corrected a race condition problem with lazy_instantiation() ------------------------------------------------------------------------ r291 | ottrey | 2004-11-21 23:37:37 +1100 (Sun, 21 Nov 2004) | 7 lines Getting ready for a November 2004 release. Merged branches/dan back with the trunk. Added timezone_test_gen.py script - this should probably go in some future contrib directory. Updated the i18n .po files. Waiting on other translations. ------------------------------------------------------------------------ r263 | ottrey | 2004-11-16 14:21:43 +1100 (Tue, 16 Nov 2004) | 2 lines Added Dan's changes to his timezone module. ------------------------------------------------------------------------ r261 | ottrey | 2004-11-15 00:12:36 +1100 (Mon, 15 Nov 2004) | 4 lines Made a tabulate function in output to be used when listing channels. Changed grab to use this new tabulate function. Changed mtgrab to use message.debug() properly. ------------------------------------------------------------------------ r260 | ottrey | 2004-11-13 17:43:33 +1100 (Sat, 13 Nov 2004) | 2 lines Setting some svn:keywords ------------------------------------------------------------------------ r259 | ottrey | 2004-11-13 17:40:29 +1100 (Sat, 13 Nov 2004) | 3 lines Added Dan's timezone module. Till I can talk him into removing it. ;-) ------------------------------------------------------------------------ r258 | ottrey | 2004-11-13 16:45:05 +1100 (Sat, 13 Nov 2004) | 2 lines Added in Dan's changes. ------------------------------------------------------------------------ r257 | gustavo | 2004-11-13 06:21:40 +1100 (Sat, 13 Nov 2004) | 6 lines lib/grab.py: Fixed infinite recurssion. lib/message.py: Fixed gettext wrong usage. ------------------------------------------------------------------------ r255 | ottrey | 2004-11-12 13:35:28 +1100 (Fri, 12 Nov 2004) | 3 lines Just trying to get things working again... ------------------------------------------------------------------------ r253 | ottrey | 2004-10-28 13:29:49 +1000 (Thu, 28 Oct 2004) | 2 lines Now handling dates of the format YYYY-MM-DD ------------------------------------------------------------------------ r252 | ottrey | 2004-10-25 13:30:38 +1000 (Mon, 25 Oct 2004) | 2 lines Optimization to message ------------------------------------------------------------------------ r251 | ottrey | 2004-10-20 15:02:26 +1000 (Wed, 20 Oct 2004) | 4 lines Apparently the 1 second datetime bug doesn't occur under windows XP, python 2.3 so I'll remove this "fix" - really should find out _exactly_ when it occurs though. ------------------------------------------------------------------------ r250 | gustavo | 2004-10-19 05:41:28 +1000 (Tue, 19 Oct 2004) | 4 lines * tv_grab_br_uol: cleanup: do not use self.conf, use self.get_conf_channels() and self.get_chan_by_{name,id}() instead. This allows transparency! * grab.py: cleanup: avoi using self.conf, use self.get_conf_channels() and self.get_chan_by_{name,id}() instead. This allows transparency! * prog.py: fixed encode error of unescaped prints ------------------------------------------------------------------------ r248 | gustavo | 2004-10-14 06:34:26 +1000 (Thu, 14 Oct 2004) | 4 lines Make things easy to translators. FIX: grab now use toprint() at keyboard interruption. ------------------------------------------------------------------------ r247 | gustavo | 2004-10-14 03:36:56 +1000 (Thu, 14 Oct 2004) | 2 lines FIX: print_stat() was crashing due missing toprint(). ------------------------------------------------------------------------ r246 | gustavo | 2004-10-14 03:16:23 +1000 (Thu, 14 Oct 2004) | 2 lines set svn:keywords on every python/grabber file. ------------------------------------------------------------------------ r244 | gustavo | 2004-10-14 01:56:25 +1000 (Thu, 14 Oct 2004) | 6 lines Fixed i18n stuff. Use: import i18n not from i18n import ... ------------------------------------------------------------------------ r243 | ottrey | 2004-10-13 17:45:28 +1000 (Wed, 13 Oct 2004) | 2 lines Prog was catching _all_ exceptions, so removed "Exception" from it's list. ------------------------------------------------------------------------ r242 | gustavo | 2004-10-09 17:01:58 +1000 (Sat, 09 Oct 2004) | 28 lines Everything is up and running again. New features: * color and xterm title! Thanks to gentoo portage :) * moved a lot of generic things from my grabber to Grab/Grab_C: - page_charset, re_clean, re_replace and clear_html() - parse_tags, parse_attrs, keep_empty_tags - dump_structure(), dump_file(), get_htmlstruct() - get_id() * config file format changed, now it uses: [ channel name ] { id, status, name } it seems more used than the previous [ channel id ]{ status, name } since the website provides name instead of the id, which user can change. * get_chan_by_id() and get_chan_by_name() * info like 'getting url' are changed to moreinfo() * message.exception() to handle exceptions in a user friendly way. * config_locale.toprint() converts unicode back to str for your terminal Bug Fixes: * almost everything is fixed now, just the grab.Grab_C grab_days() I think is still broken, my grabber and others overload it, so I don't see a showstopper for now. But I'll look at it later. * FIXED: customized parser was not handling unicode chars (unichr() <-> chr()) * many trailing spaces removed from lines, some still there * uniformized some function names to 'func_name' instead of 'funcName', and spaces within parentheses. ------------------------------------------------------------------------ r241 | gustavo | 2004-10-09 04:02:52 +1000 (Sat, 09 Oct 2004) | 3 lines Some _INCOMPLETE_ changes... some things are broken, I'll fix them later... just commit since I have to work on other computer, later. ------------------------------------------------------------------------ r240 | gustavo | 2004-10-08 13:40:30 +1000 (Fri, 08 Oct 2004) | 15 lines Major changes to support gettext. after any string modification, run: update_i18n.sh -a and translate the files reported as fuzzy or incomplete at checking phase. To start a new translation, do: cp share/locale/pytvgrab.pot share/locale/$LANG/LC_MESSAGES/pytvgrab.po and open it with a translation utility like kbabel, vi or emacs. Plain text editors should also be able to edit the file, but be aware to check if it's valid! Just commit the .po, not the .mo! The later is a binary (machine object) file. ------------------------------------------------------------------------ r239 | ottrey | 2004-10-07 16:59:18 +1000 (Thu, 07 Oct 2004) | 2 lines Small fix to _() function. ------------------------------------------------------------------------ r237 | ottrey | 2004-10-07 16:37:05 +1000 (Thu, 07 Oct 2004) | 4 lines Added a tranlsation module that contains all the translations. (Which could disapear if I ever bother to use gettext()) Modified the grab and prog modules to use the translation module. ------------------------------------------------------------------------ r235 | ottrey | 2004-10-07 11:23:33 +1000 (Thu, 07 Oct 2004) | 13 lines I've added Gustavo's ask3.py patch to the grab module. I've added --add,--del,--addAll,--delAll etc I've shifted the config method up into the library. Which means I had to use a translation method to translate the english in the library into the grabbers language. Unfortunately I couldn't figure out how to use gettext - so made my own version of gettext. ie. a method in the Grab class: translation_table={} def _(self, str): return self.translation_table.get(str, str) which uses a dictionary that is overridden by the Grabber. ------------------------------------------------------------------------ r233 | rdc | 2004-10-04 18:56:37 +1000 (Mon, 04 Oct 2004) | 2 lines Fixed ugly bug int Grab_C's ask routine. Works as intended now. ------------------------------------------------------------------------ r227 | ottrey | 2004-10-04 11:03:45 +1000 (Mon, 04 Oct 2004) | 2 lines Fixed small but fatal error in runtime library version checking. ------------------------------------------------------------------------ r223 | ottrey | 2004-10-01 11:31:12 +1000 (Fri, 01 Oct 2004) | 4 lines Make the library do the runtime check in Grab.__init__ (instead of main()). This way the check can't be overridden, and older versions of grabbers will have to do this check. ------------------------------------------------------------------------ r222 | ottrey | 2004-10-01 11:10:11 +1000 (Fri, 01 Oct 2004) | 2 lines Initialized __lib_version__ in the Grab class. ------------------------------------------------------------------------ r221 | ottrey | 2004-10-01 11:01:23 +1000 (Fri, 01 Oct 2004) | 3 lines Added runtime dependency checking. And made the lib_version check more robust. ------------------------------------------------------------------------ r218 | ottrey | 2004-10-01 10:07:38 +1000 (Fri, 01 Oct 2004) | 2 lines Updated lib version to new version numbering scheme. ------------------------------------------------------------------------ r209 | ottrey | 2004-09-29 11:40:38 +1000 (Wed, 29 Sep 2004) | 3 lines There was a problem with my nz_tvnz grabber (regarding empty guides) so I made a change to the re2 section of the library to fix that grabber. ------------------------------------------------------------------------ r199 | gustavo | 2004-09-29 00:26:40 +1000 (Wed, 29 Sep 2004) | 2 lines we don't need try-except around str.encode( encoding, 'replace' ) ------------------------------------------------------------------------ r198 | ottrey | 2004-09-28 13:53:48 +1000 (Tue, 28 Sep 2004) | 3 lines Catch any message encoding exceptions in the message.py module. If the encoding fails, simply replace invalid chars with a '?' ------------------------------------------------------------------------ r197 | ottrey | 2004-09-24 16:54:44 +1000 (Fri, 24 Sep 2004) | 5 lines Shifted main() from the grabbers up into the library. Now the library will iterate through the dates, using the date format specified by Grabber._url_date_fmt and call the grabber's grab_day() method. So all a grabber has to do now is implement a grab_day(self, date) method. ------------------------------------------------------------------------ r190 | ottrey | 2004-09-20 23:27:39 +1000 (Mon, 20 Sep 2004) | 6 lines Made cache_dir a global in the urutil module. It was getting passed round all over the place in the grabbers. This way the cache_dir is set in the library and the grabbers don't have to worry about it at all. It happens in a simliar way to how the message.verbose_level is set and used. ------------------------------------------------------------------------ r186 | ottrey | 2004-09-20 21:36:23 +1000 (Mon, 20 Sep 2004) | 3 lines I hadn't actually released version 0.3.5 of the library yet, so bumped the version back down from 0.3.6 to 0.3.5 ------------------------------------------------------------------------ r182 | ottrey | 2004-09-20 18:20:53 +1000 (Mon, 20 Sep 2004) | 16 lines Changes to lib: - Fixed up some messaging stuff. - The QUIET and ERROR levels were swapped in the message.py module. - The grab.py module had a call to sys.stderr when I could have just called message.error(). Gustavo: - I didn't really want to touch the encoding stuff in message.message(), but I think those calls to encode() might be better shifted down immediately before the call to stderr.write() Changes to br_uol grabber: - It was making calls to message.message() when it could have used message.moreinfo() instead. - It wasn't setting the translation table in the message module properly - fixed that. BTW Gustavo, what's Portuguese for "MOREINFO"? Anyway if it can't find the translation it will default to the English word. ------------------------------------------------------------------------ r181 | ottrey | 2004-09-20 17:27:51 +1000 (Mon, 20 Sep 2004) | 2 lines Making the traceback bug report creation a little friendlier. ------------------------------------------------------------------------ r177 | gustavo | 2004-09-19 18:36:55 +1000 (Sun, 19 Sep 2004) | 10 lines * customizedparser now accepts one more parameter: keep_empty_tags. This should be used to avoid removing empty tags (one withour children or cdata). It's usefull for tags. * urlutils was changed to support keep_empty_tags. * added class URL to urlutils. URL is a helper to provide GET and POST data, since POST is not part of the URL itself, this class is handy. * urlutils: cache files are prefixed with 'tv_grab-CACHE-' * urlutils: while caching, messages show the mapping remote -> local file. * Increased library version. ------------------------------------------------------------------------ r176 | ottrey | 2004-09-18 19:26:01 +1000 (Sat, 18 Sep 2004) | 8 lines Added cacheing support. Uses the command line option --cachedir=DIR If cache_dir == None (ie. default) then no cache is used. Unfortunately I seem to have broken the br_uol grabber in the process - sorry about that. :-( ------------------------------------------------------------------------ r175 | ottrey | 2004-09-18 16:59:54 +1000 (Sat, 18 Sep 2004) | 3 lines A lot of messing around with unit testing to get the ebuilds to work. Also updated all the library modules to use set the keyword properties. ------------------------------------------------------------------------ r172 | ottrey | 2004-09-17 17:18:12 +1000 (Fri, 17 Sep 2004) | 2 lines Trying to get unit testing to work again for the gentoo ebuilds. ------------------------------------------------------------------------ r171 | ottrey | 2004-09-17 17:08:12 +1000 (Fri, 17 Sep 2004) | 2 lines Attempt at writing some ebuild scripts for gentoo. ------------------------------------------------------------------------ r170 | ottrey | 2004-09-17 15:48:46 +1000 (Fri, 17 Sep 2004) | 2 lines Updating some documentation for the library. ------------------------------------------------------------------------ r168 | ottrey | 2004-09-16 10:04:44 +1000 (Thu, 16 Sep 2004) | 5 lines Added an __sf_mirror__ attribute that lets a grabber specify a preference for which sourceforge mirror to download from. Which I think is necessary when an actual URL of the source is required - eg in creating RPMs. ------------------------------------------------------------------------ r158 | ottrey | 2004-09-15 10:09:44 +1000 (Wed, 15 Sep 2004) | 4 lines Print an error message when an empty webpage is retrieved. (I think someone was having a problem getting empty files from their web proxy.) ------------------------------------------------------------------------ r157 | ottrey | 2004-09-15 10:07:14 +1000 (Wed, 15 Sep 2004) | 2 lines Needed to import sys for an extra error message to be printed. ------------------------------------------------------------------------ r149 | ottrey | 2004-09-06 15:55:09 +1000 (Mon, 06 Sep 2004) | 2 lines Prettying up exception handling traceback stuff. ------------------------------------------------------------------------ r148 | ottrey | 2004-09-06 12:00:23 +1000 (Mon, 06 Sep 2004) | 9 lines Added in bug report generation. When an exception occurs a unique traceback file is created in the cwd. And the user is directed to submit a bug report to: http://sourceforge.net/tracker/?func=add&group_id=87433&atid=583152 NB. I haven't tested this ~fully~ (especially under windows), but think it should work OK. So I'll just let it sneak out in the next release for users to test. ------------------------------------------------------------------------ r145 | ottrey | 2004-09-03 09:54:07 +1000 (Fri, 03 Sep 2004) | 4 lines Upped the lib version. Added a dist.sh script for easier distribution of the grabbers and lib. Added a pretty Windows bitmap which will show up when the win32.exe self extracting bdist is installed. ------------------------------------------------------------------------ r144 | ottrey | 2004-08-30 10:48:02 +1000 (Mon, 30 Aug 2004) | 3 lines Fix to bug: https://sourceforge.net/tracker/index.php?func=detail&aid=1018442&group_id=87433&atid=583152 ------------------------------------------------------------------------ r142 | ottrey | 2004-08-27 18:18:34 +1000 (Fri, 27 Aug 2004) | 3 lines Added some TODO documentation. I'm getting ready to change the results returned by multiplicity suffixes. ------------------------------------------------------------------------ r141 | ottrey | 2004-08-27 18:16:24 +1000 (Fri, 27 Aug 2004) | 2 lines Added a Time() + Date() method. ------------------------------------------------------------------------ r140 | ottrey | 2004-08-27 17:12:07 +1000 (Fri, 27 Aug 2004) | 48 lines Added a Group class. Added yaml support to make debugging easier. Added action methods to named pattern matches ie. now can use: (?Pexp) --> (?Pexp) eg. >>> import re2 >>> pat='(?P(?P\d+.?\d*) (?P[^,]+))(,)?' >>> buf='12 drummers drumming, 11.01 pipers piping, 10 lords a-leaping' >>> re2.extract(pat, buf) {'verse': [{'number': 12.0, 'activity': 'DRUMMERS DRUMMING'}, {'number': 11.01, 'activity': 'PIPERS PIPING'}, {'number': 10.0, 'activity': 'LORDS A-LEAPING'}]} >>> print re2.extract(pat, buf) --- verse: - activity: DRUMMERS DRUMMING number: 12.0 - activity: PIPERS PIPING number: 11.01 - activity: LORDS A-LEAPING number: 10.0 Note: 'action' can be a builtin function a string method or a user defined function. eg. >>> import re2 >>> buf='12 drummers drumming, 11.01 pipers piping, 10 lords a-leaping' >>> def exaggerate(n): return 3*float(n) ... >>> pat='(?P(?P\d+.?\d*) (?P[^,]+))(,)?' >>> print re2.extract(pat, buf) --- verse: - activity: DRUMMERS DRUMMING number: 36.0 - activity: PIPERS PIPING number: 33.03 - activity: LORDS A-LEAPING number: 30.0 ------------------------------------------------------------------------ r139 | ottrey | 2004-08-27 16:56:26 +1000 (Fri, 27 Aug 2004) | 2 lines Added __doc__ string. ------------------------------------------------------------------------ r134 | ottrey | 2004-08-23 15:10:23 +1000 (Mon, 23 Aug 2004) | 5 lines Using tv_grab_be_tvb as the guinea pig test grabber to try and achieve Windows compatibility. NOTE: I can't actually test it. Can someone test it for me please? ------------------------------------------------------------------------ r133 | ottrey | 2004-08-23 14:47:40 +1000 (Mon, 23 Aug 2004) | 7 lines Attempt to make the lib (and the grabber installer) work under Windows. NOTE: I haven't had a chance to test this properly. (ie. I got it half working on a windows box, then have made the rest of the changes blind.) I expect there's a 20% chance it will actually work. Can someone test it - please. ------------------------------------------------------------------------ r131 | ottrey | 2004-08-23 14:26:42 +1000 (Mon, 23 Aug 2004) | 3 lines Changed the unit test calling method - now the assertion will print out the expression, the expected value and the returned value. ------------------------------------------------------------------------ r130 | ottrey | 2004-08-23 14:17:03 +1000 (Mon, 23 Aug 2004) | 9 lines Attempted to fix bug under windows. - Added some more test cases to datetime2.py module. Changed the calling method - now the assertion will print out the expression, the expected value and the returned value. - mktime() won't accept "slightly" negative numbers. (ie. datetimes around 1970/1/1 which get shifted into the -ve by timezone adjustmets) - for some bizaar reason (under windows) the times are off by a second when I use 1970/1/2 as epoc. ------------------------------------------------------------------------ r129 | ottrey | 2004-08-23 14:08:59 +1000 (Mon, 23 Aug 2004) | 4 lines Made the _Match object a dict in the re2 module I wanted to make the library more useful for another program. - it shouldn't effect any of the current code. ------------------------------------------------------------------------ r128 | ottrey | 2004-08-19 11:49:50 +1000 (Thu, 19 Aug 2004) | 5 lines Added some more test cases to the datetime2.py module. Trying to track down the bug... http://sourceforge.net/tracker/index.php?func=detail&aid=987344&group_id=87433&atid=583152 ------------------------------------------------------------------------ r123 | ottrey | 2004-08-09 15:44:37 +1000 (Mon, 09 Aug 2004) | 3 lines Changed all the calls to unittest in the library modules so each library can stand alone without the unittest2 module. (ie. minor change that shouldn't affect anything) ------------------------------------------------------------------------ r119 | ottrey | 2004-07-30 15:19:46 +1000 (Fri, 30 Jul 2004) | 15 lines - Moved Julian's ask method (from tv_grab_nz_xtra) up into the library. ie. now it's part of the grab module and can be inherited from Grab_C.ask() (I was _going_ to change tv_grab_br_uol grabber to use it but I'll leave all the tricky unicode stuff up to Gustavo to change.) - Also moved Julian's debug messages up into the library. ie. I added in a debug message level to the message module. And changed tv_grab_nz_xtra to use that instead of it's own debug calls. - Also changed the tv_grab_nz_xtra grabber to let the xmltv module calculate the stop times for it. (NB. I should mention that functionality in a HOWTO_write_a_grabber) - Upped the library version to 0.3.2 and made sure the tv_grab_nz_xtra grabber depends on _that_ version of the library. (NB. Which means it will obediently complain upon installation if that version of the library has not been installed) ------------------------------------------------------------------------ r118 | ottrey | 2004-07-20 10:50:38 +1000 (Tue, 20 Jul 2004) | 4 lines Upped the revision number of the library to 0.3.1 because the tv_grab_br_uol grabber uses the new cache feature in urlutils module. So now the br_uol grabber will complain unless the 0.3.1 library has been installed. ------------------------------------------------------------------------ r117 | ottrey | 2004-07-20 10:03:11 +1000 (Tue, 20 Jul 2004) | 6 lines Attempt to fix the problem in the re2 module raised in the Discussion Forum by freefall_pwg. http://sourceforge.net/forum/forum.php?thread_id=1105426&forum_id=299829 ie. (?P[^<]*) produces a list with two elements (['heute mittag (ZDF) ', '']) Now it should return a string eg. 'heute mittag (ZDF)' instead of the above list. ------------------------------------------------------------------------ r113 | gustavo | 2004-07-17 17:15:10 +1000 (Sat, 17 Jul 2004) | 11 lines xmltv: Messages are less verbose (off by default) customizedparser: Have the contents of broken files inside the Exception urlutils: Better handling of broken connections. Clean cache if the file was wrong. ------------------------------------------------------------------------ r110 | gustavo | 2004-07-14 04:23:57 +1000 (Wed, 14 Jul 2004) | 2 lines Support cache of files. ------------------------------------------------------------------------ r109 | gustavo | 2004-07-13 14:41:16 +1000 (Tue, 13 Jul 2004) | 4 lines Better handling of poor html. I suspect that in some cases documents are wrong due connection timeout... How are we handling timeouts? ------------------------------------------------------------------------ r107 | gustavo | 2004-07-13 14:09:43 +1000 (Tue, 13 Jul 2004) | 2 lines better handling of unicode/locale ------------------------------------------------------------------------ r106 | gustavo | 2004-07-13 14:09:07 +1000 (Tue, 13 Jul 2004) | 2 lines Fix typo ------------------------------------------------------------------------ r105 | ottrey | 2004-07-09 10:43:39 +1000 (Fri, 09 Jul 2004) | 3 lines For all these modules unittest2 overrides unittest iff it is present, otherwise it defaults to using the system unittest module. This is so these modules can be tested standalone if necessary. (ie. they are now decoupled from unittest2) ------------------------------------------------------------------------ r100 | ottrey | 2004-06-13 11:54:41 +1000 (Sun, 13 Jun 2004) | 12 lines Added the unittest2.py module to the lib. (This is a wrapper for calling python's standard unittest module.) And I added svn keywords to many files. (hopefully it'll change them this time as I did.. % svn propset -R svn:keywords "Author LastChangedBy ...etc" . And I just wanted to be the one to make the 100th version! Yeah! ------------------------------------------------------------------------ r97 | ottrey | 2004-06-12 23:49:38 +1000 (Sat, 12 Jun 2004) | 15 lines Removed some files from the repository: lib/unittest.py: - Now using python's unittest module grabbers/README: - This is automatically generated when a distribution is made. grabbers/MANIFEST: - This is automatically generated when a distribution is made. grabbers/MANIFEST.in: - This is automatically generated when a distribution is made. And added: grabbers/distribute.py: - Is a new file used from distribution. ------------------------------------------------------------------------ r96 | ottrey | 2004-06-12 23:41:36 +1000 (Sat, 12 Jun 2004) | 41 lines Some major changes here, so bumped up the version from 0.2.1 to 0.3.0 MANIFEST: - Removed from the repository as they are automatically generated setup.py: - Tries to run unit tests on the lib modules. - Not sure if this will work under Windows. lib/__init__.py: - Changed the version to 0.3.0 - Changed Development Status from '3 - Alpha', '4 - Beta' lib/*.py: - Converted the unittests to conform to the python unittest module lib/prog.py: - Added __revision__ handling lib/grab.py: - Changed the default verbosity from WARNING to INFO lib/message.py: - Added a new message level - MOREINFO grabbers/tv_grab_*: - Added a __lib_version__ attribute that links the script to version of the library. - Changed the version to 0.3.0 grabbers/distribute.py: - Tried to split setup.py into setup.py and distribute.py, where distribute.py is only used for distribution and not included in the src distribution. grabbers/setup.py: - Does a dependancy check on the library before processing the grabber. grabbers/tv_grab_be_tvb: - Moved the comments to the top of the file (ie above the imports) so they could be picked up as a docstring. grabbers/README: - Removed from the repository as they are automatically generated grabbers/MANIFEST: - Removed from the repository as they are automatically generated grabbers/MANIFEST.in: - Removed from the repository as they are automatically generated Also, watch out for: - There could be a problem with the changeover from my unittest to python's unittest module. ------------------------------------------------------------------------ r84 | gustavo | 2004-02-22 19:06:45 +1100 (Sun, 22 Feb 2004) | 2 lines Don't crash on unknow charref. There're lot of bad html code out there! ------------------------------------------------------------------------ r83 | gustavo | 2004-02-22 19:04:57 +1100 (Sun, 22 Feb 2004) | 2 lines Better Unicode support. ------------------------------------------------------------------------ r82 | gustavo | 2004-02-21 21:12:17 +1100 (Sat, 21 Feb 2004) | 2 lines Support unicode information. ------------------------------------------------------------------------ r81 | gustavo | 2004-02-21 20:24:30 +1100 (Sat, 21 Feb 2004) | 2 lines Support unicode messages. Try to guess system encoding from LC_MESSAGES, LC_ALL and LANG. ------------------------------------------------------------------------ r80 | rdc | 2004-02-19 06:05:38 +1100 (Thu, 19 Feb 2004) | 5 lines Updated customizedparser to handle &#xxx; and &lala; correctly with correct spacing. Updated tv_grab_be_tvb to use the right server charset (w-1215). Updated both files with svn:keywords ------------------------------------------------------------------------ r79 | ottrey | 2004-01-20 12:30:10 +1100 (Tue, 20 Jan 2004) | 4 lines Attempt to make unittest module windows compatible. (Still needs someone to test it though...) (_should_ re-write to use standard unittest lib ... one day.) ------------------------------------------------------------------------ r77 | ottrey | 2003-11-28 11:08:50 +1100 (Fri, 28 Nov 2003) | 6 lines Changed trove classifiers, so that setup.py register works, in : lib/__init__.py grabbers/au_aol/__init__.py grabbers/be_tvb/__init__.py grabbers/br_uol/__init__.py ------------------------------------------------------------------------ r76 | ottrey | 2003-11-26 14:12:26 +1100 (Wed, 26 Nov 2003) | 3 lines Remove the os.popen('date') test in datetime2 to aim for ..chrgmmm.. windows compatability. ------------------------------------------------------------------------ r68 | ottrey | 2003-11-18 15:35:05 +1100 (Tue, 18 Nov 2003) | 2 lines Updated the version. ------------------------------------------------------------------------ r67 | ottrey | 2003-11-18 15:33:05 +1100 (Tue, 18 Nov 2003) | 18 lines Changed --verbose=LEVEL to not accept argument and to be issued multiply. (This will make it compatible with Ed's perl grabbers.) So now, verbose level 0 : is achieved by % prog --quiet (ie. QUIET) verbose level 1 : is achieved by % prog (ie. ERROR) verbose level 2 : is achieved by % prog --verbose (ie. WARNING) verbose level 3 : is achieved by % prog --verbose --verbose (ie. INFO) or with the short forms... -q, -v NB. -v is no longer a short form of --version BTW, I'm still using the internal enumeration of QUIET|ERROR|WARNING|INFO, its just that it is no longer supported on the command line. I also neatened up datetime2 a little. ------------------------------------------------------------------------ r65 | ottrey | 2003-11-07 11:54:54 +1100 (Fri, 07 Nov 2003) | 5 lines Added in an attributes argument to addChannel so that icon and url can be added to a channel. (see test cases for an example). Checked in a new version of datetime2.py, hopefully this one works for everyone. ------------------------------------------------------------------------ r64 | rdc | 2003-10-27 14:58:28 +1100 (Mon, 27 Oct 2003) | 2 lines -- Updated datetime2.py I hope it's now fixed - There still was a time.daylight in the nowdt function where a t[8] should have been. ------------------------------------------------------------------------ r62 | rdc | 2003-10-26 14:31:26 +1100 (Sun, 26 Oct 2003) | 2 lines -- Updated datetime2.py Added unittest test to test if there is no faulty DST handling creeping through when adding date's with times. ------------------------------------------------------------------------ r61 | ottrey | 2003-10-17 15:45:26 +1000 (Fri, 17 Oct 2003) | 3 lines It wasn't reporting the exception properly, so now raise Exception instead of UnitTestException. ------------------------------------------------------------------------ r60 | ottrey | 2003-10-17 15:39:46 +1000 (Fri, 17 Oct 2003) | 7 lines Checked in den_RDC changes. Fixed nowdt() to also work for python2.2 Added an "adventurous" test case to test the date, time and timezone returned from the system command "date", with the datetime2 method "nowdt()". ("adventurously" in that I hope that the test will never occur over a 1 second boundary.) ------------------------------------------------------------------------ r59 | gustavo | 2003-09-17 08:44:36 +1000 (Wed, 17 Sep 2003) | 3 lines Automatic call to unittest. ------------------------------------------------------------------------ r57 | ottrey | 2003-09-16 09:47:04 +1000 (Tue, 16 Sep 2003) | 4 lines Fixed some Time matching stuff. The python time library doesn't seem to handle am/pm case-sensitivity. Ie. I can't use "%P" and "%p" only "%p". (see time library for details) ------------------------------------------------------------------------ r56 | gustavo | 2003-09-16 06:35:30 +1000 (Tue, 16 Sep 2003) | 13 lines Improved CustomizedParser, now with unitTests. Problems that may appear: When called to close a tag and another was expected, it goes down the stack, closing all tags until it find the given tag. It helps when you have something, because it automatically closes . But if you have some broken HTML, like I had () it will close ALL your tags, so you need to fix the HTML before. This is not difficult, since it's better to leave open tags instead of close tags that was not opened. urlutils now retry 3 times by default. ------------------------------------------------------------------------ r53 | gustavo | 2003-09-13 15:56:08 +1000 (Sat, 13 Sep 2003) | 3 lines Changed ugly hack to replace & -> & that break grabbers that already converted that. ------------------------------------------------------------------------ r52 | gustavo | 2003-09-13 15:53:24 +1000 (Sat, 13 Sep 2003) | 11 lines XMLTV: Fixed some cases with setStops() CustomizedParser: Fixed translating & -> & br_uol: Use those features, adapt to new style and works as expected again. ------------------------------------------------------------------------ r50 | ottrey | 2003-09-12 10:56:49 +1000 (Fri, 12 Sep 2003) | 2 lines Added a __call__ method, and some more test cases, and pattern matches for Time. ------------------------------------------------------------------------ r47 | ottrey | 2003-09-10 01:07:21 +1000 (Wed, 10 Sep 2003) | 2 lines Ready for alpha release now. ------------------------------------------------------------------------ r45 | ottrey | 2003-09-10 00:50:56 +1000 (Wed, 10 Sep 2003) | 2 lines Getting ready for first alpha release. ------------------------------------------------------------------------ r44 | ottrey | 2003-09-10 00:35:38 +1000 (Wed, 10 Sep 2003) | 3 lines Changed setup.py scripts, to get information for the package distribution. And to run unit tests. ------------------------------------------------------------------------ r39 | ottrey | 2003-09-09 00:42:09 +1000 (Tue, 09 Sep 2003) | 7 lines Gave the setup script a thorough work-over. The distribution is now called: pytvgrab-lib Enforced some unit testing. Added unittest files to the au_aol grabber. Working towards a decent setup script for a grabber. ------------------------------------------------------------------------ r34 | ottrey | 2003-09-08 10:51:32 +1000 (Mon, 08 Sep 2003) | 3 lines Moved grabbers to their own sub-directories. Renamed ./tvgrab to ./lib ------------------------------------------------------------------------ r30 | ottrey | 2003-09-07 01:24:20 +1000 (Sun, 07 Sep 2003) | 2 lines Fixed a bug with double stop times in xmltv. ------------------------------------------------------------------------ r29 | ottrey | 2003-09-06 23:54:44 +1000 (Sat, 06 Sep 2003) | 16 lines Decoupled the grabbers from XMLTV. As now there is no need to create an XMLTV instance in the grabber code. Just pass the generator_info_name to Grab instead, then it instantiates the xmltv. NB. This causes a slight problem if XMLTV need's to be subclassed - eg. to implement a new addProgram method. Affected files: tvgrab/grab.py scripts/tv_grab_example1 scripts/tv_grab_example2 scripts/tv_grab_example3 scripts/tv_grab_example4 scripts/tv_grab_au_aol scripts/tv_grab_be_tvb scripts/tv_grab_br_uol scripts/tv_grab_br_ottrey ------------------------------------------------------------------------ r25 | ottrey | 2003-09-06 17:40:52 +1000 (Sat, 06 Sep 2003) | 2 lines addProgram's info, can now take lists - eg. actor lists. ------------------------------------------------------------------------ r24 | ottrey | 2003-09-06 17:28:18 +1000 (Sat, 06 Sep 2003) | 3 lines Renaming all instances of 'programme' to 'program' in accordance with the American English namings scheme. ------------------------------------------------------------------------ r23 | ottrey | 2003-09-06 17:18:55 +1000 (Sat, 06 Sep 2003) | 5 lines Now using the new message module. Also imports from the new datetime2 module on behalf of the grabbers that will subclass from it. Ie. Date, Time, DateTime and today are now available from this module. ------------------------------------------------------------------------ r22 | ottrey | 2003-09-06 17:15:13 +1000 (Sat, 06 Sep 2003) | 12 lines Changed to use the new message module. Ie. it doesn't have to inherit from Message now. Also added in den_RDC's addProgramme(). I don't think it is going to work too well with the change to the new DTD. As you need detailed knowledge of the DTD. Eg. to add a 'rating' you need to set the info dictionary to: {'rating': {'value': 'G'}} as the 0.5.15 DTD defines rating as G But it's a pretty good way of doing things for now, so I've added it in. As none of the three grabbers need to re-implement addProgramme() now. ------------------------------------------------------------------------ r21 | ottrey | 2003-09-06 17:10:54 +1000 (Sat, 06 Sep 2003) | 2 lines This module has been renamed to datetime2.py ------------------------------------------------------------------------ r20 | ottrey | 2003-09-06 17:09:43 +1000 (Sat, 06 Sep 2003) | 2 lines This is the old mytypes module. ------------------------------------------------------------------------ r19 | ottrey | 2003-09-06 17:08:04 +1000 (Sat, 06 Sep 2003) | 2 lines Removed mytypes. ------------------------------------------------------------------------ r18 | ottrey | 2003-09-06 17:06:58 +1000 (Sat, 06 Sep 2003) | 2 lines Now handles SystemExit exception properly and uses the new datetime2 module. ------------------------------------------------------------------------ r17 | ottrey | 2003-09-06 17:04:11 +1000 (Sat, 06 Sep 2003) | 17 lines Changed to make it easier to use from other modules. No need to inherit from Message now. It is now used in the following way: import message message.info('this is an info message') message.warning('this is a warning message') And the verbose level is kept inside the message module. So any module using message will refer to that level. NB. It can be changed "globally" like this: message.verbose=message.verbose_level.INFO or message.verbose=message.get_value('INFO') ------------------------------------------------------------------------ r16 | ottrey | 2003-09-04 23:47:27 +1000 (Thu, 04 Sep 2003) | 13 lines Added more test cases. now works for: - (EST - Australia/Brisbane a non-daylight savings region) Southern Hemisphere, east of UTC in September - (CEST - Europe/Brussles) Northern Hemisphere, east of UTC in September - (PDT - US/Eastern) Northern Hemisphere, west of UTC in September doesn't work for: - (EST - Australia/Melbourne a daylight savings region) Southern Hemisphere, east of UTC in September (I think this might be because of a bug in the time library.) ------------------------------------------------------------------------ r15 | ottrey | 2003-09-02 23:29:00 +1000 (Tue, 02 Sep 2003) | 2 lines Added a __repr__ function. ------------------------------------------------------------------------ r13 | ottrey | 2003-09-02 18:40:16 +1000 (Tue, 02 Sep 2003) | 4 lines I think I fixed the daylight savings problem. Added a comparision method, to implement stuff like if t < Time('6am'): ------------------------------------------------------------------------ r12 | ottrey | 2003-09-02 12:05:48 +1000 (Tue, 02 Sep 2003) | 2 lines Fixed daylight saving problem that was causing DateTime unit test #3 to fail. ------------------------------------------------------------------------ r11 | ottrey | 2003-09-02 11:52:24 +1000 (Tue, 02 Sep 2003) | 2 lines removed the sum() function as it's only available in python2.3 ------------------------------------------------------------------------ r10 | rdc | 2003-09-02 11:47:26 +1000 (Tue, 02 Sep 2003) | 3 lines customizedparser: fixed out-of date version, now handles must_close_tags correctly ------------------------------------------------------------------------ r9 | ottrey | 2003-09-02 11:04:34 +1000 (Tue, 02 Sep 2003) | 2 lines Fixed unit test numbering. ------------------------------------------------------------------------ r7 | ottrey | 2003-09-02 03:07:44 +1000 (Tue, 02 Sep 2003) | 7 lines Made some _major_ additions to the mytypes module. now provides functions like Date()+1, returns the next day. Also made some changes to the xmltv module. Made some changes to grab, after looking at tv_grab_be. Changed tv_grab_br_uol to suit. (Doh! forgot to add tv_grab_be) ------------------------------------------------------------------------ r1 | rdc | 2003-09-01 11:12:39 +1000 (Mon, 01 Sep 2003) | 2 lines initial source checkin - from oldversion 0.1.0-4a ------------------------------------------------------------------------