[Pywikipedia-bugs] [Maniphest] [Commented On] T336630: TestShortLink::test_create_short_link sometimes fails with oauth credentials in user-config.py

2023-05-15 Thread zhuyifei1999
zhuyifei1999 added a comment.


  > I think the bottom line here is that the pywikibot system as a whole 
depends too much on external resources (such as user-config.py) which makes the 
test suite fragile. There really needs to be a way for the test framework to 
supply a complete configuration without looking at an external configuration 
file.
  
  I agree.

TASK DETAIL
  https://phabricator.wikimedia.org/T336630

EMAIL PREFERENCES
  https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: zhuyifei1999
Cc: zhuyifei1999, Aklapper, pywikibot-bugs-list, RoySmith, PotsdamLamb, 
Jyoo1011, JohnsonLee01, SHEKH, Dijkstra, Khutuck, Zkhalido, Viztor, Wenyi, 
Tbscho, MayS, Framawiki, Mdupont, JJMC89, Dvorapa, Altostratus, binbot, 
Avicennasis, mys_721tx, Xqt, jayvdb, Masti, Alchimista
___
pywikibot-bugs mailing list -- pywikibot-bugs@lists.wikimedia.org
To unsubscribe send an email to pywikibot-bugs-le...@lists.wikimedia.org


[Pywikipedia-bugs] [Maniphest] [Commented On] T336630: TestShortLink::test_create_short_link sometimes fails with oauth credentials in user-config.py

2023-05-14 Thread RoySmith
RoySmith added a comment.


  OK, I mostly understand what's happening here.   My user-config.py defines 
oauth credentials for {en,test}.wikipedia.org, and those credentials were 
created to only be valid on those specific projects 
.
  test_create_short_link() forces a login to meta, and that's one of the ways 
this fails.
  
  I think the bottom line here is that the pywikibot system as a whole depends 
to much on external resources (such as user-config.py) which makes the test 
suite fragile.  There really needs to be a way for the test framework to supply 
a complete configuration without looking at an external configuration file.

TASK DETAIL
  https://phabricator.wikimedia.org/T336630

EMAIL PREFERENCES
  https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: RoySmith
Cc: Aklapper, pywikibot-bugs-list, RoySmith, PotsdamLamb, Jyoo1011, 
JohnsonLee01, SHEKH, Dijkstra, Khutuck, Zkhalido, Viztor, Wenyi, Tbscho, MayS, 
Framawiki, Mdupont, JJMC89, Dvorapa, Altostratus, binbot, Avicennasis, 
mys_721tx, Xqt, jayvdb, Masti, Alchimista
___
pywikibot-bugs mailing list -- pywikibot-bugs@lists.wikimedia.org
To unsubscribe send an email to pywikibot-bugs-le...@lists.wikimedia.org