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

Futures have inconsistent behavior in bash app fn body #35

Closed
yadudoc opened this Issue Oct 6, 2017 · 2 comments

Comments

Projects
None yet
1 participant
@yadudoc
Contributor

yadudoc commented Oct 6, 2017

Eg :

@App('bash', dfk)
def app1(inputs=[], outputs=[], stdout=None, stderr=None, mock=False ):
    cmd_line = '''echo 'test' > {outputs[0]}'''

@App('bash', dfk)
def app2(inputs=[], outputs=[], stdout=None, stderr=None, mock=False ):

    with open('somefile.txt', 'w') as f:
        f.write("%s\n" % inputs[0])          #<--------------- Here inputs[0] is a DataFuture
    cmd_line = '''echo '{inputs[0]}' > {outputs[0]}'''
app1_future = app1(inputs = [],
                       outputs = [ "simple-out.txt"])
#app1_future.result()                                                                                                                                                    

app2_future = app2(inputs=[app1_future.outputs[0]],
                       outputs = ["simple-out2.txt"])
app2_future.result()

One fix is to evaluate the fn body entirely at app execution time. This need some work.

@yadudoc yadudoc added the bug label Oct 6, 2017

@yadudoc yadudoc added this to the Parsl-0.3.0 milestone Oct 6, 2017

@yadudoc yadudoc self-assigned this Oct 6, 2017

yadudoc added a commit that referenced this issue Oct 19, 2017

@yadudoc

This comment has been minimized.

Show comment
Hide comment
@yadudoc

yadudoc Nov 1, 2017

Contributor

This issue is addressed by issue #37 and fixes are included in branch restructuring_libsubmit by 98f8d40

Contributor

yadudoc commented Nov 1, 2017

This issue is addressed by issue #37 and fixes are included in branch restructuring_libsubmit by 98f8d40

yadudoc added a commit that referenced this issue Nov 2, 2017

@yadudoc

This comment has been minimized.

Show comment
Hide comment
@yadudoc

yadudoc Nov 2, 2017

Contributor

Tests passing on branch:restructuring_libsubmit. Closing.

Contributor

yadudoc commented Nov 2, 2017

Tests passing on branch:restructuring_libsubmit. Closing.

@yadudoc yadudoc closed this Nov 2, 2017

benclifford pushed a commit that referenced this issue Aug 9, 2018

annawoodard pushed a commit that referenced this issue Sep 24, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment