-
Notifications
You must be signed in to change notification settings - Fork 150
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
Errors in some cases are unusable/PR was reverted #274
Comments
Hi @phxnsharp, As we indicated in the PR comment here, we ended up adjusting the error handling code slightly and moving the tests to a different file after merging. At the time there were massive code changes taking place, as ClearScript was going cross-platform, so it's certainly possible that we broke something. However, we just ran your original tests from the PR, and all five worked with the following text changes:
Please let us know if you're aware of any additional changes or regressions. Thank you! |
We have a suite of unit tests that test our integration with ClearScript. When we recently switched it from our custom compiled version from my fork to the latest release, we started getting a pile of failed tests due to error messages being much simplified. Based on that and seeing the mass deletions, I assumed it was totally broken. But I see that all 14 tests are really parameterized versions of a single test, and that other tests we put into place are still working. So it looks like just one case is broken. The case is when you have provided a COM object to the script host and the script attempts to call a non-existent property. The expected error in our tests looks like:
but all we are getting is:
There are a lot of permutations and I don't have my original PR up and compiling right now. The test I originally wrote named VBScriptEngine_ExceptionDetails_NoDebugger on line 545 of VBScriptEngineTest.cs in my PR might prove this case. Or, we might need to write a new test doing the same thing with ComVisibleTestObject (it might be specific to having a COM object). Thanks for your help! Glad to know it is isolated to a specific case. |
Hi @phxnsharp,
We've run all five tests from your PR on the latest ClearScript (currently version 7.1.5), and they all succeeded with the text changes above. One of these tests, Please let us know if you can isolate an errant case. Thanks! |
I have someone trying to do that, but it looks like in the refactor the test projects were all removed from the "NoV8" solution. Is there still a way to run the tests without setting up V8? |
The
Sadly, it wouldn't be trivial. You could add one of the existing test projects to Another option might be to create a basic console app, bring in ClearScript via NuGet, and add your test code. We'll be happy to investigate any issue you find that way. Cheers! |
Here is a test and helper class that isolates our issue.
|
Hi @briell99, Thanks for posting the test case! We've confirmed that it currently causes ClearScript to lose a portion of the error details. We'll have a fix in the next ClearScript release. Thanks again! |
Fixed in Version 7.1.6. |
In #204, which was approved and merged with master I fixed and added test cases for several areas where error reporting was quite non-useful. Shortly after in 28d6aa2#diff-3e3487db6f5281f14631a689d9e902314cecb42d32976a21758dbbece8e7a801
those changes and the tests that prove they work were reverted or lost. I don't know if it was intentional or not.
However, the changes are actually very important for us as we would like good errors with line numbers to be reported in all cases for our customers. Can I ask for this to be revisited please?
The text was updated successfully, but these errors were encountered: