totoazero created this task.
totoazero added a subscriber: totoazero.
totoazero added a project: pywikibot-core.
totoazero moved this task to Backlog on the pywikibot-core workboard.
Herald added subscribers: pywikibot-bugs-list, Aklapper.
TASK DESCRIPTION
I used the following with an older version of pywikibot :
```
[page for page in cat.articles(starttime=timestamp, sortby='timestamp',
namespaces=[0,2], recurse=False)]
```
where timestamp is a pywikibot.Timestamp object.
Yet, with the latest pywikibot version (Pywikibot: [https]
r-pywikibot-core.git (458dd0a, g6606, 2015/10/03, 12:59:27, ok) ; Release
version: 2.0b3 ; requests version: 2.2.1 ; running on the Toolserver) I get the
following error :
```
Traceback (most recent call last):
File "maj_articles_recents.py", line 343, in <module>
main()
File "maj_articles_recents.py", line 206, in main
list_new.extend([page for page in cat.articles(starttime=timestamp,
sortby='timestamp', namespaces=namespaces, recurse=recurse)])
File "/data/project/totoazero/pwb_test/pywikibot/page.py", line 2460, in
articles
member_type=['page', 'file']
File "/data/project/totoazero/pwb_test/pywikibot/site.py", line 3542, in
categorymembers
if excluded_namespaces.intersect(namespaces):
AttributeError: 'set' object has no attribute 'intersect'
<type 'exceptions.AttributeError'>
CRITICAL: Closing network session.
```
It looks like there's an issue with the namespaces, as everything is alright
when I get rid of this option.
TASK DETAIL
https://phabricator.wikimedia.org/T114563
WORKBOARD
https://phabricator.wikimedia.org/project/board/87/
EMAIL PREFERENCES
https://phabricator.wikimedia.org/settings/panel/emailpreferences/
To: totoazero
Cc: Aklapper, totoazero, pywikibot-bugs-list, jayvdb
_______________________________________________
pywikibot-bugs mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/pywikibot-bugs