-
-
Notifications
You must be signed in to change notification settings - Fork 346
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
Netkan.exe should fail gracefully on files with an invalid $kref token #374
Comments
The current failure mode for a netkan file with no $kref is this:
|
For reference, the issue lies on these lines: |
This issue was moved to KSP-CKAN/CKAN-netkan#4 |
re-opening after repo merge |
This still exists, with us currently getting:
However it strikes me that if we have no
Or something similar. (In short, this is just a better-error-message change.) |
Having no $kref at all poses no issue, having a broken $kref now gives a generic JSON deserialization error |
@plague006 would that be broken JSON? Which should be caught during testing with jsonlint I'd expect. I think this was completed during the refactor #1218 - but I'm not sure. Either way I think this can be closed now. |
It's not broken JSON as I understand it. It validates with jsonlint without issue. Some excerpts from a test:
gives the output
which is really generic and hard for users to interpret. |
My first rodeo with the NetKAN codebase. The only place I see that error message in the current codebase is https://github.com/KSP-CKAN/CKAN/blob/master/Core/Types/CkanModule.cs#L297 - having a full stack trace would be handy because that CkanModule ctor is being called somewhat frequently in my limited profiling of the current code. |
Current output with
So it doesn't stop at JSON deserialization anymore, but it waits till later in the processing to complain, when it finally notices it doesn't have any URLs to download. Ideally yes, the error would specify that the |
I thought it did, but recent reports indicate that it doesn't.
It should, however,
warntell the user if it spots a file upon which it performs no expansion.The text was updated successfully, but these errors were encountered: