https://bugzilla.wikimedia.org/show_bug.cgi?id=57754

--- Comment #1 from Liangent <[email protected]> ---
Repro:

== Query 1: Create a new claim, at Q245 ==

token=XXX&data=%7B%7D&new=item

{
    "entity": {
        "labels": [],
        "descriptions": [],
        "aliases": [],
        "sitelinks": [],
        "claims": [],
        "id": "Q245",
        "type": "item",
        "lastrevid": 2588
    },
    "success": 1
}

== Query 2: Create initial revision 2589 ==

id=Q245&token=XXX&data=%7B%22labels%22%3A%5B%7B%22language%22%3A%22en%22%2C%22value%22%3A%22Foo%22%7D%5D%2C%22claims%22%3A%7B%22P55%22%3A%5B%7B%22mainsnak%22%3A%7B%22snaktype%22%3A%22value%22%2C%22property%22%3A%22P55%22%2C%22datavalue%22%3A%20%7B%22value%22%3A%20%22abc%22%2C%22type%22%3A%20%22string%22%7D%7D%2C%22type%22%3A%22statement%22%2C%22rank%22%3A%22normal%22%7D%5D%7D%7D

{
    "entity": {
        "labels": {
            "en": {
                "language": "en",
                "value": "Foo"
            }
        },
        "descriptions": [],
        "aliases": [],
        "sitelinks": [],
        "claims": {
            "P55": [
                {
                    "id": "Q245$0CF9E5D0-31CD-4019-86A8-CF5AAA1CD596",
                    "mainsnak": {
                        "snaktype": "value",
                        "property": "P55",
                        "datavalue": {
                            "value": "abc",
                            "type": "string"
                        }
                    },
                    "type": "statement",
                    "rank": "normal"
                }
            ]
        },
        "id": "Q245",
        "type": "item",
        "lastrevid": 2589
    },
    "success": 1
}

== Query 3: Attempt to rewrite the item to something ==

id=Q245&baserevid=2589&token=XXX&data=%7B%22labels%22%3A%5B%7B%22language%22%3A%22de%22%2C%22value%22%3A%22Bar%22%7D%5D%2C%22claims%22%3A%7B%22P55%22%3A%5B%7B%22mainsnak%22%3A%7B%22snaktype%22%3A%22value%22%2C%22property%22%3A%22P55%22%2C%22datavalue%22%3A%20%7B%22value%22%3A%20%22def%22%2C%22type%22%3A%20%22string%22%7D%7D%2C%22type%22%3A%22statement%22%2C%22rank%22%3A%22normal%22%7D%5D%7D%7D&clear=

{
    "entity": {
        "labels": {
            "de": {
                "language": "de",
                "value": "Bar"
            }
        },
        "descriptions": [],
        "aliases": [],
        "sitelinks": [],
        "claims": {
            "P55": [
                {
                    "id": "Q245$8424C010-5151-44B3-B00C-6F2E6EEE436B",
                    "mainsnak": {
                        "snaktype": "value",
                        "property": "P55",
                        "datavalue": {
                            "value": "def",
                            "type": "string"
                        }
                    },
                    "type": "statement",
                    "rank": "normal"
                }
            ]
        },
        "id": "Q245",
        "type": "item",
        "lastrevid": 2590
    },
    "success": 1
}

== Query 4: Simultaneous attempt to rewrite the item to something else based on
revision 2589. This created
https://test.wikidata.org/w/index.php?title=Q245&oldid=2591 as a mixed
revision, and returned data contain "new" attempt only ==

id=Q245&baserevid=2589&token=XXX&data=%7B%22labels%22%3A%5B%7B%22language%22%3A%22nl%22%2C%22value%22%3A%22Bar%22%7D%5D%2C%22claims%22%3A%7B%22P55%22%3A%5B%7B%22mainsnak%22%3A%7B%22snaktype%22%3A%22value%22%2C%22property%22%3A%22P55%22%2C%22datavalue%22%3A%20%7B%22value%22%3A%20%22qwerty%22%2C%22type%22%3A%20%22string%22%7D%7D%2C%22type%22%3A%22statement%22%2C%22rank%22%3A%22normal%22%7D%5D%7D%7D&clear=

{
    "entity": {
        "labels": {
            "nl": {
                "language": "nl",
                "value": "Bar"
            }
        },
        "descriptions": [],
        "aliases": [],
        "sitelinks": [],
        "claims": {
            "P55": [
                {
                    "id": "Q245$31144320-3601-4B00-B733-7F1DC6245C65",
                    "mainsnak": {
                        "snaktype": "value",
                        "property": "P55",
                        "datavalue": {
                            "value": "qwerty",
                            "type": "string"
                        }
                    },
                    "type": "statement",
                    "rank": "normal"
                }
            ]
        },
        "id": "Q245",
        "type": "item",
        "lastrevid": 2591
    },
    "warnings": {
        "messages": {
            "0": {
                "name": "wikibase-self-conflict-patched",
                "type": "warning"
            },
            "html": {
                "*": "<p>Your edit was patched into the latest version,
overriding some of your own intermediate changes.\n</p>"
            }
        }
    },
    "success": 1
}

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
Wikibugs-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l

Reply via email to