Skip to content

Commit

Permalink
fix: logic error in url retrieval
Browse files Browse the repository at this point in the history
  • Loading branch information
tdejager committed Jul 18, 2024
1 parent 4ebdfc1 commit 99940de
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 11 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -165,3 +165,4 @@ mapping/*# pixi environments
.pixi

.vscode/
.DS_store
2 changes: 1 addition & 1 deletion src/rattler_build_conda_compat/recipe_sources.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ def get_all_url_sources(recipe: Mapping[Any, Any]) -> Iterator[str]:
sources = output.get("source", None)
sources = typing.cast(ConditionalList[Source], sources)
if sources is None:
return
continue
sources = visit_conditional_list(sources, None)
for source in sources:
if "url" in source:
Expand Down
23 changes: 13 additions & 10 deletions tests/data/outputs_source.yaml
Original file line number Diff line number Diff line change
@@ -1,11 +1,14 @@
outputs:
source:
- if: foo
then:
- url: https://foo.com
- if: bla
then:
- url: https://bar.com
else:
- url: https://baz.com
- url: https://qux.com
- package:
name: foo
version: 1.0.0
- source:
- if: foo
then:
- url: https://foo.com
- if: bla
then:
- url: https://bar.com
else:
- url: https://baz.com
- url: https://qux.com

0 comments on commit 99940de

Please sign in to comment.