mspieth / rssdler

Automatically exported from code.google.com/p/rssdler
4 stars 0 forks source link

Error on execution - 'NoneType' object has no attribute 'count' #33

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. run using rssdler -r on MacOS 10.5 system

What is the expected output? What do you see instead?
INFO --- RSSDler 0.4.1a1
DEBUG writing daemonInfo
INFO [Waking up] Fri Nov  7 04:25:16 2008
DEBUG checking working dir, maybe changing dir
INFO Scanning threads
INFO finding new downloads in thread tvtorrentz
CRITICAL 2070 Unexpected Error: Traceback (most recent call last):
  File "/Library/Python/2.5/site-packages/rssdler.py", line 2067, in main
    run()
  File "/Library/Python/2.5/site-packages/rssdler.py", line 2037, in run
    rssparse(key)
  File "/Library/Python/2.5/site-packages/rssdler.py", line 1882, in rssparse
    try: page = downloader(getConfig()['threads'][tName]['link'])
  File "/Library/Python/2.5/site-packages/rssdler.py", line 601, in mechRetrievePage
    url, urlNotEncoded = encodeQuoteUrl( url, encoding='utf-8' ), url
  File "/Library/Python/2.5/site-packages/rssdler.py", line 385, in encodeQuoteUrl
    if not percentIsQuoted(url) and percentNeedsQuoted(url):
  File "/Library/Python/2.5/site-packages/rssdler.py", line 343, in percentIsQuoted
    if sStr.count(i): return True
AttributeError: 'NoneType' object has no attribute 'count'

Traceback (most recent call last):
  File "/usr/bin/rssdler", line 13, in <module>
    rssdler._main(sys.argv)
  File "/Library/Python/2.5/site-packages/rssdler.py", line 2294, in _main
    main()
  File "/Library/Python/2.5/site-packages/rssdler.py", line 2067, in main
    run()
  File "/Library/Python/2.5/site-packages/rssdler.py", line 2037, in run
    rssparse(key)
  File "/Library/Python/2.5/site-packages/rssdler.py", line 1882, in rssparse
    try: page = downloader(getConfig()['threads'][tName]['link'])
  File "/Library/Python/2.5/site-packages/rssdler.py", line 601, in mechRetrievePage
    url, urlNotEncoded = encodeQuoteUrl( url, encoding='utf-8' ), url
  File "/Library/Python/2.5/site-packages/rssdler.py", line 385, in encodeQuoteUrl
    if not percentIsQuoted(url) and percentNeedsQuoted(url):
  File "/Library/Python/2.5/site-packages/rssdler.py", line 343, in percentIsQuoted
    if sStr.count(i): return True
AttributeError: 'NoneType' object has no attribute 'count'

> /Library/Python/2.5/site-packages/rssdler.py(343)percentIsQuoted()
-> if sStr.count(i): return True

What version of the product are you using? On what operating system?
Both the 0.4.0a and the svn version give the error

Please provide any additional information below.

Original issue reported on code.google.com by adda...@gmail.com on 7 Nov 2008 at 9:31

GoogleCodeExporter commented 8 years ago
I think I've got the same problem. I'm running Ubuntu 8.04 and RSSdler 0.4.0a.
Sometimes rssdler works but quite often I get an error message. Below is the 
output
when i run rssdler -r:
CRITICAL main 2047 Unexpected Error: Traceback (most recent call last):
  File "/usr/lib/python2.5/site-packages/rssdler.py", line 2044, in main
    run()
  File "/usr/lib/python2.5/site-packages/rssdler.py", line 2016, in run
    rssparse(key)
  File "/usr/lib/python2.5/site-packages/rssdler.py", line 1863, in rssparse
    try: page = downloader(getConfig()['threads'][tName]['link'])
  File "/usr/lib/python2.5/site-packages/rssdler.py", line 582, in mechRetrievePage
    url, urlNotEncoded = encodeQuoteUrl( url, encoding='utf-8' ), url
  File "/usr/lib/python2.5/site-packages/rssdler.py", line 385, in encodeQuoteUrl
    if not percentIsQuoted(url) and percentNeedsQuoted(url):
  File "/usr/lib/python2.5/site-packages/rssdler.py", line 343, in percentIsQuoted
    if sStr.count(i): return True
AttributeError: 'NoneType' object has no attribute 'count'

Traceback (most recent call last):
  File "/usr/bin/rssdler", line 13, in <module>
    rssdler._main(sys.argv)
  File "/usr/lib/python2.5/site-packages/rssdler.py", line 2271, in _main
    main()
  File "/usr/lib/python2.5/site-packages/rssdler.py", line 2044, in main
    run()
  File "/usr/lib/python2.5/site-packages/rssdler.py", line 2016, in run
    rssparse(key) 
  File "/usr/lib/python2.5/site-packages/rssdler.py", line 1863, in rssparse
    try: page = downloader(getConfig()['threads'][tName]['link'])
  File "/usr/lib/python2.5/site-packages/rssdler.py", line 582, in mechRetrievePage
    url, urlNotEncoded = encodeQuoteUrl( url, encoding='utf-8' ), url
  File "/usr/lib/python2.5/site-packages/rssdler.py", line 385, in encodeQuoteUrl
    if not percentIsQuoted(url) and percentNeedsQuoted(url):
  File "/usr/lib/python2.5/site-packages/rssdler.py", line 343, in percentIsQuoted
    if sStr.count(i): return True
AttributeError: 'NoneType' object has no attribute 'count'

Original comment by fell...@gmail.com on 12 Nov 2008 at 1:48

GoogleCodeExporter commented 8 years ago
That's because your config.txt has errors, fix the errors and it'll be fine.

Original comment by neobe...@gmail.com on 8 Dec 2008 at 6:29

GoogleCodeExporter commented 8 years ago
Indeed, I had somehow omitted 'link ='  in front of the RSS URL in the config 
file.  Thanks for the help.

Original comment by adda...@gmail.com on 31 Dec 2008 at 11:48

GoogleCodeExporter commented 8 years ago
It is an idea to throw a descriptive error message like "your config.txt has 
errors"
instead of "AttributeError: 'NoneType' object has no attribute 'count'"....

Original comment by sixjo...@gmail.com on 16 Apr 2009 at 9:21

GoogleCodeExporter commented 8 years ago

Original comment by lostnihi...@gmail.com on 22 Aug 2009 at 8:13