potiuk commented on code in PR #38648:
URL: https://github.com/apache/airflow/pull/38648#discussion_r1546124599
##########
dev/breeze/src/airflow_breeze/commands/release_management_commands.py:
##########
@@ -3266,16 +3270,32 @@ def generate_issue_content(
if latest:
import requests
- response = requests.get("https://pypi.org/pypi/apache-airflow/json")
- response.raise_for_status()
- latest_released_version = response.json()["info"]["version"]
- previous = str(latest_released_version)
- current = os.getenv("VERSION", "HEAD")
- if current == "HEAD":
- get_console().print(
- "\n[warning]Environment variable VERSION not set, setting
current release "
- "version as 'HEAD'\n"
- )
+ if not is_helm_chart:
Review Comment:
NIT: revert this check to avoid `not` and do not do the second check. Also
you could extract what's inside the if statemantes to `get_latest_helm_chart()`
and `get_latest_airflow` methods - and move them somwhere to the `utils`
folder. That would make them reusable for other cases possibly.
```
if is_helm_chart:
....
else:
...
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]