From cd0981bb3ce1beb531ccc307b0f32392daacf7f6 Mon Sep 17 00:00:00 2001 From: Dylan Baker Date: Wed, 28 Aug 2024 10:04:16 -0700 Subject: [PATCH] options: fix imports - group imports properly - dont import from typing and import typing --- mesonbuild/options.py | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/mesonbuild/options.py b/mesonbuild/options.py index f1f3554c2..72dfb61a3 100644 --- a/mesonbuild/options.py +++ b/mesonbuild/options.py @@ -7,6 +7,7 @@ from collections import OrderedDict from itertools import chain from functools import total_ordering import argparse +import typing as T from .mesonlib import ( HoldableObject, @@ -24,12 +25,8 @@ from .mesonlib import ( listify_array_value, MachineChoice, ) - from . import mlog -import typing as T -from typing import ItemsView - DEFAULT_YIELDING = False # Can't bind this near the class method it seems, sadly. @@ -755,7 +752,7 @@ class OptionStore: def values(self): return self.d.values() - def items(self) -> ItemsView['OptionKey', 'UserOption[T.Any]']: + def items(self) -> T.ItemsView['OptionKey', 'UserOption[T.Any]']: return self.d.items() # FIXME: this method must be deleted and users moved to use "add_xxx_option"s instead.