github-sync-labels-milestones
github-sync-labels-milestones copied to clipboard
Should an error be thrown if label currently exists?
More of a question, but if a Label/Milestone already exists, should an error message be the only message that is returned?
I found that I'd get this message:
{"message":"Validation Failed","errors":[{"resource":"Label","code":"already_exists","field":"name"}],"documentation_url":"https://developer.github.com/v3/issues/labels/#create-a-label"}
But when actually checking my repositories, all the Labels are synced along with the Milestones - I believe the message at the end stating how many labels were created/edited should still be displayed as they technically do still change successfully.
This seems to be related to #7.
If the exact label exists, no error is shown and it should work this way imo.
There are known issues with case sensitivity, i assume that you ran into one of these.
Could you provide steps to reproduce this issue?
I see this error too. If I added "previousNames" to attempt a replace, it gives me:
Error: Can not rename label "difficulty:easy" to "difficulty:easy" since there is still a main definition "difficulty:easy"
As I said this might be caused by the github api being case-insensitive. It would help if you could provied a detailed description of the existing labels, the cofiguration of the sync, the expected outcome and the actual outcome.