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

Errors thrown when Leg construction fails #175

Closed
erikquinn opened this issue Dec 1, 2016 · 5 comments
Closed

Errors thrown when Leg construction fails #175

erikquinn opened this issue Dec 1, 2016 · 5 comments
Assignees
Milestone

Comments

@erikquinn
Copy link
Collaborator

erikquinn commented Dec 1, 2016

To Reproduce:

At KJFK, issue command caf cvs w 4L to an aircraft filed on the DEEZZ4. Will produce an error of:

RouteModel.js:46 Invalid data type passed to RouteModel. Expected a string but received [object Object]

This is due to it trying to construct a new RouteModel from the contents of Leg.route, which it expects to be a simple route string, but in this case, it was already an instance of RouteModel, so the construction fails. Thus, the Leg construction subsequently fails as well.

With the failure of the instantiation of the new Leg, the waypoints are not generated either. Thus, when aircraft.fms.currentWaypoint or aircraft.fms.altitudeForCurrentWaypoint() are called, there are no Waypoints within the current Leg, so the app goes berserk with errors.

@erikquinn erikquinn added the bug label Dec 1, 2016
@erikquinn erikquinn added this to the v3.2.0 milestone Dec 1, 2016
@n8rzz n8rzz self-assigned this Dec 1, 2016
@erikquinn erikquinn added feature and removed bug labels Dec 8, 2016
@erikquinn
Copy link
Collaborator Author

@n8rzz FYI: I pushed a small start to this to the feature/ATC-175 branch. Keep it or trash it; either way it should provide some useful information.

@n8rzz
Copy link
Owner

n8rzz commented Dec 11, 2016

@erikquinn so #154 shouldn't even be a thing? Am I reading that correctly, every airport file should define rwy, body and exitPoints?

@erikquinn
Copy link
Collaborator Author

It depends on the type of procedure...

If it starts or ends at an airport, it should have a runway section (SIDs/STARs/IAPs, but not airways).

If it ends at the airport, it should have an entryPoint, if it begins at the airport it should have an exitPoint.

All procedures should have a body section.

@n8rzz
Copy link
Owner

n8rzz commented Dec 13, 2016

yeah, I get what you're saying, we're on the same page there.

so what do we do about the airport files that current have only body sections? because, currently, the StandardRouteCollection supports that case and I believe there are several airports that are set up with only body sections (I could be wrong though)

@n8rzz n8rzz added the WIP label Dec 16, 2016
@n8rzz
Copy link
Owner

n8rzz commented Dec 16, 2016

feature/ATC-175 branch created

@n8rzz n8rzz removed their assignment Dec 17, 2016
@erikquinn erikquinn self-assigned this Dec 18, 2016
@n8rzz n8rzz modified the milestones: v3.3.0, v3.2.0 Dec 19, 2016
@n8rzz n8rzz modified the milestones: v3.2.0, v3.3.0 Dec 19, 2016
@n8rzz n8rzz closed this as completed Dec 19, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants