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

Remove v1.6 deprecated enum variants #575

Merged
merged 6 commits into from
Feb 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@

- [#577](https://github.com/mobilityhouse/ocpp/issues/577) v2.0.1 AttributeType Enum Corrections

## BREAKING ##
- [#574](https://github.com/mobilityhouse/ocpp/issues/574) Remove v1.6 deprecated enum members - IMPORTANT see upgrade path [#574](https://github.com/mobilityhouse/ocpp/issues/574)

## 0.26.0 (2024-01-17)

- [#544](https://github.com/mobilityhouse/ocpp/issues/544) ocpp/charge_point.py - Pass `Call.unique_id` to the `on` and `after` routing handlers.
Expand Down
109 changes: 0 additions & 109 deletions ocpp/v16/enums.py
Original file line number Diff line number Diff line change
Expand Up @@ -143,24 +143,6 @@ class ChargePointErrorCode(StrEnum):
under_voltage = "UnderVoltage"
weak_signal = "WeakSignal"

# Soon to be deprecated enums
connectorLockFailure = "ConnectorLockFailure"
evCommunicationError = "EVCommunicationError"
groundFailure = "GroundFailure"
highTemperature = "HighTemperature"
internalError = "InternalError"
localListConflict = "LocalListConflict"
noError = "NoError"
otherError = "OtherError"
overCurrentFailure = "OverCurrentFailure"
overVoltage = "OverVoltage"
powerMeterFailure = "PowerMeterFailure"
powerSwitchFailure = "PowerSwitchFailure"
readerFailure = "ReaderFailure"
resetFailure = "ResetFailure"
underVoltage = "UnderVoltage"
weakSignal = "WeakSignal"


class ChargePointStatus(StrEnum):
"""
Expand All @@ -184,10 +166,6 @@ class ChargePointStatus(StrEnum):
unavailable = "Unavailable"
faulted = "Faulted"

# Soon to be deprecated enums
suspendedevse = "SuspendedEVSE"
suspendedev = "SuspendedEV"


class ChargingProfileKindType(StrEnum):
"""
Expand Down Expand Up @@ -243,11 +221,6 @@ class ChargingProfilePurposeType(StrEnum):
tx_default_profile = "TxDefaultProfile"
tx_profile = "TxProfile"

# Soon to be deprecated enums
chargepointmaxprofile = "ChargePointMaxProfile"
txdefaultprofile = "TxDefaultProfile"
txprofile = "TxProfile"


class ChargingProfileStatus(StrEnum):
"""
Expand All @@ -257,8 +230,6 @@ class ChargingProfileStatus(StrEnum):
accepted = "Accepted"
rejected = "Rejected"
not_supported = "NotSupported"
# Soon to be deprecated enums
notSupported = "NotSupported"


class ChargingRateUnitType(StrEnum):
Expand Down Expand Up @@ -311,10 +282,6 @@ class ConfigurationStatus(StrEnum):
reboot_required = "RebootRequired"
not_supported = "NotSupported"

# Soon to be deprecated enums
rebootRequired = "RebootRequired"
notSupported = "NotSupported"


class ConfigurationKey(StrEnum):
"""
Expand Down Expand Up @@ -400,10 +367,6 @@ class DataTransferStatus(StrEnum):
unknown_message_id = "UnknownMessageId"
unknown_vendor_id = "UnknownVendorId"

# Soon to be deprecated enums
unknownMessageId = "UnknownMessageId"
unknownVendorId = "UnknownVendorId"


class DeleteCertificateStatus(StrEnum):
"""
Expand All @@ -425,9 +388,6 @@ class DiagnosticsStatus(StrEnum):
upload_failed = "UploadFailed"
uploading = "Uploading"

# Soon to be deprecated enums
uploadFailed = "UploadFailed"


class FirmwareStatus(StrEnum):
"""
Expand All @@ -453,10 +413,6 @@ class FirmwareStatus(StrEnum):
invalid_signature = "InvalidSignature"
signature_verified = "SignatureVerified"

# Soon to be deprecated enums
downloadFailed = "DownloadFailed"
installationFailed = "InstallationFailed"


class GenericStatus(StrEnum):
"""
Expand Down Expand Up @@ -558,25 +514,6 @@ class Measurand(StrEnum):
temperature = "Temperature"
voltage = "Voltage"

# Soon to be deprecated enums
currentExport = "Current.Export"
currentImport = "Current.Import"
currentOffered = "Current.Offered"
energyActiveExportRegister = "Energy.Active.Export.Register"
energyActiveImportRegister = "Energy.Active.Import.Register"
energyReactiveExportRegister = "Energy.Reactive.Export.Register"
energyReactiveImportRegister = "Energy.Reactive.Import.Register"
energyActiveExportInterval = "Energy.Active.Export.Interval"
energyActiveImportInterval = "Energy.Active.Import.Interval"
energyReactiveExportInterval = "Energy.Reactive.Export.Interval"
energyReactiveImportInterval = "Energy.Reactive.Import.Interval"
powerActiveExport = "Power.Active.Export"
powerActiveImport = "Power.Active.Import"
powerFactor = "Power.Factor"
powerOffered = "Power.Offered"
powerReactiveExport = "Power.Reactive.Export"
powerReactiveImport = "Power.Reactive.Import"


class MessageTrigger(StrEnum):
"""
Expand All @@ -597,13 +534,6 @@ class MessageTrigger(StrEnum):
log_status_notification = "LogStatusNotification"
sign_charge_point_certificate = "SignChargePointCertificate"

# Soon to be deprecated enums
bootNotification = "BootNotification"
diagnosticsStatusNotification = "DiagnosticsStatusNotification"
firmwareStatusNotification = "FirmwareStatusNotification"
meterValues = "MeterValues"
statusNotification = "StatusNotification"


class Phase(StrEnum):
"""
Expand All @@ -623,14 +553,6 @@ class Phase(StrEnum):
l2_l3 = "L2-L3"
l3_l1 = "L3-L1"

# Soon to be deprecated enums
l1n = "L1-N"
l2n = "L2-N"
l3n = "L3-N"
l1l2 = "L1-L2"
l2l3 = "L2-L3"
l3l1 = "L3-L1"


class ReadingContext(StrEnum):
"""
Expand All @@ -646,14 +568,6 @@ class ReadingContext(StrEnum):
transaction_end = "Transaction.End"
trigger = "Trigger"

# Soon to be deprecated enums
interruptionBegin = "Interruption.Begin"
interruptionEnd = "Interruption.End"
sampleClock = "Sample.Clock"
samplePeriodic = "Sample.Periodic"
transactionBegin = "Transaction.Begin"
transactionEnd = "Transaction.End"


class Reason(StrEnum):
"""
Expand All @@ -672,15 +586,6 @@ class Reason(StrEnum):
unlock_command = "UnlockCommand"
de_authorized = "DeAuthorized"

# Soon to be deprecated enums
emergencyStop = "EmergencyStop"
evDisconnected = "EVDisconnected"
hardReset = "HardReset"
powerLoss = "PowerLoss"
softReset = "SoftReset"
unlockCommand = "UnlockCommand"
deAuthorized = "DeAuthorized"


class RecurrencyKind(StrEnum):
"""
Expand Down Expand Up @@ -752,9 +657,6 @@ class TriggerMessageStatus(StrEnum):
rejected = "Rejected"
not_implemented = "NotImplemented"

# Soon to be deprecated enums
notImplemented = "NotImplemented"


class UnitOfMeasure(StrEnum):
"""
Expand Down Expand Up @@ -791,10 +693,6 @@ class UnlockStatus(StrEnum):
unlock_failed = "UnlockFailed"
not_supported = "NotSupported"

# Soon to be deprecated enums
unlockFailed = "UnlockFailed"
notSupported = "NotSupported"


class UpdateFirmwareStatus(StrEnum):
"""
Expand Down Expand Up @@ -832,10 +730,6 @@ class UpdateStatus(StrEnum):
not_supported = "NotSupported"
version_mismatch = "VersionMismatch"

# Soon to be deprecated enums
notSupported = "NotSupported"
versionMismatch = "VersionMismatch"


class UpdateType(StrEnum):
"""
Expand All @@ -854,6 +748,3 @@ class ValueFormat(StrEnum):

raw = "Raw"
signed_data = "SignedData"

# Soon to be deprecated enums
signedData = "SignedData"
Loading