[Pywikipedia-bugs] [Maniphest] [Updated] T186200: Rewrite Wikibase data model implementation

2023-01-18 Thread matej_suchanek
matej_suchanek added a subtask: T327205: Pywikibot Claim inconsistency with 
sources vs references.

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

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

To: matej_suchanek
Cc: Xqt, SilentSpike, David_Haskiya_WMSE, Phaebz, Dvorapa, Lokal_Profil, 
Aklapper, matej_suchanek, pywikibot-bugs-list, BeautifulBold, Suran38, 
PotsdamLamb, Jyoo1011, JohnsonLee01, SHEKH, Peteosx1x, Dijkstra, NavinRizwi, 
Khutuck, Zkhalido, Viztor, Wenyi, Tbscho, MayS, Framawiki, Mdupont, JJMC89, 
Altostratus, Avicennasis, mys_721tx, Dinoguy1000, jayvdb, Ricordisamoa, 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] [Updated] T186200: Rewrite Wikibase data model implementation

2020-03-09 Thread matej_suchanek
matej_suchanek added a project: Epic.
matej_suchanek added a comment.


  +1. Very good idea (I believe the best one). `page.py` is getting a lot of 
new things in https://gerrit.wikimedia.org/r/c/pywikibot/core/+/526380 (so 
putting it on hold), this overhaul would add more and there is still a lot to 
be implemented... So there will be a new subtask.
  
  T108440  proposes creating a 
submodule but just moving all the stuff to a separate file would work too, so 
that can be done later.

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

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

To: matej_suchanek
Cc: Xqt, SilentSpike, David_Haskiya_WMSE, Phaebz, Dvorapa, Lokal_Profil, 
Aklapper, matej_suchanek, pywikibot-bugs-list, NavinRizwi, Zkhalido, Viztor, 
Wenyi, Tbscho, MayS, Framawiki, Mdupont, JJMC89, Altostratus, Avicennasis, 
mys_721tx, Dinoguy1000, jayvdb, Ricordisamoa, Masti, Alchimista, Rxy
___
pywikibot-bugs mailing list
pywikibot-bugs@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/pywikibot-bugs


[Pywikipedia-bugs] [Maniphest] [Updated] T186200: Rewrite Wikibase data model implementation

2019-06-25 Thread Dvorapa
Dvorapa edited subtasks, added: T189321: Support for Lexicographical 
data/WikibaseLexeme in Pywikibot; removed: T226479: Implement support for 
WikibaseLexeme in Pywikibot.

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

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

To: Dvorapa
Cc: Phaebz, Pintoch, Dvorapa, Lokal_Profil, Aklapper, matej_suchanek, 
pywikibot-bugs-list, Viztor, DannyS712, Wenyi, Tbscho, MayS, Framawiki, 
Mdupont, JJMC89, Altostratus, Avicennasis, mys_721tx, jayvdb, Ricordisamoa, 
Dalba, Masti, Alchimista, Rxy
___
pywikibot-bugs mailing list
pywikibot-bugs@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/pywikibot-bugs


[Pywikipedia-bugs] [Maniphest] [Updated] T186200: Rewrite Wikibase data model implementation

2019-06-25 Thread Xqt
Xqt added a subtask: T222608: Should Wikidata Integrator and Pywikibot merge?.

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

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

To: Xqt
Cc: Phaebz, Pintoch, Dvorapa, Lokal_Profil, Aklapper, matej_suchanek, 
pywikibot-bugs-list, Viztor, DannyS712, Wenyi, Tbscho, MayS, Framawiki, 
Mdupont, JJMC89, Altostratus, Avicennasis, mys_721tx, jayvdb, Ricordisamoa, 
Dalba, Masti, Alchimista, Rxy
___
pywikibot-bugs mailing list
pywikibot-bugs@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/pywikibot-bugs


[Pywikipedia-bugs] [Maniphest] [Updated] T186200: Rewrite Wikibase data model implementation

2019-06-25 Thread Lokal_Profil
Lokal_Profil added a comment.


  In T186200#4559300 , 
@Pintoch wrote:
  
  > Also, I think it would be very hard to clean up this implementation while 
maintaining compatibility with existing user code. Given that pywikibot has 
basically no releases and people are encouraged to use the master branch, I 
don't see how a breaking change like this could be carried out without creating 
a big mess. So in short, I don't see how that can be done at all in pywikibot's 
git repository. But I would be very happy to be proven wrong.
  
  
  This at least has been addressed with users now recomended to use release 
tagged with "stable" while pywikibot developers use the master branch well 
aware that it might break/be broken. While backwards compatibility is likely 
impossible we should strive to ensure any "old" calls raise suitable 
deprecation exceptions for a while.
  
  This rework is probably also a good opportunity to pull wikibase related code 
out of `__init__.py` into e.g. `wikibase.py`. With T226479 
 and T223820 
 there will be even more wikibase 
