0

Trying to deploy package (big one) to a new org but all the tests failed with very weird errors:

1)line -1, column -1: Dependent class is invalid and needs recompilation: Class ClassName : Variable does not exist: isReadOnly Stack Trace: null

2) line -1, column -1: Dependent class is invalid and needs recompilation: Class ClassName : Method does not exist or incorrect signature: void MethodName from the type MethodType Stack Trace: null

Do you know the root cause of the errors?

4
  • Before deployment all the classes were compiled.
    – neckobik
    Commented Mar 18, 2019 at 10:58
  • refer this: help.salesforce.com/articleView?id=000229072&type=1
    – Annappa PH
    Commented Mar 18, 2019 at 12:24
  • It can be hard to find the salient points in the error messages when a large deployment fails. This could represent a missing dependency - a custom class or sObject that's not present in the target org. Can you find any other text that describes the "first" error, usually at the head of the log?
    – David Reed
    Commented Mar 18, 2019 at 13:03
  • Maybe the type of your readOnly variable is missed. Please, check it Commented Oct 13, 2019 at 2:35

1 Answer 1

0

It is good practice to compile all classes and check that if any of the classes in your package returning an error for such errors:

Setup Menu -> Develop -> Apex Classes -> Compile all classes

1
  • I've compiled all the classes before deployment, never the less got this error.
    – neckobik
    Commented Mar 18, 2019 at 10:57

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .