-
Notifications
You must be signed in to change notification settings - Fork 445
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
project loader, schema: add advanced grammar support for build-environment #3350
Conversation
3366aec
to
6b5ba35
Compare
Grammar changes are complete, I'm going to split that into it's own PR, with build-environment changes coming separately. |
6b5ba35
to
ffabfd2
Compare
0e0d8e8
to
551f841
Compare
Codecov Report
@@ Coverage Diff @@
## master #3350 +/- ##
==========================================
- Coverage 90.75% 90.73% -0.02%
==========================================
Files 257 256 -1
Lines 18230 18206 -24
==========================================
- Hits 16544 16520 -24
Misses 1686 1686
Continue to review full report at Codecov.
|
…nment Drop the _list_of_dicts_to_env() conversion and account for the data structure as-is when using it. Signed-off-by: Chris Patterson <chris.patterson@canonical.com>
551f841
to
a2f6c76
Compare
Units are failing |
@@ -646,7 +641,7 @@ def _generate_part_env(self, step: steps.Step) -> str: | |||
for k, v in plugin_environment.items(): | |||
print(f'export {k}="{v}"', file=run_environment) | |||
print("## User Environment", file=run_environment) | |||
for env in user_build_environment: | |||
for env in self.build_environment: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
for env in self.build_environment: | |
# Part's (user) say. | |
for env in self.build_environment: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done.
@@ -646,7 +641,7 @@ def _generate_part_env(self, step: steps.Step) -> str: | |||
for k, v in plugin_environment.items(): | |||
print(f'export {k}="{v}"', file=run_environment) | |||
print("## User Environment", file=run_environment) | |||
for env in user_build_environment: | |||
for env in self.build_environment: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
or (I prefer this even if it is more code) combined with the change some lines of code prior
for env in self.build_environment: | |
for env in user_build_environment: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done.
@@ -630,9 +628,6 @@ def _generate_part_env(self, step: steps.Step) -> str: | |||
else: | |||
plugin_environment = dict() | |||
|
|||
# Part's (user) say. | |||
user_build_environment = self._part_properties["build-environment"] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
code suggestions not working for removed lines, I would keep user_build_environment but = self.build_environment
This makes the code obvious to casual readers. The "user" part of this variable name was your idea ;-)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Makes sense, will do
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done.
Signed-off-by: Chris Patterson <chris.patterson@canonical.com>
Only test failing is plainbox. |
…nment (canonical#3350) Drop the _list_of_dicts_to_env() conversion and account for the data structure as-is when using it. Signed-off-by: Chris Patterson <chris.patterson@canonical.com>
No description provided.