Skip to content

Commit

Permalink
Fix #1971: bpu.types.Sequence no longer defined
Browse files Browse the repository at this point in the history
This was renamed to Strip in 4.4.
  • Loading branch information
OmarEmaraDev committed Jan 25, 2025
1 parent 8a98c9e commit a45df0d
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@

### Fixed

- Fixed Sequence sockets for recent API change.

### Changed

## 2.3 (25 January 2025)
Expand Down
6 changes: 3 additions & 3 deletions animation_nodes/sockets/sequence.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import bpy
from bpy.props import *
from bpy.types import Sequence
from bpy.types import Strip
from .. events import propertyChanged
from .. base_types import AnimationNodeSocket, PythonListSocket

Expand Down Expand Up @@ -54,7 +54,7 @@ def getDefaultValueCode(cls):

@classmethod
def correctValue(cls, value):
if isinstance(value, Sequence) or value is None:
if isinstance(value, Strip) or value is None:
return value, 0
return cls.getDefaultValue(), 2

Expand All @@ -75,6 +75,6 @@ def getCopyExpression(cls):
@classmethod
def correctValue(cls, value):
if isinstance(value, list):
if all(isinstance(element, Sequence) or element is None for element in value):
if all(isinstance(element, Strip) or element is None for element in value):
return value, 0
return cls.getDefaultValue(), 2

0 comments on commit a45df0d

Please sign in to comment.