Sort the list of sources in generated file headers
This commit is contained in:
parent
2a73dbac98
commit
fc90653ab1
@ -1,5 +1,5 @@
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# sources: google/protobuf/timestamp.proto, google/protobuf/field_mask.proto, google/protobuf/source_context.proto, google/protobuf/any.proto, google/protobuf/type.proto, google/protobuf/api.proto, google/protobuf/duration.proto, google/protobuf/struct.proto, google/protobuf/wrappers.proto, google/protobuf/empty.proto, google/protobuf/descriptor.proto
|
||||
# sources: google/protobuf/any.proto, google/protobuf/api.proto, google/protobuf/descriptor.proto, google/protobuf/duration.proto, google/protobuf/empty.proto, google/protobuf/field_mask.proto, google/protobuf/source_context.proto, google/protobuf/struct.proto, google/protobuf/timestamp.proto, google/protobuf/type.proto, google/protobuf/wrappers.proto
|
||||
# plugin: python-betterproto
|
||||
import warnings
|
||||
from dataclasses import dataclass
|
||||
|
@ -58,7 +58,7 @@ from betterproto.lib.google.protobuf.compiler import CodeGeneratorRequest
|
||||
import re
|
||||
import textwrap
|
||||
from dataclasses import dataclass, field
|
||||
from typing import Dict, Iterator, List, Optional, Set, Text, Type, Union
|
||||
from typing import Dict, Iterable, Iterator, List, Optional, Set, Text, Type, Union
|
||||
import sys
|
||||
|
||||
from ..casing import sanitize_name
|
||||
@ -251,15 +251,15 @@ class OutputTemplate:
|
||||
return self.package_proto_obj.package
|
||||
|
||||
@property
|
||||
def input_filenames(self) -> List[str]:
|
||||
def input_filenames(self) -> Iterable[str]:
|
||||
"""Names of the input files used to build this output.
|
||||
|
||||
Returns
|
||||
-------
|
||||
List[str]
|
||||
Iterable[str]
|
||||
Names of the input files used to build this output.
|
||||
"""
|
||||
return [f.name for f in self.input_files]
|
||||
return sorted(f.name for f in self.input_files)
|
||||
|
||||
@property
|
||||
def python_module_imports(self) -> Set[str]:
|
||||
|
Loading…
x
Reference in New Issue
Block a user