Skip to content

Update: Error reporting#630

Merged
dinhtungdu merged 19 commits intodevelopfrom
update/error-reporting
Sep 22, 2020
Merged

Update: Error reporting#630
dinhtungdu merged 19 commits intodevelopfrom
update/error-reporting

Conversation

@dinhtungdu
Copy link
Copy Markdown
Contributor

@dinhtungdu dinhtungdu commented Aug 24, 2020

Description of the Change

This PR brings a better error reporting system to distributor:

  • Display detailed error while creating a new external connection through the Wizard. Covered cases:

    • Invalid domains.
    • The remote site is not a WordPress installation.
  • Update connection detail page:

    • Clearly state that if the account is not authenticated or doesn't have permission to post.
    • Add a new permission table for the current account.
  • Display pull errors after pulling from remote, screenshot.

  • Update and display detailed errors for push UI, screenshot.

Possible Drawbacks

The return value of push methods is changed from int to array. So it may cause compatibility issues for sites that uses those methods directly.

Verification Process

Manual verification.

Checklist:

  • I have read the CONTRIBUTING document.
  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have added tests to cover my change.
  • All new and existing tests passed.

Applicable Issues

Changelog Entry

@jeffpaul jeffpaul requested a review from dkotter August 24, 2020 16:05
@jeffpaul jeffpaul added this to the 1.7.0 milestone Aug 24, 2020
@dkotter
Copy link
Copy Markdown
Collaborator

dkotter commented Aug 27, 2020

@dinhtungdu This looks really good, nice work here! I left some minor code review comments, let me know if you have any questions on those.

Testing this out locally, everything seems to work great, didn't run into any issues.

I left this in one of my review comments but the main thing I think we need to be clear on here is we're changing the return of the external connections pull method, from returning an ID to an array. If anyone has built add-ons or customizations that utilize that method, it could break things for them.

Copy link
Copy Markdown
Contributor

@helen helen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Opened #635 to track the return type change of push() (may need to update it to reflect that it actually applies to network connections as well), otherwise this seems fine to me.

@helen helen removed the request for review from dkotter September 22, 2020 14:50
@dinhtungdu dinhtungdu merged commit ae5d8ac into develop Sep 22, 2020
@dinhtungdu dinhtungdu deleted the update/error-reporting branch September 22, 2020 14:52
@jeffpaul jeffpaul modified the milestones: 1.7.0, 1.6.1 Nov 10, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants