apache / apache/buildstream

BuildStream silently allows overriding list defined in include

Open
#2,028 3 comments 2 reactions 1 assignee Claimed by @nathanwilliams-ct View on GitHub
Dominant language
Python
Stars
140
Forks
45
Avg merge
1d 3h
Merged PRs (30d)
6

Description

When you define a list like

```
build-depends:
- foo.bst
- bar.bst
```

in include and then set same in element body, there will be silent possibly unexpected replace when user was supposed to instead append. I propose behaviour be slightly adjusted such that when you redefine list with above syntax in element, there will be a warning that can be made fatal. (implicit-list-replace or something else, I'm up to different names) To fix the warning, you would have to in element in this case state intent you want to replace existing list through

```
build-depends:
(=):
- foo.bst
- bar.bst
```

If the list is not defined before, then there will be no warning with the short-hand syntax.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.