Skip to content

Conversation

@bdsoha
Copy link
Contributor

@bdsoha bdsoha commented Jun 17, 2025

Ensures that airflow.cfg is rendered from the merged configuration object ($config) instead of .Values.config, allowing computed default values like execution_api_server_url to be properly included in the final config.


^ Add meaningful description above
Read the Pull Request Guidelines for more information.
In case of fundamental code changes, an Airflow Improvement Proposal (AIP) is needed.
In case of a new dependency, check compliance with the ASF 3rd Party License Policy.
In case of backwards incompatible changes please leave a note in a newsfragment file, named {pr_number}.significant.rst or {issue_number}.significant.rst, in airflow-core/newsfragments.

@boring-cyborg boring-cyborg bot added the area:helm-chart Airflow Helm Chart label Jun 17, 2025
@bdsoha bdsoha marked this pull request as draft June 17, 2025 09:54
@bdsoha bdsoha marked this pull request as ready for review June 17, 2025 09:56
@eladkal eladkal requested a review from romsharon98 June 17, 2025 22:58
@romsharon98
Copy link
Contributor

changes looks good.
can you add tests to avoid regression?

@bdsoha
Copy link
Contributor Author

bdsoha commented Jun 19, 2025

@romsharon98 Thanks for the tip about regression.
It got me thinking about what actually needs to be tested.
At this point, the only relevant test case is for core.execution_api_server_url, which is already covered and passing.

If in the future additional defaults are applied, they will be separately tested.
Have any suggestions?

@romsharon98
Copy link
Contributor

@romsharon98 Thanks for the tip about regression.

It got me thinking about what actually needs to be tested.

At this point, the only relevant test case is for core.execution_api_server_url, which is already covered and passing.

If in the future additional defaults are applied, they will be separately tested.

Have any suggestions?

Just wondering how it's passing before the change..

@bdsoha
Copy link
Contributor Author

bdsoha commented Jun 20, 2025

@romsharon98

Because merge mutates the first map you pass in and then returns that very same map.
deepCopy duplicates the map, and merge then modifies the copy.

I made a few changes to the code:

  • Swapped the logic to use a safer deepCopy instead.
  • Added a stricter test assertion to check the trailing /.

@romsharon98
Copy link
Contributor

@romsharon98

Because merge mutates the first map you pass in and then returns that very same map.

deepCopy duplicates the map, and merge then modifies the copy.

I made a few changes to the code:

  • Swapped the logic to use a safer deepCopy instead.

  • Added a stricter test assertion to check the trailing /.

Thanks for the clarification:)

@romsharon98 romsharon98 merged commit 9cd74b0 into apache:main Jun 20, 2025
67 checks passed
@bdsoha bdsoha deleted the feature/helm-use-merged-config-values branch June 20, 2025 12:26
RoyLee1224 pushed a commit to RoyLee1224/airflow that referenced this pull request Jun 21, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:helm-chart Airflow Helm Chart

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants