Skip to content
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

Print total files processed even when they all error (import media command) #2005

Closed
kevinfodness opened this issue Aug 27, 2024 · 0 comments · Fixed by #2012
Closed

Print total files processed even when they all error (import media command) #2005

kevinfodness opened this issue Aug 27, 2024 · 0 comments · Fixed by #2012

Comments

@kevinfodness
Copy link
Contributor

Expected/Desired Behavior

When importing an archive of media files via vip import media, if all files in the archive error out, no status is printed. This can happen if importing an archive of files that was already imported to the platform without asking the command to overwrite files, in which case it will skip them because they've already been imported. It would be ideal to still print the number of total files, but show zero processed, like Imported Files: 0/100 - 0%

Actual Behavior

The line that normally includes the number of imported files vs. the total files in the archive is missing, like this:

=============================================================
Importing Media into your App...

=============================================================
Status: COMPLETED ✓ : The imported files should be visible on your App

Steps to Reproduce the Problem

  1. Use the vip import media command to import an archive of images into your application.
  2. Re-run the import with the same archive and observe that the line that normally prints the number of processed files vs. total files is missing.

(Optional) Additional notes

I believe the issue is that this line is checking to see if any files have been processed, which in the case of errors will always be zero:

if ( this.status.filesProcessed && this.status.filesTotal ) {
- it would be ideal to only check the total number of files so that progress can be shown immediately, updated when files are processed, and will be available after the command has finished executing so the user can verify the total number of processed files, even if they have all errored out.

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 a pull request may close this issue.

1 participant