related code coming in and `__init__` is fairly bloated as is.

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

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

To: Lokal_Profil
Cc: Phaebz, Pintoch, Dvorapa, Lokal_Profil, Aklapper, matej_suchanek, 
pywikibot-bugs-list, Viztor, DannyS712, Wenyi, Tbscho, MayS, Framawiki, 
Mdupont, JJMC89, Altostratus, Avicennasis, mys_721tx, jayvdb, Ricordisamoa, 
Dalba, Masti, Alchimista, Rxy
___
pywikibot-bugs mailing list
pywikibot-bugs@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/pywikibot-bugs


[Pywikipedia-bugs] [Maniphest] [Updated] T186200: Rewrite Wikibase data model implementation

2019-06-25 Thread Xqt
Xqt added a subtask: T226479: Implement support for WikibaseLexeme in Pywikibot.

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

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

To: Xqt
Cc: Phaebz, Pintoch, Dvorapa, Lokal_Profil, Aklapper, matej_suchanek, 
pywikibot-bugs-list, Viztor, DannyS712, Wenyi, Tbscho, MayS, Framawiki, 
Mdupont, JJMC89, Altostratus, Avicennasis, mys_721tx, jayvdb, Ricordisamoa, 
Dalba, Masti, Alchimista, Rxy
___
pywikibot-bugs mailing list
pywikibot-bugs@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/pywikibot-bugs


[Pywikipedia-bugs] [Maniphest] [Updated] T186200: Rewrite Wikibase data model implementation

2018-06-08 Thread Lokal_Profil
Lokal_Profil added a comment.

In T186200#4240251, @Dvorapa wrote:
I'm not familiar with Wikidata, but at least this seems to make the code cleaner, improve its readability, and reduce code-complexity on Codeclimate.

Just make sure you will solve some of the issues in #pywikibot-wikidata belonging to this part as they would require to rewrite the code once more when being solved after the rewrite.


At a quick glance T170432: Function to add a claim with source in a single edit/T112577: Make it possible to add a qualifier together with a new claim using new_claim.addQualifier() are probably the most interesting ones to keep in mind. For those to be possible there would have to be some way of preparing references/qualifiers without the addSource/addQualifier calling the API. This refactoring doesnt solve that but I also don't believe it makes it harder. Possibly we want to add a function to BaseClaim which addSource/addQualifier/setTarget (etc.) extends so that the postponement mechanism can be added there.

T124139: Claim new method has_source/T76615: Claim equality operator would be fixed/easier to fix by the refactoring (possibly no longer needeed with the above same_as suggestion)

T107712: Use narrow API calls instead of wbeditentity in Pywikibot Would be helped by the refactor.

Per T108440: Pull out all Wikibase-related parts of pywikibot to pywikibot/wikibase and use it as a submodule it might be wort taking a look at https://github.com/wikimedia/pywikibot-wikibase to see how/if it tackled this. Or even revisit the question about moving all wikibase code into a submodule.TASK DETAILhttps://phabricator.wikimedia.org/T186200EMAIL PREFERENCEShttps://phabricator.wikimedia.org/settings/panel/emailpreferences/To: Lokal_ProfilCc: Dvorapa, Lokal_Profil, Aklapper, matej_suchanek, pywikibot-bugs-list, Sc4s2cg, Magul, Tbscho, MayS, Framawiki, Salgo60, Mdupont, JJMC89, Avicennasis, jayvdb, Ricordisamoa, Dalba, Masti, Alchimista, Rxy___
pywikibot-bugs mailing list
pywikibot-bugs@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/pywikibot-bugs


[Pywikipedia-bugs] [Maniphest] [Updated] T186200: Rewrite Wikibase data model implementation

2018-05-24 Thread Lokal_Profil
Lokal_Profil added a comment.
+1 for this idea. It will also make T76615: Claim equality operator easier to deal with.

One note though is that the the suggestion above does not match Wikibase steucture as described in https://phabricator.wikimedia.org/T76615#3464800. Importantly pywikibot.Claim here is a mixture of Claim (value +Qualifiers) and Statement (Claim+References).

If we are breaking things this would be a great time to drop the missleading target_equals (or rename it to clarify its not a true equals).
Might also be worth considering if self.qualifiers should be simple dict (since Wikibase does not say the order has significance).TASK DETAILhttps://phabricator.wikimedia.org/T186200EMAIL PREFERENCEShttps://phabricator.wikimedia.org/settings/panel/emailpreferences/To: Lokal_ProfilCc: Lokal_Profil, Aklapper, matej_suchanek, pywikibot-bugs-list, Magul, Tbscho, MayS, Framawiki, Mdupont, JJMC89, Dvorapa, Avicennasis, jayvdb, Ricordisamoa, Dalba, Masti, Alchimista, Rxy___
pywikibot-bugs mailing list
pywikibot-bugs@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/pywikibot-bugs