Bench update notification message

Continuing the discussion from this post:
CAUTION Somebody broke “bench” last night

I have found the cli.py file mentioned by @ankush. But the code is for version 5.14
In version 5.12 doesn’t have the mentioned function (def execute_cmd).

My goal is to disable the notification (not necessarily the version checking itself) in version 5.12 so I don’t have to update to 5.14.

After searching I found it in:

/usr/local/lib/python3.6/site-packages/bench/utils/__init__.py

and comment the following line:

	#	if pypi_version > local_version:
	#		log(f"A newer version of bench is available: {local_version} → {pypi_version}")

You can also make this log go to stderr instead so scripts using stdout get (somewhat) parsable output, but this isn’t the only thing that pops up on stdout… auditing all of them will take forever.

Thanks for the suggestion.
So far this is the only notification pops up quite often and unpredictable so comment out these lines is enough… for now :slight_smile:

Sent PR, it’s a very small change.

2 Likes

Actually in v5.14 in the cli.py just change the

def execute_cmd(check_for_update=True

to

def execute_cmd(check_for_update=False

is easier, isn’t it?