Skip to content

Commit 8dfbbf9

Browse files
Pepe Iborrafacebook-github-bot
Pepe Iborra
authored andcommitted
Handle targets with platform constraints
Summary: D70771787 added platform constraints to omega_analyser, which broke the universe analysis in the ide BXL script. This Diff introduces error handling so that incompatible targets can be filtered out Reviewed By: ndmitchell Differential Revision: D71623081 fbshipit-source-id: e72de2b09b36c4ee2853a4ce3df822f9ca1ecb71
1 parent 4f01e2d commit 8dfbbf9

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

prelude/haskell/ide/ide.bxl

+4-3
Original file line numberDiff line numberDiff line change
@@ -97,12 +97,13 @@ def _find_project_and_solve(ctx, target, project_universe = []):
9797

9898
def _find_target_in_universe(ctx, target, project_universe):
9999
for p in project_universe:
100-
cfg_p = ctx.configured_targets(
100+
cfg_p = ctx.lazy.configured_target_node(
101101
p,
102102
modifiers = configuration_modifiers,
103-
)
104-
if cfg_p == None:
103+
).catch().resolve()
104+
if not (cfg_p.is_ok()) or cfg_p.unwrap() == None:
105105
continue
106+
cfg_p = cfg_p.unwrap()
106107
members = cfg_p.resolved_attrs_eager(ctx).include_projects
107108
for member in members:
108109
if target.label.raw_target() == member.label.raw_target():

0 commit comments

Comments
 (0)