Skip to content

Commit

Permalink
Merge #12035
Browse files Browse the repository at this point in the history
12035: Reformat python r=Frassle a=Frassle

It would appear the formatting rules have changed.

Co-authored-by: Fraser Waters <fraser@pulumi.com>
  • Loading branch information
bors[bot] and Frassle committed Feb 1, 2023
2 parents 6248c08 + fc8ee6a commit d2bd3b6
Show file tree
Hide file tree
Showing 7 changed files with 1 addition and 12 deletions.
1 change: 0 additions & 1 deletion sdk/python/lib/pulumi/asset.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ class FileAsset(Asset):
path: str

def __init__(self, path: Union[str, PathLike]) -> None:

if not isinstance(path, (str, PathLike)):
raise TypeError("FileAsset path must be a string or os.PathLike")
self.path = fspath(path)
Expand Down
1 change: 0 additions & 1 deletion sdk/python/lib/pulumi/automation/_remote_workspace.py
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,6 @@ def _create_local_workspace(
auth: Optional[RemoteGitAuth] = None,
opts: Optional[RemoteWorkspaceOptions] = None,
) -> LocalWorkspace:

if not url:
raise Exception("url is required.")
if branch and commit_hash:
Expand Down
3 changes: 0 additions & 3 deletions sdk/python/lib/pulumi/resource.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,6 @@ def __init__(
update: Optional[str] = None,
delete: Optional[str] = None,
) -> None:

self.create = create
self.update = update
self.delete = delete
Expand Down Expand Up @@ -164,7 +163,6 @@ def __init__(
stack: Optional["Input[str]"] = ..., # type: ignore
project: Optional["Input[str]"] = ..., # type: ignore
) -> None:

self.name = name
self.type_ = type_
self.parent = parent
Expand Down Expand Up @@ -484,7 +482,6 @@ def _merge_instance(self, opts: "ResourceOptions") -> "ResourceOptions":
return ResourceOptions.merge(self, opts)

def _depends_on_list(self) -> "Input[List[Input[Resource]]]":

if self.depends_on is None:
return []

Expand Down
3 changes: 0 additions & 3 deletions sdk/python/lib/pulumi/runtime/resource.py
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,6 @@ async def prepare_aliases(
resource_options: Optional["ResourceOptions"],
supports_alias_specs: bool,
) -> List[alias_pb2.Alias]:

aliases: List[alias_pb2.Alias] = []
if resource_options is None or resource_options.aliases is None:
return aliases
Expand Down Expand Up @@ -165,7 +164,6 @@ async def prepare_resource(
opts: Optional["ResourceOptions"],
typ: Optional[type] = None,
) -> ResourceResolverOperations:

# Before we can proceed, all our dependencies must be finished.
explicit_urn_dependencies: Set[str] = set()
if opts is not None and opts.depends_on is not None:
Expand Down Expand Up @@ -490,7 +488,6 @@ def create_urn(
def resource_output(
res: "Resource",
) -> Tuple[Callable[[Any, bool, bool, Optional[Exception]], None], "Output"]:

value_future: asyncio.Future[Any] = asyncio.Future()
known_future: asyncio.Future[bool] = asyncio.Future()
secret_future: asyncio.Future[bool] = asyncio.Future()
Expand Down
2 changes: 0 additions & 2 deletions sdk/python/lib/pulumi/runtime/rpc.py
Original file line number Diff line number Diff line change
Expand Up @@ -751,7 +751,6 @@ def do_resolve(
deps: Set["Resource"],
failed: Optional[Exception],
):

# Create a union of deps and the resource.
deps_union = set(deps) if deps else set()
deps_union.add(r)
Expand Down Expand Up @@ -1011,7 +1010,6 @@ def resolve_outputs(
resolvers: Dict[str, Resolver],
transform_using_type_metadata: bool = False,
):

# Produce a combined set of property states, starting with inputs and then applying
# outputs. If the same property exists in the inputs and outputs states, the output wins.
all_properties = {}
Expand Down
1 change: 0 additions & 1 deletion sdk/python/lib/pulumi/runtime/stack.py
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,6 @@ async def wait_for_rpcs(await_all_outstanding_tasks=True) -> None:

# If the RPCs have successfully completed, now await all remaining outstanding tasks.
if await_all_outstanding_tasks:

outstanding_tasks = _get_running_tasks()
if len(outstanding_tasks) == 0:
log.debug("No outstanding tasks to complete")
Expand Down
2 changes: 1 addition & 1 deletion sdk/python/lib/pulumi/stack_reference.py
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ async def __is_secret_name(self, name: Input[str]) -> bool:
# determine if this output should be secret. Names could be None here in cases where we are
# using an older CLI that did not return this information (in this case we again fallback to
# the secretness of outputs value).
names = await (self.secret_output_names.future())
names = await self.secret_output_names.future()
if names is None:
return await self.outputs.is_secret()

Expand Down

0 comments on commit d2bd3b6

Please sign in to comment.