You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@daffodil.apache.org by "Steve Lawrence (Jira)" <ji...@apache.org> on 2020/09/11 20:26:00 UTC

[jira] [Resolved] (DAFFODIL-2387) CLI: Delete infoset file if there is an error

     [ https://issues.apache.org/jira/browse/DAFFODIL-2387?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Steve Lawrence resolved DAFFODIL-2387.
--------------------------------------
    Fix Version/s: 3.0.0
       Resolution: Won't Fix

Agreed, standard behavior people are familiar with is to not delete output on failure. Resolving as won't fix.

> CLI: Delete infoset file if there is an error
> ---------------------------------------------
>
>                 Key: DAFFODIL-2387
>                 URL: https://issues.apache.org/jira/browse/DAFFODIL-2387
>             Project: Daffodil
>          Issue Type: Bug
>          Components: CLI
>            Reporter: Steve Lawrence
>            Priority: Minor
>              Labels: beginner
>             Fix For: 3.0.0
>
>
> The CLI -o option specifies an output file that Daffodil should write the infoset to (or unparse data to). If there is an error during parse/unparse (e.g. non-backtrackable parse error, SDE) this file is not deleted which can cause confusion. Especially since in some cases the file could have a partial infoset/data.
> We might want to consider deleting the output file that we create if there is an error to prevent possible confusion. Note that we need to be careful about when we delete it. For example, say the file already existed when we ran Daffodil. In this case Daffodil will truncate the file to zero bytes and then write the output. But if there is an error, do we want to delete it if it already existed? Or maybe we just leave it truncated it to zero bytes (I.e. should we delete a file we didn't create?)



--
This message was sent by Atlassian Jira
(v8.3.4#803005)