Skip to content

Commit

Permalink
Merge pull request #1877 from jaimergp/union-list
Browse files Browse the repository at this point in the history
allow str or list of str in `noarch_platforms` and `remote_ci_setup`
  • Loading branch information
beckermr authored Mar 21, 2024
2 parents 9605f25 + b73faae commit b3c7349
Show file tree
Hide file tree
Showing 3 changed files with 31 additions and 2 deletions.
6 changes: 6 additions & 0 deletions conda_smithy/data/conda-forge.json
Original file line number Diff line number Diff line change
Expand Up @@ -1838,6 +1838,9 @@
},
"noarch_platforms": {
"anyOf": [
{
"$ref": "#/$defs/Platforms"
},
{
"items": {
"$ref": "#/$defs/Platforms"
Expand Down Expand Up @@ -1904,6 +1907,9 @@
},
"remote_ci_setup": {
"anyOf": [
{
"type": "string"
},
{
"items": {
"type": "string"
Expand Down
4 changes: 2 additions & 2 deletions conda_smithy/schema.py
Original file line number Diff line number Diff line change
Expand Up @@ -729,7 +729,7 @@ class ConfigModel(BaseModel):
),
)

noarch_platforms: Optional[List[Platforms]] = Field(
noarch_platforms: Optional[Union[Platforms, List[Platforms]]] = Field(
default_factory=lambda: ["linux_64"],
description=cleandoc(
"""
Expand Down Expand Up @@ -856,7 +856,7 @@ class ConfigModel(BaseModel):
),
)

remote_ci_setup: Optional[List[str]] = Field(
remote_ci_setup: Optional[Union[str, List[str]]] = Field(
default_factory=lambda: [
"conda-forge-ci-setup=4",
"conda-build>=24.1",
Expand Down
23 changes: 23 additions & 0 deletions news/1877-union-lists.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
**Added:**

* <news item>

**Changed:**

* <news item>

**Deprecated:**

* <news item>

**Removed:**

* <news item>

**Fixed:**

* Allow ``str`` (in addition to list of ``str``) in ``conda-forge.yml``'s ``noarch_platforms`` and ``remote_ci_setup``. (#1869 via #1877)

**Security:**

* <news item>

0 comments on commit b3c7349

Please sign in to comment.