Skip to content

fix wrong conditional for build custom_rules.tmpl.xml#1544

Merged
AndreMiras merged 1 commit intokivy:masterfrom
bit4bit:master
Dec 20, 2018
Merged

fix wrong conditional for build custom_rules.tmpl.xml#1544
AndreMiras merged 1 commit intokivy:masterfrom
bit4bit:master

Conversation

@bit4bit
Copy link
Contributor

@bit4bit bit4bit commented Dec 20, 2018

without this, ant debug stop with message:

/root/.buildozer/android/platform/android-sdk-20/tools/ant/build.xml:655: /root/fleet_dispatch_client/.buildozer/android/platform/build/dists/myapp/tmp-src does not exist.

**render_args)

if exists("custom_rules.tmpl.xml"):
if exists(join("templates", "custom_rules.tmpl.xml")):
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure how this works if you fixed the first path in the exists condition, but not the render one which I would have expected to be the same 🤔

Copy link
Contributor Author

@bit4bit bit4bit Dec 20, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hi, because os.path.exists check on filesystem and not use jinja2.Environment, render it's a local function that use the jinja2.Environment.

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@AndreMiras it works because of this line:

(which sets up the environment to be located inside templates, so jinja2 naturally looks in there)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you guys, clear!

**render_args)

if exists("custom_rules.tmpl.xml"):
if exists(join("templates", "custom_rules.tmpl.xml")):
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you guys, clear!

@AndreMiras
Copy link
Member

Looking good thank you. I'm just restarting the build because it flaky failed and will merge pretty soon

@AndreMiras AndreMiras merged commit 03671e9 into kivy:master Dec 20, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants