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

Project auto save exception #3190

Closed
millpaub opened this issue Jan 21, 2020 · 8 comments · Fixed by #3191
Closed

Project auto save exception #3190

millpaub opened this issue Jan 21, 2020 · 8 comments · Fixed by #3191

Comments

@millpaub
Copy link

Describe the bug
A clear and concise description of what the bug is.
On export, the process shuts down about 40% through the process. No errors are displayed.
Loaded the lasts daily build with no noticeable changes.

A clear and concise description of what the bug is.

Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Expected behavior
A clear and concise description of what you expected to happen.

System Details

Log Files

Exception / Stacktrace
No stacktrace found in log files

Screenshots (Optional)
If applicable, add screenshots to help explain your problem. You can include screenshots by
copy/pasting them on GitHub or dragging-and-dropping into the GitHub page. All images are public,
so please don't post screenshots containing personal information.

@ferdnyc
Copy link
Contributor

ferdnyc commented Jan 21, 2020

Traceback (most recent call last):
  File "C:\Program Files\OpenShot Video Editor\windows\main_window.py", line 643, in auto_save_project
    recover_path_with_timestamp = os.path.join(info.RECOVERY_PATH, "%d-%s.osp" % (int(time()), file_name))
TypeError: 'module' object is not callable
     metrics:INFO Track exception: [200] http://www.openshot.org/exception/json/ | *failed-recording-exception*: Control/space characters not allowed (key=b":1:Windows-2.5.0-TypeError: 'module' object is no")
 main_window:INFO auto_save_project
  exceptions:ERROR Unhandled Exception
Traceback (most recent call last):
  File "C:\Program Files\OpenShot Video Editor\windows\main_window.py", line 643, in auto_save_project
    recover_path_with_timestamp = os.path.join(info.RECOVERY_PATH, "%d-%s.osp" % (int(time()), file_name))

Thanks for the report. This should be easy to fix, it looks like a recent bug introduced into the autosave routine.

ferdnyc added a commit that referenced this issue Jan 21, 2020
This is an attempt to address the (frankly _weird_) error from the logs in #3190, which appears to come down to Python getting confused when `time.time()` is imported over its own module name. Instead we `import time` when needed and call it as `time.time()`.

Fixes #3190 (hopefully?)
@ferdnyc
Copy link
Contributor

ferdnyc commented Jan 21, 2020

@millpaub

Hopefully #3191 will fix this, if and when it merges we'll have a new Daily Build for testing. But in the meantime, it looks like you're getting bit by a slightly weird autosave bug, so the workaround would be to simply turn off autosave (in the Preferences).

@millpaub
Copy link
Author

millpaub commented Jan 21, 2020 via email

@SuslikV
Copy link
Contributor

SuslikV commented Jan 22, 2020

... I noticed on the export panel that the “cancel” button is highlighted when the export is processing.

Because there is no other button available when process of video export already started, only new confirmation dialog can be added, like "OpenShot's export. Are you sure wish to cancel the video export? Yes/No." where "No" can be default button. Is this OK solution? I usually don't like a lot of confirmations but rendering can be time consuming task and restarting it will be boring.

@ferdnyc
Copy link
Contributor

ferdnyc commented Jan 22, 2020

The computer had been replaced and not all of the settings had been updated on the new computer. I moved the files to another machine and completed the export on it. During that time, I was reviewing what had happened during export on the other computer. I noticed on the export panel that the “cancel” button is highlighted when the export is processing. What happened was the screen delay was set to 15 minutes, once it went blank, I would hit the return key, which canceled the export. Is there a way to alter the program in such a way that it doesn’t automatically highlight the “cancel” button?

It's worth looking into, sure.

Though, at the same time — not to try and redirect the issue, and like I said I do agree the input-focused Cancel is worth trying to correct — I'd recommend getting in the habit of unblanking your screen with a "known-safe" keypress. I use Shift, personally. Nothing will ever happen as a side-effect of pressing Shift. 😆

@ferdnyc
Copy link
Contributor

ferdnyc commented Jan 22, 2020

@SuslikV

Yeah, thinking about it more, a confirmation dialog probably makes more sense than worrying about input focus.

...Just as long as "Yes" isn't the default response on the confirmation dialog, or we're right back where we started. 😉

@SuslikV
Copy link
Contributor

SuslikV commented Jan 22, 2020

@ferdnyc many people right-handed, it is easy to miss the Shift button and press Enter instead...

I made PR (#3193) to add confirmation dialog. Maybe it worth to look at. Edit: it's too complicated, I know. You prefer one-line solutions.

@ferdnyc
Copy link
Contributor

ferdnyc commented Jan 22, 2020

@ferdnyc many people right-handed, it is easy to miss the Shift button and press Enter instead...

Of course. Nothing's foolproof. But it sounds very much like @millpaub was aiming for Enter, nothing accidental about it.

Heck, if someone's really worried about missing Shift, they can always aim for Ctrl, and then if they miss they'll hit Shift or Menu. Point is, modifier keys are especially good choices for "no-consequence" input events, since they rarely have any significant effect unless combined with another key.

@DylanC DylanC changed the title (Give your bug report a descriptive title) Project auto save exception Jan 22, 2020
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.

3 participants