-
Notifications
You must be signed in to change notification settings - Fork 126
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
fix FormationViolation to FormatViolation on CallError (OCPP 2.0.1 Specification, Table B06.FR.17) #202
Conversation
Hello, I just fix the Changes:
Thx |
I added another fix on Thx |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
First of all thanks a lot for finding and fixing these implementation errors.
All commits except the first one LG2M (I left one minor comment).
Regarding the FormatViolation
I cannot accept the change the way it is, because in v1.6 the error code is indeed called FormationViolation
(for whatever reason this was changed in v2). I believe this might just be the only change between the two ocppj versions. Fixing one version would break the other. To not break anything we probably need to inject error codes from the top layer. I would suggest splitting this into 2 separate PRs.
@@ -284,7 +284,7 @@ type CSMS interface { | |||
// Retrieves all messages currently configured on a charging station. | |||
GetDisplayMessages(clientId string, callback func(*display.GetDisplayMessagesResponse, error), requestId int, props ...func(*display.GetDisplayMessagesRequest)) error | |||
// Retrieves all installed certificates on a charging station. | |||
GetInstalledCertificateIds(clientId string, callback func(*iso15118.GetInstalledCertificateIdsResponse, error), typeOfCertificate types.CertificateUse, props ...func(*iso15118.GetInstalledCertificateIdsRequest)) error | |||
GetInstalledCertificateIds(clientId string, callback func(*iso15118.GetInstalledCertificateIdsResponse, error), certificateTypes []types.CertificateUse, props ...func(*iso15118.GetInstalledCertificateIdsRequest)) error |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In theory the certificateTypes
are optional so they could be omitted from this signature (all optional values are ommitted throughout the lib as they can be added via the props variadic function). That being sad, if this leads to too many changes, we could also leave it as it is.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hello, I've modified these changes based on your review and created a new PR on #207
For Lines 373 to 390 in c34f6ad
|
New issue #210 |
FormationViolation
toFormatViolation
base onOCPP 2.0.1 Specification
TableB06.FR.17