- **status**: open --> pending
- **assigned_to**: Legoktm
---
** [feature-requests:#346] claimit.py: lang for source lookup**
**Status:** pending
**Created:** Sat Aug 31, 2013 12:40 PM UTC by APAC
**Last Updated:** Sat Aug 31, 2013 12:40 PM UTC
**Owner:** Legoktm
def setSource(self, lang):
page = pywikibot.Page(self.repo, 'Wikidata:List of wikis/python')
source_values = json.loads(page.get())
source_values = source_values['wikipedia']
for lang in source_values:
source_values[lang] = pywikibot.ItemPage(self.repo,
source_values[lang])
if lang in source_values:
self.source = pywikibot.Claim(self.repo, 'p143')
self.source.setTarget(source_values.get(lang))
The use of lang in "for lang in source_values:" overwrites the lang in "def setSource(self, lang)". This leads to incorrect results. "lang" should be the language of the source wiki. For -cat:"zh:Category:Somevalue" this would be "zh".
---
Sent from sourceforge.net because Pywikipedia-bugs(a)lists.wikimedia.org is subscribed to https://sourceforge.net/p/pywikipediabot/feature-requests/
To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/pywikipediabot/admin/feature-requests/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.
https://gerrit.wikimedia.org/r/#/c/82106/
---
** [feature-requests:#346] claimit.py: lang for source lookup**
**Status:** pending
**Created:** Sat Aug 31, 2013 12:40 PM UTC by APAC
**Last Updated:** Sat Aug 31, 2013 12:40 PM UTC
**Owner:** Legoktm
def setSource(self, lang):
page = pywikibot.Page(self.repo, 'Wikidata:List of wikis/python')
source_values = json.loads(page.get())
source_values = source_values['wikipedia']
for lang in source_values:
source_values[lang] = pywikibot.ItemPage(self.repo,
source_values[lang])
if lang in source_values:
self.source = pywikibot.Claim(self.repo, 'p143')
self.source.setTarget(source_values.get(lang))
The use of lang in "for lang in source_values:" overwrites the lang in "def setSource(self, lang)". This leads to incorrect results. "lang" should be the language of the source wiki. For -cat:"zh:Category:Somevalue" this would be "zh".
---
Sent from sourceforge.net because Pywikipedia-bugs(a)lists.wikimedia.org is subscribed to https://sourceforge.net/p/pywikipediabot/feature-requests/
To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/pywikipediabot/admin/feature-requests/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.
---
** [feature-requests:#346] claimit.py: lang for source lookup**
**Status:** open
**Created:** Sat Aug 31, 2013 12:40 PM UTC by APAC
**Last Updated:** Sat Aug 31, 2013 12:40 PM UTC
**Owner:** nobody
def setSource(self, lang):
page = pywikibot.Page(self.repo, 'Wikidata:List of wikis/python')
source_values = json.loads(page.get())
source_values = source_values['wikipedia']
for lang in source_values:
source_values[lang] = pywikibot.ItemPage(self.repo,
source_values[lang])
if lang in source_values:
self.source = pywikibot.Claim(self.repo, 'p143')
self.source.setTarget(source_values.get(lang))
The use of lang in "for lang in source_values:" overwrites the lang in "def setSource(self, lang)". This leads to incorrect results. "lang" should be the language of the source wiki. For -cat:"zh:Category:Somevalue" this would be "zh".
---
Sent from sourceforge.net because Pywikipedia-bugs(a)lists.wikimedia.org is subscribed to https://sourceforge.net/p/pywikipediabot/feature-requests/
To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/pywikipediabot/admin/feature-requests/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.
Ok, I see the issue here. claimit.py was designed to be run on a client site, not on the datasite itself. I'll get around to fixing this soon.
---
** [feature-requests:#341] Create pagegenerators for Wikidata (items from file, items using a given property, items linking to items, etc)**
**Status:** open
**Created:** Thu Aug 29, 2013 03:50 AM UTC by APAC
**Last Updated:** Sat Aug 31, 2013 06:59 AM UTC
**Owner:** Legoktm
Currently pagegenerators.py doesn't seem to work for Wikidata. Either existing generators would need to be adapted or new ones created.
---
Sent from sourceforge.net because Pywikipedia-bugs(a)lists.wikimedia.org is subscribed to https://sourceforge.net/p/pywikipediabot/feature-requests/
To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/pywikipediabot/admin/feature-requests/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.
- **assigned_to**: Legoktm
---
** [feature-requests:#341] Create pagegenerators for Wikidata (items from file, items using a given property, items linking to items, etc)**
**Status:** open
**Created:** Thu Aug 29, 2013 03:50 AM UTC by APAC
**Last Updated:** Sat Aug 31, 2013 06:59 AM UTC
**Owner:** Legoktm
Currently pagegenerators.py doesn't seem to work for Wikidata. Either existing generators would need to be adapted or new ones created.
---
Sent from sourceforge.net because Pywikipedia-bugs(a)lists.wikimedia.org is subscribed to https://sourceforge.net/p/pywikipediabot/feature-requests/
To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/pywikipediabot/admin/feature-requests/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.
Actually, it also has
WARNING: API warning (wbgetentities): Unrecognized value for parameter 'sites':
wikidatawiki
config is set with:
family = 'wikidata'
mylang = 'wikidata'
---
** [feature-requests:#341] Create pagegenerators for Wikidata (items from file, items using a given property, items linking to items, etc)**
**Status:** open
**Created:** Thu Aug 29, 2013 03:50 AM UTC by APAC
**Last Updated:** Sat Aug 31, 2013 06:14 AM UTC
**Owner:** nobody
Currently pagegenerators.py doesn't seem to work for Wikidata. Either existing generators would need to be adapted or new ones created.
---
Sent from sourceforge.net because Pywikipedia-bugs(a)lists.wikimedia.org is subscribed to https://sourceforge.net/p/pywikipediabot/feature-requests/
To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/pywikipediabot/admin/feature-requests/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.
It might be faster as the items could be stored in the generator.
---
** [feature-requests:#345] claimit.py sample: add option to read from file (list of items and properties)**
**Status:** open
**Created:** Thu Aug 29, 2013 03:57 AM UTC by APAC
**Last Updated:** Thu Aug 29, 2013 06:33 AM UTC
**Owner:** nobody
---
Sent from sourceforge.net because Pywikipedia-bugs(a)lists.wikimedia.org is subscribed to https://sourceforge.net/p/pywikipediabot/feature-requests/
To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/pywikipediabot/admin/feature-requests/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.
Something like
pwb.py claimit -ref:"Property:P1234" P123 Q1234567 -namespace:0
throws an error:
pywikibot.data.api.APIError: param-missing: Either provide the item "ids" or pairs of "sites" and "titles" for corresponding pages.
Maybe it was fixed in last weeks update.
---
** [feature-requests:#341] Create pagegenerators for Wikidata (items from file, items using a given property, items linking to items, etc)**
**Status:** open
**Created:** Thu Aug 29, 2013 03:50 AM UTC by APAC
**Last Updated:** Thu Aug 29, 2013 06:30 AM UTC
**Owner:** nobody
Currently pagegenerators.py doesn't seem to work for Wikidata. Either existing generators would need to be adapted or new ones created.
---
Sent from sourceforge.net because Pywikipedia-bugs(a)lists.wikimedia.org is subscribed to https://sourceforge.net/p/pywikipediabot/feature-requests/
To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/pywikipediabot/admin/feature-requests/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.
- **status**: pending-fixed --> closed-fixed
---
** [bugs:#1660] Can't set claim target due to an AttributeError**
**Status:** closed-fixed
**Created:** Thu Aug 29, 2013 09:44 AM UTC by Wieland Hoffmann
**Last Updated:** Thu Aug 29, 2013 03:43 PM UTC
**Owner:** Legoktm
Executing the following code
:::python
import pywikibot as wp
s = wp.Site('wikidata', 'wikidata')
d = s.data_repository()
m = wp.ItemPage(d, 'Q14005')
c = wp.Claim(s, "P248")
c.setTarget(m)
results in a short traceback ending in "AttributeError: APISite instance has no attribute 'getPropertyType'". According to git bisect, the first commit showing this behaviour is 8f1c2631215b340acf962ae1a0fa7ffcefe84df5 (or svn revision 11600).
Output from python version.py:
Pywikibot: [ssh] pywikibot/core (r1995, fa7a248, 2013/08/28, 22:33:44, ok)
Release version: 2.0b1
Python: 2.7.5 (default, May 12 2013, 12:00:47)
[GCC 4.8.0 20130502 (prerelease)]
unicode test: ok
---
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.
Looked into this a bit.
I've managed to isolate the problem to ~line 237 where all the txt2timestamp functions are. It seems that all of them are raising ValueErrors.
---
** [bugs:#1482] archivebot.py doesn't support unicode month names**
**Status:** open
**Created:** Sat Jun 30, 2012 05:50 PM UTC by Anonymous
**Last Updated:** Sat Jun 30, 2012 05:50 PM UTC
**Owner:** nobody
archivebot.py doesn't work well with languages such as Turkish which has some months with unicode characters. Namely:
2 Şubat
4 Mayıs
8 Ağustos
9 Eylül
11 Kasım
12 Aralık
---
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.