Skip to content

Commit 5cdd868

Browse files
committed
Fix type hints using or
1 parent e032278 commit 5cdd868

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

message_ix_models/model/material/data_util.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
from collections.abc import Mapping
22
from functools import lru_cache
3-
from typing import TYPE_CHECKING, Literal
3+
from typing import TYPE_CHECKING, Literal, Optional
44

55
import message_ix
66
import numpy as np
@@ -285,7 +285,7 @@ def read_sector_data(
285285

286286

287287
def read_timeseries(
288-
scenario: message_ix.Scenario, material: str, ssp: str or None, filename: str
288+
scenario: message_ix.Scenario, material: str, ssp: Optional[str], filename: str
289289
) -> pd.DataFrame:
290290
"""
291291
Read "timeseries" type data from a sector specific xlsx input file
@@ -363,7 +363,7 @@ def convert_if_digit(col_name):
363363

364364

365365
def read_rel(
366-
scenario: message_ix.Scenario, material: str, ssp: str or None, filename: str
366+
scenario: message_ix.Scenario, material: str, ssp: Optional[str], filename: str
367367
) -> pd.DataFrame:
368368
"""
369369
Read relation_* type parameter data for specific industry

0 commit comments

Comments
 (0)