What are you saying about the version of python is not correct because this is trunk branch not rewrite branch and in this branch we don't have setSource as a method of claim class, It's just a function in this code
---
** [bugs:#1634] harvest template syntax error**
**Status:** open-accepted
**Created:** Fri May 24, 2013 10:33 PM UTC by masti
**Last Updated:** Tue Jun 25, 2013 12:35 PM UTC
**Owner:** nobody
$python harvest\_template.py -cat:"Miasta Polski"
File "harvest\_template.py", line 116
item.editclaim\(str\(claim\), linkedItem.getID\(\) ,refs=\{self.setSource\(self.site\(\).language\(\)\)\}\)
^
SyntaxError: invalid syntax
$ python version.py
unicode test: triggers problem \#3081100
Pywikipedia \[http\] trunk/pywikipedia \(r11578, 2013/05/24, 17:03:42, ok\)
Python 2.6.6 \(r266:84292, Oct 12 2012, 14:23:48\)
\[GCC 4.4.6 20120305 \(Red Hat 4.4.6-4\)\]
config-settings:
use\_api = True
use\_api\_login = True
unicode test: triggers problem \#3081100
---
Sent from sourceforge.net because Pywikipedia-bugs(a)lists.wikimedia.org is subscribed to https://sourceforge.net/p/pywikipediabot/bugs/
To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/pywikipediabot/admin/bugs/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.
---
** [bugs:#1634] harvest template syntax error**
**Status:** open-accepted
**Created:** Fri May 24, 2013 10:33 PM UTC by masti
**Last Updated:** Tue Jun 25, 2013 12:35 PM UTC
**Owner:** nobody
$python harvest\_template.py -cat:"Miasta Polski"
File "harvest\_template.py", line 116
item.editclaim\(str\(claim\), linkedItem.getID\(\) ,refs=\{self.setSource\(self.site\(\).language\(\)\)\}\)
^
SyntaxError: invalid syntax
$ python version.py
unicode test: triggers problem \#3081100
Pywikipedia \[http\] trunk/pywikipedia \(r11578, 2013/05/24, 17:03:42, ok\)
Python 2.6.6 \(r266:84292, Oct 12 2012, 14:23:48\)
\[GCC 4.4.6 20120305 \(Red Hat 4.4.6-4\)\]
config-settings:
use\_api = True
use\_api\_login = True
unicode test: triggers problem \#3081100
---
Sent from sourceforge.net because Pywikipedia-bugs(a)lists.wikimedia.org is subscribed to https://sourceforge.net/p/pywikipediabot/bugs/
To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/pywikipediabot/admin/bugs/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.
{self.setSource(self.site().language())} is allowed in python 2.7 but not in python 2.6. I think we want to keep python 2.6 compatibility, right?
---
** [bugs:#1634] harvest template syntax error**
**Status:** open-accepted
**Created:** Fri May 24, 2013 10:33 PM UTC by masti
**Last Updated:** Mon Jun 24, 2013 03:13 PM UTC
**Owner:** nobody
$python harvest\_template.py -cat:"Miasta Polski"
File "harvest\_template.py", line 116
item.editclaim\(str\(claim\), linkedItem.getID\(\) ,refs=\{self.setSource\(self.site\(\).language\(\)\)\}\)
^
SyntaxError: invalid syntax
$ python version.py
unicode test: triggers problem \#3081100
Pywikipedia \[http\] trunk/pywikipedia \(r11578, 2013/05/24, 17:03:42, ok\)
Python 2.6.6 \(r266:84292, Oct 12 2012, 14:23:48\)
\[GCC 4.4.6 20120305 \(Red Hat 4.4.6-4\)\]
config-settings:
use\_api = True
use\_api\_login = True
unicode test: triggers problem \#3081100
---
Sent from sourceforge.net because Pywikipedia-bugs(a)lists.wikimedia.org is subscribed to https://sourceforge.net/p/pywikipediabot/bugs/
To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/pywikipediabot/admin/bugs/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.
- **status**: closed-works-for-me --> open-accepted
---
** [bugs:#1634] harvest template syntax error**
**Status:** open-accepted
**Created:** Fri May 24, 2013 10:33 PM UTC by masti
**Last Updated:** Mon Jun 24, 2013 03:13 PM UTC
**Owner:** nobody
$python harvest\_template.py -cat:"Miasta Polski"
File "harvest\_template.py", line 116
item.editclaim\(str\(claim\), linkedItem.getID\(\) ,refs=\{self.setSource\(self.site\(\).language\(\)\)\}\)
^
SyntaxError: invalid syntax
$ python version.py
unicode test: triggers problem \#3081100
Pywikipedia \[http\] trunk/pywikipedia \(r11578, 2013/05/24, 17:03:42, ok\)
Python 2.6.6 \(r266:84292, Oct 12 2012, 14:23:48\)
\[GCC 4.4.6 20120305 \(Red Hat 4.4.6-4\)\]
config-settings:
use\_api = True
use\_api\_login = True
unicode test: triggers problem \#3081100
---
Sent from sourceforge.net because Pywikipedia-bugs(a)lists.wikimedia.org is subscribed to https://sourceforge.net/p/pywikipediabot/bugs/
To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/pywikipediabot/admin/bugs/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.
- **status**: open --> closed-works-for-me
- **Group**: --> confirmed
---
** [bugs:#1634] harvest template syntax error**
**Status:** closed-works-for-me
**Created:** Fri May 24, 2013 10:33 PM UTC by masti
**Last Updated:** Mon Jun 24, 2013 03:02 PM UTC
**Owner:** nobody
$python harvest\_template.py -cat:"Miasta Polski"
File "harvest\_template.py", line 116
item.editclaim\(str\(claim\), linkedItem.getID\(\) ,refs=\{self.setSource\(self.site\(\).language\(\)\)\}\)
^
SyntaxError: invalid syntax
$ python version.py
unicode test: triggers problem \#3081100
Pywikipedia \[http\] trunk/pywikipedia \(r11578, 2013/05/24, 17:03:42, ok\)
Python 2.6.6 \(r266:84292, Oct 12 2012, 14:23:48\)
\[GCC 4.4.6 20120305 \(Red Hat 4.4.6-4\)\]
config-settings:
use\_api = True
use\_api\_login = True
unicode test: triggers problem \#3081100
---
Sent from sourceforge.net because Pywikipedia-bugs(a)lists.wikimedia.org is subscribed to https://sourceforge.net/p/pywikipediabot/bugs/
To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/pywikipediabot/admin/bugs/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.
There is no syntax error in the actual (r11579) code:
>>> import harvest_template
>>>
---
** [bugs:#1634] harvest template syntax error**
**Status:** open
**Created:** Fri May 24, 2013 10:33 PM UTC by masti
**Last Updated:** Fri May 24, 2013 10:33 PM UTC
**Owner:** nobody
$python harvest\_template.py -cat:"Miasta Polski"
File "harvest\_template.py", line 116
item.editclaim\(str\(claim\), linkedItem.getID\(\) ,refs=\{self.setSource\(self.site\(\).language\(\)\)\}\)
^
SyntaxError: invalid syntax
$ python version.py
unicode test: triggers problem \#3081100
Pywikipedia \[http\] trunk/pywikipedia \(r11578, 2013/05/24, 17:03:42, ok\)
Python 2.6.6 \(r266:84292, Oct 12 2012, 14:23:48\)
\[GCC 4.4.6 20120305 \(Red Hat 4.4.6-4\)\]
config-settings:
use\_api = True
use\_api\_login = True
unicode test: triggers problem \#3081100
---
Sent from sourceforge.net because Pywikipedia-bugs(a)lists.wikimedia.org is subscribed to https://sourceforge.net/p/pywikipediabot/bugs/
To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/pywikipediabot/admin/bugs/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.
- **status**: open --> closed
---
** [bugs:#1637] Test ticket for bugs-l**
**Status:** closed
**Created:** Sun Jun 16, 2013 02:13 PM UTC by Merlijn S. van Deen
**Last Updated:** Sun Jun 16, 2013 02:22 PM UTC
**Owner:** nobody
yadayada
---
Sent from sourceforge.net because you indicated interest in <https://sourceforge.net/p/pywikipediabot/bugs/1637/>
To unsubscribe from further messages, please visit <https://sourceforge.net/auth/subscriptions/>
Patches item #3614398, was opened at 2013-06-07 03:04
Message generated for change (Comment added) made by amird
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=603140&aid=3614398&group_…
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Luca Rabinelli (beta16)
>Assigned to: Amir (amird)
Summary: WikiData: property datatype
Initial Comment:
in file attached there's a simple function for determine datatype of a wikidata property via API, instead use of "isinstance".
Useful in DataPage.editclaim()
----------------------------------------------------------------------
>Comment By: Amir (amird)
Date: 2013-06-11 09:06
Message:
Looks good, I will commit and make related changes
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=603140&aid=3614398&group_…
Bugs item #3538008, was opened at 2012-06-25 21:52
Message generated for change (Comment added) made by nobody
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=603138&aid=3538008&group_…
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: James (jaclayiii)
Assigned to: Nobody/Anonymous (nobody)
Summary: *-login.data can have case discrepency on Linux host
Initial Comment:
Pywikipedia [http] trunk/pywikipedia (r10401, 2012/06/21, 06:18:43)
Python 2.7.2+ (default, Oct 4 2011, 20:06:09)
[GCC 4.6.1]
config-settings:
use_api = True
use_api_login = True
unicode test: ok
Summary: the *-login.data file maybe saved with an uppercase username but when load cookies tries to find it on a Linux host, the case of the username maybe lower. This has the unintended consequence of not allowing bots to login on private wikis that have anonymous read api rights disabled.
If a user connects to a wiki that has LDAP or some other form of "add-on" authentication, the user name returned may vary in case from what is in the user-config.py file. The reason this matters is that the <wikifamily>-<language>-<username>-login.data file may be saved with an upper case letter in the username. Thus if the user-config.py file contained:
users["mywiki"]["en"]="james"
but the LDAP authenticator returned back "James" as the username, then the *-login.data file would be mywiki-en-James-login.data, but when _loadcookies goes to look for such a file on line 5572:
if os.path.exists(localPA)
localPA is /~some/path/to/mywiki-en-james-login.data
Notice that the James is now lower case in the file above.
As Linux is case sensitive, it cannot find the login data and thus prevents access to wikis the do not allow anonymous access to api's. A temporary work around requires setting user name to the appropriate case (even if the username is case insensitive in the LDAP authentication scheme), for example:
users["mywiki"]["en"]="James"
keywords: SSL, Login failure, https login failure, https linux login, https pywikipedia, https pywikipedia linux
----------------------------------------------------------------------
Comment By: Nobody/Anonymous (nobody)
Date: 2013-06-09 19:57
Message:
mwyHgt <a href="http://sivhbtbyssot.com/">sivhbtbyssot</a>,
[url=http://rhecwdzrqubz.com/]rhecwdzrqubz[/url],
[link=http://izhdiwwkxgsa.com/]izhdiwwkxgsa[/link],
http://coiapkvdjaci.com/
----------------------------------------------------------------------
Comment By: Nobody/Anonymous (nobody)
Date: 2013-05-31 05:13
Message:
ET0EqF I truly appreciate this blog article.Really thank you! Will read
on... http://point.md/
----------------------------------------------------------------------
Comment By: Nobody/Anonymous (nobody)
Date: 2013-03-14 21:16
Message:
Hey! Do you use Twitter? I'llike to follow you if that would be ok. I'm
certainly enjoying your blog and look forward to new updates. louis vuitton
replicated bags http://www.louisvuittonreplicago.com/
----------------------------------------------------------------------
Comment By: Nobody/Anonymous (nobody)
Date: 2013-03-13 06:44
Message:
I have been taking Japan Lingzhi 2 Day Diet
http://udaydiets.cocolog-nifty.com/ for a week and lost 5 pounds.the
initial issue within the morning is take this pill with an empty stomach
and it appears to create my appetite disappear. this is considerably
stronger than any other merchandise. and i choose to take 2 tablets within
the future.
----------------------------------------------------------------------
Comment By: James (jaclayiii)
Date: 2012-06-26 15:20
Message:
After thinking even more on this issue, even for those not using LDAP
authentication (which I would assume the majority are not using), correct
casing based on the user-config file shouldn't have undesirable effects: if
you can log in with what's in the user config file then correctly saving
the cookie file with that username shouldn't negatively impact anything. On
the other hand if you do not save the cookie file with the same user name
that is in the user-config file, but you continue to use the user-config
file to generate the localPA variable, then you may have problems on case
sensitive platforms.
If this fix seems to difficult (I don't believe it to be) or you're
suspicious of the logic, you may want to place a warning in the setup
instructions. I've added a comment on the wiki for userconfig.py that
people using *nix systems should be aware that by default mediawiki has
uppercase user names.
----------------------------------------------------------------------
Comment By: James (jaclayiii)
Date: 2012-06-26 12:08
Message:
After rereading the LDAP link, you're probably right in that the it's the
actual mediawiki login that is forcing uppercase, nonetheless the file name
that pywiki attempts to find should be case correct irrelevant of the
username supplied or returned. My thought for that fix has to do with
correctly saving the *-login.data cookie with the username found in
user-config.py.
----------------------------------------------------------------------
Comment By: James (jaclayiii)
Date: 2012-06-26 11:59
Message:
It has very much to do with LDAP:
http://www.mediawiki.org/wiki/Extension:LDAP_Authentication/User_Provided_I…
And it has very much to do with Linux: Linux path names are case sensitive.
I reported the bug as it took me time to track down and perhaps someone
else who has the misfortune of dealing with it will find this helpful.
The fact is that if I can login with a lower case name, and I can, then
whatever pywiki stores should be in the same case, NOT what may be returned
when the wiki user name is returned. The file name for *-login.data should
be the same case as what is stored in user-config.py
This is just good practice, especially on a case sensitive host like
Linux.
Also, as mediawiki is authenticating against LDAP, whatever it stores as
the username is irrelevant if it correctly authenticates. A further reason
to enforce correct casing based on the user-config.py file.
----------------------------------------------------------------------
Comment By: Merlijn S. van Deen (valhallasw)
Date: 2012-06-26 03:27
Message:
This has very little to do with Linux or LDAP, but rather has to do with
the fact your username is 'James' and not 'james'. This is related to the
'first character is capitalized' convention on some wikis, but not all
(!).
However, we could probably check whether the name has changed when the user
is logged in and emit a warning when this happens (and/or store the cookie
with the username as saved in the config file, but that could have some
unintended consequences).
----------------------------------------------------------------------
Comment By: James (jaclayiii)
Date: 2012-06-25 21:56
Message:
Quick comment: _loadCookies() is in wikipedia.py on line 5534
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=603138&aid=3538008&group_…