Skip to content

BUG: IMAGEPASTE_OT_move_to_save_directory throws a TypeError on save in Blender 4.5. #64

@Pluglug

Description

@Pluglug

Describe the bug

Summary

IMAGEPASTE_OT_move_to_save_directory throws a TypeError on save in Blender 4.5.
Before I invest time fixing this, I’d like to confirm whether ImagePaste is still expected to be maintained or if full integration into Blender has superseded it.

Environment

  • Blender 4.5 LTS
  • Windows 10
  • ImagePaste v1.8.2

Steps to Reproduce

  1. Enable ImagePaste.
  2. Paste an image (Ctrl-Shift-V) → works.
  3. Save the .blend file → exception occurs.

Traceback

TypeError: IMAGEPASTE_OT_move_to_save_directory.__init__() takes 1 positional argument but 2 were given
File "…/preferences.py", line 262, in move_to_save_directory_handler
bpy.ops.imagepaste.move_to_save_directory("INVOKE_DEFAULT")

Root Cause (suspected)

Blender 4.4+ changed the rules for subclassing operator classes;
__init__ now must forward *args, **kwargs to super().__init__
(see https://developer.blender.org/docs/release_notes/4.4/python_api/#subclassing-blender-types).

Question(s)

  1. README has said “This Addon is soon to be deprecated as the functionality is being integrated into Blender itself!” since 2023-07-21.
    Is there a public tracker or design task for View3D/Sequencer paste integration?
  2. If ImagePaste is still meant to support post-4.2 Blender, I’m willing to open a PR that:
    • fixes the __init__ signature issue,
    • updates handler registration,
    • tests on 4.5 across Win/macOS/Linux.
      Let me know if that contribution would be welcome.

Thanks for clarifying the roadmap!

Step to reproduce

  1. Enable ImagePaste.
  2. Paste an image (Ctrl-Shift-V) → works.
  3. Save the .blend file → exception occurs.

Relevant log output

TypeError: IMAGEPASTE_OT_move_to_save_directory.__init__() takes 1 positional argument but 2 were given
File "…/preferences.py", line 262, in move_to_save_directory_handler
bpy.ops.imagepaste.move_to_save_directory("INVOKE_DEFAULT")

Expected behavior

When I save the .blend file:

  • Any images that were pasted via ImagePaste should be moved from the temp
    folder to the directory defined in the add-on prefs (default: a sub-folder
    next to the .blend).
  • File paths inside Blender should update to a relative path, so re-opening
    the file shows the images with no “missing data” warnings.
  • The operation should run silently from the save_post handler—no dialogs,
    no errors or warnings in the console.

In short: saving a file after pasting images should “just work”.

Platform

Windows

Platform version

22H2

Blender version

Other

ImagePaste Version

1.8.2

Metadata

Metadata

Labels

bugSomething isn't working

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions