diff options
author | Dylan Baker <dylan.c.baker@intel.com> | 2022-03-17 10:14:01 -0700 |
---|---|---|
committer | Dylan Baker <dylan.c.baker@intel.com> | 2022-03-23 09:10:04 -0700 |
commit | 8bd46a976bcfd9100336fe1ab32db05cd480e2f6 (patch) | |
tree | 9d754be43f44a786a88ae8c9a713a73f96b4fce7 /bin | |
parent | 4286b5c02aef8eb39142962be2458d66c44ff3ce (diff) |
pick/core: drop the main_sha field
It isn't actually used, so we don't need it.
Diffstat (limited to 'bin')
-rw-r--r-- | bin/pick/core.py | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/bin/pick/core.py b/bin/pick/core.py index 766749c471f..d805a7be987 100644 --- a/bin/pick/core.py +++ b/bin/pick/core.py @@ -42,7 +42,6 @@ if typing.TYPE_CHECKING: nominated: bool nomination_type: typing.Optional[int] resolution: typing.Optional[int] - main_sha: typing.Optional[str] because_sha: typing.Optional[str] IS_FIX = re.compile(r'^\s*fixes:\s*([a-f0-9]{6,40})', flags=re.MULTILINE | re.IGNORECASE) @@ -118,7 +117,6 @@ class Commit: nominated: bool = attr.ib(False) nomination_type: typing.Optional[NominationType] = attr.ib(None) resolution: Resolution = attr.ib(Resolution.UNRESOLVED) - main_sha: typing.Optional[str] = attr.ib(None) because_sha: typing.Optional[str] = attr.ib(None) def to_json(self) -> 'CommitDict': @@ -131,7 +129,7 @@ class Commit: @classmethod def from_json(cls, data: 'CommitDict') -> 'Commit': - c = cls(data['sha'], data['description'], data['nominated'], main_sha=data['main_sha'], because_sha=data['because_sha']) + c = cls(data['sha'], data['description'], data['nominated'], because_sha=data['because_sha']) if data['nomination_type'] is not None: c.nomination_type = NominationType(data['nomination_type']) if data['resolution'] is not None: |