**CAUTION** Somebody broke "bench" last night

Okay, here is the scoop…

I have been installing v13 servers for the past few days (every day) and suddenly today my manual method started failing!

When I would run the command:

bench init --frappe-branch version-13 frappe-bench

The process would appear to work for quite a while until near the end it would generate the following error:

ValueError: The 'bench.config' package was not installed in a way that PackageLoader understands.

I tried several times to wipe the server and re-install only to finally decide to look for possible problems in how bench was installed. There were a whopping ton of changes made to bench last night and now it appears at least some of those are breaking changes.

In order to get my installs back on track, I have had to alter how bench installs by specifically calling out the previous version. If you are using my manual V13 install tutorial, you will need to change the two pip3 commands to now look as follows:

pip3 install frappe-bench==5.12.0

sudo pip3 install frappe-bench==5.12.0

Once you make this change the ‘bench init’ command will complete properly and the rest of the system installs as expected.

Hope this helps someone else. I pulled my hair out for a few hours today until I found it. :grimacing:

Remember, as always… Your Mileage May Vary! :sunglasses:

BKM :nerd_face:

12 Likes

What an issue :exploding_head:
Glad you solve it and share it :blush:

The release has since been “yanked” from PyPI so pip install frappe-bench won’t install or upgrade to it (unless you specifically ask for it).

Thanks for reporting this. This is likely an issue related to the changes in the build stage (build: pyproject.toml > setup.py + requirements.txt by gavindsouza · Pull Request #1337 · frappe/bench · GitHub) or a bug in an upstream dependency.

Edit: Made a patch release. Should work fine on latest release now.

4 Likes

Hi Gavin,

I appreciate that you were able to use my error listing to find the source of the problem.

However, due to the overwhelming number of lines of code that changed across nearly all areas of bench from installation to core functions, I think I will just stick with v5.12.0 for now.

I just do not have the time and resources to continue to play the part of the lab rat for all of these changes. I will wait until your newest version has been installed and running for a while before I venture down that path again.

Thanks, but no thanks. I need to keep creating production machines and the previous version seems to do that well for now.

BKM :nerd_face:

1 Like

You’re welcome.

I am also having issues with the installation. Problem with transfer to production, error
“nginx: [emerg] unknown “host_access” variable
nginx: configuration file /etc/nginx/nginx.conf test failed”
This works for me!

Well, I am glad to hear that someone else was able to use this quick fix to get their installation working.

Based on your feedback, it appears that @gavindsouza is not yet finished fixing the problems introduced with the last bench update.

BKM

Nice catch @bkm I had an issue with nginx configuration after running bench setup nginx command. But, downgrading bench resolved the issue.

There is a related issue notified on github, nginx.conf gets incorrect after bench setup nginx

https://github.com/frappe/bench/issues/1351

I have acustom app with a script running bench command and get a feedback of the result. It is stopped when there is a notification for bench update:

INFO: A newer version of bench is available: 5.12.1 → 5.14.0

For previous versions I just updated the bench. But this issue from BKM worries me.

@gavindsouza is there any way I can suppress this notification?

Just ignore it? :laughing:

What?!?!

Are you trying to be funny? Or are you intentionally being sarcastic to the point of being rude?

Your answer indicates that you either didn’t read the actual question @rahy posted…

Or

You are just trying to provoke and antagonize the people actually trying to make bench work.

Again… “Just ignore it?” is ridiculous. @rahy tells us in his post that the stupid notification is stopping the actions of the script he depends on to perform bench functions.

The rest of us out here also use bench in different scripts and if it stops to wait for the acknowledgement of a stupid notice that there is a newer version of bench, then the newest version of bench becomes useless.

You know, I really am beginning to dislike the attitude of the devs lately. When a simple question was asked, you turn it into somehting you think is funny while real world users are tripping over your nonsense.

Ugh!

BKM :rage:

1 Like

I actually didn’t fully understand the question and assumed it was about annoyance that warning causes.

Most if not all bench commands don’t have stable stdout, so using stdout in scripts like this is bound to break.


Feel free to fix it if it has been bothering you for so long, here’s the reference code that you need to modify:

Quite a lot coming from someone whose every other message is passive-aggressive. I am enlightened, thanks! :smile:

4 Likes

If you didn’t fully understand the question, the appropriate response is either:

  1. No response.
  2. Ask for clarification.

Instead, you threw out “Just ignore it”. A comment both unhelpful, and a little rude. Obviously anyone can just ignore messages. There’s no need to suggest this.

If you’d stopped typing right before this statement? You’d have recovered from your earlier mistake. Instead, you keep digging a deeper hole. Trying to be funny (again), by directly insulting another forum user.

If we cannot (or will not) reply with questions or helpful feedback, then we should not reply at all.

This thread is completely derailed, so I’m locking it. Let’s try to keep these forums professional, please.

2 Likes

Thanks @ankush for the reference.
After installed, where is this file located?