Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: make replacementName and Version not mergeable #18853

Merged
merged 2 commits into from Nov 10, 2022

Conversation

t-kulmburg
Copy link
Contributor

Changes

Changes the config options replacementName and replacementVersion to be not mergeable.
Both are Strings that are used in package files exactly as they are written in the config, so merging them (in this case would mean appending two strings) does not make sense.

Context

This fixes this requested change in my other pull request, meaning i don`t need to make the change in the link at all.

Reason for this change is that I encountered a problem when working on replacements (#17882 & #17883):

Inside mergeChildConfig, when merging both replacementName and replacementVersion (both merging configs already had the same entries for both) the entry changed to an Array of single characters.

DEBUG: (repository=xx/renovate-test)
       "depName": {"0": "p", "1": "o", "2": "s", "3": "t", "4": "g", "5": "r", "6": "e", "7": "s"}
ERROR: Repository has unknown error (repository=xx/renovate-test)
       "err": {
         "message": "depName.replace is not a function",
         "stack": "TypeError: depName.replace is not a function\n    at sanitizeDepName ...
       }

Documentation (please check one with an [x])

  • I have updated the documentation, or
  • No documentation update is required

How I've tested my work (please tick one)

I have verified these changes via:

  • Code inspection only, or
  • Newly added/modified unit tests, or
  • No unit tests but ran on a real repository, or
  • Both unit tests + ran on a real repository

@viceice viceice enabled auto-merge (squash) November 10, 2022 09:58
@viceice viceice merged commit 76b536e into renovatebot:main Nov 10, 2022
@renovate-release
Copy link
Collaborator

🎉 This PR is included in version 34.21.5 🎉

The release is available on:

Your semantic-release bot 📦🚀

@t-kulmburg t-kulmburg deleted the fix/replacements-not-mergeable branch November 10, 2022 13:01
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Dec 11, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants