bug: fix some issues, and remove unused imports.
This commit is contained in:
@@ -15,8 +15,6 @@
|
|||||||
# ------------------------------------------------------------------------------
|
# ------------------------------------------------------------------------------
|
||||||
from dataclasses import asdict, dataclass
|
from dataclasses import asdict, dataclass
|
||||||
|
|
||||||
import toml
|
|
||||||
|
|
||||||
from pyasic.config.fans import FanModeConfig
|
from pyasic.config.fans import FanModeConfig
|
||||||
from pyasic.config.mining import MiningModeConfig
|
from pyasic.config.mining import MiningModeConfig
|
||||||
from pyasic.config.pools import PoolConfig
|
from pyasic.config.pools import PoolConfig
|
||||||
|
|||||||
@@ -13,7 +13,6 @@
|
|||||||
# See the License for the specific language governing permissions and -
|
# See the License for the specific language governing permissions and -
|
||||||
# limitations under the License. -
|
# limitations under the License. -
|
||||||
# ------------------------------------------------------------------------------
|
# ------------------------------------------------------------------------------
|
||||||
from abc import ABC, abstractmethod
|
|
||||||
from dataclasses import asdict, dataclass
|
from dataclasses import asdict, dataclass
|
||||||
from enum import Enum
|
from enum import Enum
|
||||||
from typing import Union
|
from typing import Union
|
||||||
|
|||||||
@@ -94,7 +94,9 @@ class PowerScalingEnabled(MinerConfigValue):
|
|||||||
mode: str = field(init=False, default="enabled")
|
mode: str = field(init=False, default="enabled")
|
||||||
power_step: int = None
|
power_step: int = None
|
||||||
minimum_power: int = None
|
minimum_power: int = None
|
||||||
shutdown_enabled: PowerScalingShutdown = None
|
shutdown_enabled: Union[
|
||||||
|
PowerScalingShutdownEnabled, PowerScalingShutdownDisabled
|
||||||
|
] = None
|
||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
def from_bosminer(cls, power_scaling_conf: dict) -> "PowerScalingEnabled":
|
def from_bosminer(cls, power_scaling_conf: dict) -> "PowerScalingEnabled":
|
||||||
|
|||||||
Reference in New Issue
Block a user