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

topgrade 14.0.0 regression test failure #655

Closed
chenrui333 opened this issue Jan 22, 2024 · 12 comments
Closed

topgrade 14.0.0 regression test failure #655

chenrui333 opened this issue Jan 22, 2024 · 12 comments
Labels
C-bug Something isn't working

Comments

@chenrui333
Copy link
Contributor

chenrui333 commented Jan 22, 2024

👋 trying to build the latest release, but run into some regression test failure. The error log is as below:

regression test failure
==> /opt/homebrew/Cellar/topgrade/14.0.0/bin/topgrade -n --only brew_formula
―― 11:00:27 - Topgrade 14.0.0 Breaking Changes ――
1. In 13.0.0, we introduced a new feature, pushing git repos, now this feature
   has been removed as some users are not satisfied with it.

   For configuration entries, the following ones are gone:

   
   [git]
   pull_only_repos = []
   push_only_repos = []
   pull_arguments = ""
   push_arguments = ""



Confirmed? (y)es/(N)oError:
   0: Not a terminal

Location:
   src/main.rs:143
/opt/homebrew/Library/Homebrew/ignorable.rb:29:in `block in raise'
Minitest::Assertion: Expected: 0
  Actual: 1

full build log, https://github.com/Homebrew/homebrew-core/actions/runs/7606266278/job/20711857326?pr=160588
relates to Homebrew/homebrew-core#160588

@chenrui333 chenrui333 added the C-bug Something isn't working label Jan 22, 2024
@SteveLauC
Copy link
Member

Thanks for helping package Topgrade to homebrew!

That prompt indeed needs an terminal, maybe I should skip it when it is executed without the terminal, e.g., in the CI test environment

@chenrui333
Copy link
Contributor Author

That prompt indeed needs an terminal, maybe I should skip it when it is executed without the terminal, e.g., in the CI test environment

can we add some environment option for it?

@SteveLauC
Copy link
Member

Are the tests used by brew human-written, i.e., can be changed by us? From the log, the answer seems to be yes, brew tries to get the version number and execute the homebrew_formula step, and do some assertions on the output.

From the stacktrace, I see a method called with_env, does this mean that we can set a environment variable before running the test? If so, maybe I can add a environment variable to make the breaking changes notification optional

@chenrui333
Copy link
Contributor Author

From the stacktrace, I see a method called with_env, does this mean that we can set a environment variable before running the test? If so, maybe I can add a environment variable to make the breaking changes notification optional

yeah, that is totally doable, you can do it with ENV["XXX"] = "XXX" in the test block.

@chenrui333
Copy link
Contributor Author

@SteveLauC what environment variable should I try on?

@SteveLauC
Copy link
Member

@SteveLauC what environment variable should I try on?

I will implement this soon:)

@SteveLauC
Copy link
Member

SteveLauC commented Jan 23, 2024

Hi, I just implemented this feature in #659, we can skip that notification now with:

$ TOPGRADE_SKIP_BRKC_NOTIFY=true topgrade

Should I release a new version of Toprade (say v14.0.1), or you can just release v14.0.0 with a newer commit

@chenrui333
Copy link
Contributor Author

yeah, new release is better, but I can push some build patch to test that PR. Thanks for the quick turnaround. :)

@chenrui333
Copy link
Contributor Author

Works fine for me, I can ship either in 14.0.0 or 14.0.1 :)

@SteveLauC
Copy link
Member

SteveLauC commented Jan 24, 2024

new release is better

Let me give it a new release!

Update: I kinda want to include #661 in this release, so let's wait for a moment, but still, a new release will come in a day or two:)

@chenrui333
Copy link
Contributor Author

no worries at all, since we have fixed and shipped the change, I am gonna close this issue for now. Appreciate the quick turnaround! ❤️

@SteveLauC
Copy link
Member

v14.0.1 released:)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants