Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Raise more useful message when constructor are not resolvable #29737

Merged
merged 1 commit into from Dec 5, 2017

Conversation

PVince81
Copy link
Contributor

@PVince81 PVince81 commented Dec 1, 2017

Description

Whenever resolved class C exists but one of its constructor arguments
cannot be resolved, the app framework would throw an exception that the
class C does not exist even though it does. This is misleading and leads
to confusion, anger and loss of time.

This fix expands the error message to include the message about the
constructor argument that wasn't properly forwarded.

Related Issue

None raised.

Motivation and Context

Happened to me several times

How Has This Been Tested?

Open settings/Application, go to the CheckSetupController and modify one letter of one of the constructor arg services. Ex replace "Config" with "Xonfig". Then go to settings page and check owncloud.log.

Before the fix: it would say that CheckSetupController does not exist at all.
After the fix. it says the above, but also adds that constructor arg "Xonfig" could not be resolved.

Screenshots (if appropriate):

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

  • 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 read the CONTRIBUTING document.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

Whenever resolved class C exists but one of its constructor arguments
cannot be resolved, the app framework would throw an exception that the
class C does not exist even though it does. This is misleading and leads
to confusion, anger and loss of time.

This fix expands the error message to include the message about the
constructor argument that wasn't properly forwarded.
@codecov
Copy link

codecov bot commented Dec 1, 2017

Codecov Report

Merging #29737 into master will decrease coverage by <.01%.
The diff coverage is 0%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master   #29737      +/-   ##
============================================
- Coverage     62.62%   62.62%   -0.01%     
- Complexity    17581    17582       +1     
============================================
  Files          1037     1037              
  Lines         57906    57908       +2     
============================================
  Hits          36262    36262              
- Misses        21644    21646       +2
Impacted Files Coverage Δ Complexity Δ
lib/private/AppFramework/App.php 47.91% <0%> (-2.09%) 15 <0> (+1)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update e806a96...2f227de. Read the comment docs.

@lock
Copy link

lock bot commented Aug 1, 2019

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock bot locked as resolved and limited conversation to collaborators Aug 1, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants