Issue 328 in specto: user agent setting?

4 views
Skip to first unread message

spe...@googlecode.com

unread,
Apr 8, 2011, 9:25:00 PM4/8/11
to specto...@googlegroups.com
Status: New
Owner: ----

New issue 328 by nsw.prot...@gmail.com: user agent setting?
http://code.google.com/p/specto/issues/detail?id=328

Some site, like wikipedia return a 403 forbidden, I'm guessing because of
the user agent? Can there be an option for setting a custom user agent?


spe...@googlecode.com

unread,
Apr 16, 2011, 1:13:01 AM4/16/11
to specto...@googlegroups.com
Updates:
Labels: WatchType-Web Type-Defect

Comment #1 on issue 328 by nekoh...@gmail.com: user agent setting?
http://code.google.com/p/specto/issues/detail?id=328

Hey there, I don't experience this problem. Please specify your version, if
possible test with the bzr version, and activate debug mode to provide
debug logs.

The development version of Specto already identifies as Specto for its user
agent.

spe...@googlecode.com

unread,
Apr 16, 2011, 1:17:02 AM4/16/11
to specto...@googlegroups.com
Updates:
Status: Needinfo

Comment #2 on issue 328 by nekoh...@gmail.com: user agent setting?
http://code.google.com/p/specto/issues/detail?id=328

(No comment was entered for this change.)

spe...@googlecode.com

unread,
Dec 31, 2011, 9:59:54 AM12/31/11
to specto...@googlegroups.com

Comment #3 on issue 328 by julien.l...@gmail.com: user agent setting?
http://code.google.com/p/specto/issues/detail?id=328

I have the same issue with Wikipedia. I use version Specto 0.3.1 that is
bundled with Ubuntu 10.04 LTS.

The last agent that you see in this window with the forbidden icon is set
to watch http://en.wikinews.org/wiki/Portal:Canada

Attachments:
spectoWikipediaForbidden.png 83.5 KB

spe...@googlecode.com

unread,
Dec 31, 2011, 10:03:55 AM12/31/11
to specto...@googlegroups.com

Comment #4 on issue 328 by julien.l...@gmail.com: user agent setting?
http://code.google.com/p/specto/issues/detail?id=328

Sorry, imaged attached.

Attachments:
spectoWikipediaForbidden.png 77.0 KB

spe...@googlecode.com

unread,
Dec 31, 2011, 10:28:59 AM12/31/11
to specto...@googlegroups.com

Comment #5 on issue 328 by nekoh...@gmail.com: user agent setting?
http://code.google.com/p/specto/issues/detail?id=328

Well, you could edit spectlib/plugins/watch_web_static.py and replace the
custom agent in there. Otherwise I'd need a patch that makes this a
behavior dependent on a gconf key :)

spe...@googlecode.com

unread,
Dec 31, 2011, 11:32:14 AM12/31/11
to specto...@googlegroups.com

Comment #6 on issue 328 by julien.l...@gmail.com: user agent setting?
http://code.google.com/p/specto/issues/detail?id=328

Ok. I'm guessing that would be line 102 of the file in question:

102 request = web_proxy.urllib2.Request(self.uri, None,
{"Accept-encoding": "gzip"}

Reading the documentation at

http://docs.python.org/dev/library/urllib.request

I think I can figure out how to modify that line.

spe...@googlecode.com

unread,
Dec 31, 2011, 1:18:36 PM12/31/11
to specto...@googlegroups.com

Comment #7 on issue 328 by nekoh...@gmail.com: user agent setting?
http://code.google.com/p/specto/issues/detail?id=328

Nah, just search for "agent" in that file :) it's the line right above it
in my case.

Reply all
Reply to author
Forward
0 new messages