Pymel

Latest version: v1.3.1

Safety actively analyzes 613461 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 1 of 3

1.3.1

==================================

----------------------------------
Fixes
----------------------------------
- Fix issue with `mel2py` in python3 (issue 465)

==================================

1.3.0

==================================

----------------------------------
Additions
----------------------------------
- all: Add maya-2023 and python 3.9 support
- all: Major update to pyi type stubs.
Most auto-generated functions & methods now include type info for all arguments,
including both short and long variants for functions generated from MEL/`maya.cmds`.
The stubs are distributed as part of the pymel package in a PEP 561-compatible way,
so that they will be automatically discovered by IDEs and static type analyzers like mypy.

----------------------------------
Non-Backward Compatible Changes
----------------------------------
- dropped support for maya-2018

----------------------------------
Fixes
----------------------------------
- Fix language.Env.host() (issue 460)
- Do not use 'is' when comparing to string literals (issue 449)
- Fix bug where maybeConvert returned None for 0 (issue 448)
- Fix incompatible use of __import__ on python3 (issues 447 and 445)

==================================

1.2.0

==================================

----------------------------------
Additions
----------------------------------
- all: Add maya-2022 and python3 support!
- all: Add support for pip installing pymel, and uploading to pypi
- api: add support for MPxTransform_BoundingBox
- Update PLY to 3.11

==================================

1.1.0

==================================

----------------------------------
Non-Backward Compatible Changes
----------------------------------
- removed support for maya versions before 2017
- general: AttributeSpec.parent() now returns None instead of erroring
- datatypes: Quaternion.asEulerRotation now returns a datatypes.EulerRotation
as intended, instead of OpenMaya.MEulerRotation; since dt.EulerRotation
inherits from om.MEulerRotation, they should mostly be compatible, but if you
need a om.MEulerRotation, just cast directly - ie,
om.MEulerRotation(dt.Quaternion().asEulerRotation())
- uitypes: OptionMenuGrp.getParent() now returns a PyUI object, instead of a
string, as intended. This brings it's behavior in line with most other PyUI
.getParent() calls, including RowLayout.getParent() and Layout.getParent(),
from which OptionMenuGrp inherits
- uitypes: PopupMenu.getItemArray() now returns PyUI objects, instead of
strings, as intended. This brings it's behavior in line with Menu
.getItemArray(), from which it inherits
- nodetypes: Due to a bug, the following methods were wrapped on a random
scattering of subclasses of the named classes. They were ever intended to be
wrapped at all. They are all being removed - exact methods and reasoning
below:

- **DagNode.setObject**: dangerous - changes the node we're wrapping out from
underneath us
- **DependNode.addAttribute**: dangerous, because it only took
AttributeSpec objects as inputs. In addition to being fairly obscure,
they are mostly constructed from existing attributes - but the API
explicitly warns against adding an attribute using an MObject that's already
added to another node. Use addAttr method instead.
- **DependNode.attribute**: too confusing to have both "attr" and "attribute"
which return different types of objects. Use attrSpec instead. Also, the old
wrap only worked with integer indices, which wasn't useful in most
situations (attrSpec works with either string names, Attribute objects, or
indices).
- **DependNode.findPlug**: dangerous, as it allowed returning networked mplugs.
Use attr method instead. The api docs warn that networked plugs should not
be used if you might be breaking connections, thus why these are
considerered dangerous. Also, it only worked when fed AttributeSpec, a
little known / used part of pymel.
- **DependNode.reorderedAttribute**: obscure, and apparently only useful
during file IO
- **Shape.dagPath**: useless, as it just always returned self
- **Shape.getPath**: useless, as it just always returned self

----------------------------------
Changes
----------------------------------
- all: The basic way methods and commands are wrapped has been altered.
Formerly, all items were wrapped dynamically, at runtime; now, they are
wrapped and "baked", using templates, when a pymel release is made. The end
result should be code that is more much readable and understandable for end
users.
- all: Converted to a new .py/.pyc.zip cache format. Improved pymel import
times, in addition to being more readable/diffable/maintainable
- general: AttributeDefaults renamed to AttributeSpec, which better reflects
what it is: a specification for the type on an attribute, not associated with
any single node. The AttributeDefaults name is preserved as an alias for
backwards compatibility.
- nodetypes: Due to a bug, the following methods were wrapped on a random
scattering of subclasses of the named classes. They were ever intended to be
wrapped at all. They are being marked as deprecated, and will raise a
warning, if used on any of the subclasses for which they are implemented:

DependNode.findAlias, DependNode.getAffectedAttributes, DependNode
.getAffectedByAttributes, DependNode.getAliasList, DependNode
.getConnections, DependNode.plugsAlias, DependNode.setAlias, Transform
.getRotationQuaternion, Transform.setRotationQuaternion

- nodetypes: The following methods were removed from Shape: model, removeChild,
and removeChildAt. They were never intended to be wrapped, and were non-
functional, so removing them should not introduce any backwards-compatibility
issues.
- nodetypes:Shape.getAllPaths was moved from Shape to DagNode, and marked
deprecated. It was only wrapped as a result of a bug, it has a misleading name
(it returns PyNodes, not paths), and is functionally equivalent to
getInstances(). However, since it may have been in use, and we don't wish to
break backward compatibility, we are marking it as deprecated. We are moving
it to DagNode, instead of Shape, because the fact that it was defined on
Shape and not Transform made it give incorrect / misleading results. This is
because the Transform node will check it's first shape for attributes it
can't find defined on itself - the net result is that, even though it's not
defined on Transform, if it had a shape, it would "appear" to be, but return
the "wrong" results - ie PyNodes corresponding to all instances of the
first shape, NOT the transform itself.
- nodetypes: AnimCurve.timedAnimCurveTypeForPlug/unitlessAnimCurveTypeForPlug
turned into classmethods, as they don't require / operate on a specific
AnimCurve
- conf: add a new setting to pymel.conf, "deleted_pynode_name_access", to
to control the behavior when a deleted node's name is queried / used. The
current behavior - of issuing a warning, but returning the old name - is now
deprecated, and at some point the default will be changed to "error", which
will cause pymel to raise a DeletedMayaNodeError. If you wish to keep the
old behavior - and not be nagged that it may be changed at some point the
future - change the setting to "warn". You may also set it to "ignore" if you
want to not even issue a warning. (The current default setting is
"warn_deprecated", which will behave just like "warn", except with an
additional FutureWarning to remind you to change the setting in pymel.conf)
- util: Singleton: eliminate DeprecationWarning for object.__init__(*p, **k)
- nodetypes: tweak new constraint-weight-query syntax - we now allow
constraint(q=1, weight=True), instead of constraint(q=1, weight=[]); also,
may use a tuple (or other non-list iterable) for weight

- general: remove unused kwargs for Attribute.affects/affected
- uitypes: make a base PyUIContainer parent class for Layout and Window
- mel2py: removed findMelOnlyCommands(), as it wasn't working, unused, and never
intended to be publicly exposed.
(https://github.com/LumaPictures/pymel/issues/412)

----------------------------------
Additions
----------------------------------
- all: Add maya-2019 support
- all: python-3 / "typing" style type comments added to many / most commands
and methods
- general: AttributeSpec may now be constructed from a string (which names an
existing Attribute), an Attribute, an MPlug, or another AttributeSpec.
DependNode.attrSpec now also accepts all these objects as well.
- uitypes: Many layout flags were were not wrapped on Layout; they now are,
which also means all sub-classes inherit these methods as well (though many
subclasses already had their own overrides for many of these commands). The
full set of new methods on Layout is:

dragCallback, dropCallback, getAnnotation, getBackgroundColor, getChildArray,
getDocTag, getEnable, getEnableBackground, getFullPathName, getHeight,
getHighlightColor, getIsObscured, getManage, getNumberOfChildren,
getNumberOfPopupMenus, getPopupMenuArray, getPreventOverride, getVisible,
getVisibleChangeCommand, getWidth, noBackground, setAnnotation,
setBackgroundColor, setDocTag, setEnable, setEnableBackground, setHeight,
setHighlightColor, setManage, setPreventOverride, setVisible,
setVisibleChangeCommand, setWidth, statusBarMessage

- nodetypes: Some api method wraps were re-enabled on DependNode, DagNode, and
ObjectSet. Formerly, some of these methods were implemented on some
subclasses of these node types; they are now uniformly available on the base
node. Note that some of these methods represent new functionality, while
others merely duplicate existing functionality (ie, DagNode.partialPathName
<=> DagNode.name); however, we wanted to provide a uniform interface, and did
not want to break backward compatibility, so they were enabled on their base
classes. The set of new methods is:

Camera.getFarClippingPlane, Camera.setFarClippingPlane,
Camera.getNearClippingPlane, Camera.setNearClippingPlane,
DagNode.fullPathName, DagNode.isInstancedAttribute, DagNode.partialPathName,
DagNode.setInstanceable, DependNode.allocateFlag, DependNode.attributeClass,
DependNode.deallocateAllFlags, DependNode.deallocateFlag,
DependNode.dgCallbacks, DependNode.dgTimer, DependNode.dgTimerOff,
DependNode.dgTimerOn, DependNode.dgTimerQueryState, DependNode.dgTimerReset,
DependNode.getAliasAttr, DependNode.hasAttribute, DependNode.isNewAttribute,
DependNode.removeAttribute, DependNode.setFlag, DependNode.typeName,
ObjectSet.addMember, ObjectSet.isMember, ObjectSet.removeMember

- nodetypes: Transform.rotateByQuaternion added, and accepts either a
Quaternion/MQuaternion or four separate floats
- nodetypes: DependNode.deleteAttr now accepts Attribute objects (first
verifying that it is an attribute on the same node as self)
- nodetypes: Added a DependNode.typeName classmethod - similar to
DependNode.type / general.nodeType, but unlike those, it does not require an
actual instance of a node, or call any mel / api functions - instead, it just
returns the type that the given class wraps. When called from an instance,
should always give the same result as DependNode.type, since pymel always
ensures that the most specific node class is used to create any PyNode
- nodetypes: Undo support added to a number of AnimCurve methods:

addKeys, addKeysWithTangents, insertKey, remove, setAngle, setBreakdown,
setInTangentType, setOutTangentType, setPostInfinityType,
setPreInfinityType, setTangentTypes, setTangentsLocked, setTime,
setUnitlessInput, setValue, setWeight, setWeighted, setWeightsLocked

- util.enum: EnumValue objects now have a __hash__, and so can be stored in dicts / sets
- versions: add v2018_1, v2018_1, v2018_2, v2019_3, v2019
- general: added getDefault method to Attribute class - thanks Bob White!
- language: allow optionvars to save long types - thanks Jordan Hueckstaedt!
- all: standardize on numpy-style docstrings with PEP484 type annotations.
- general: allow adding of 2 (1-dimensional) components - ie, you can now add
two MeshVertex objects, containing verts for the same mesh, together to get
a new MeshVertex object representing their union
- nodetypes: add Transform.getRotateOrientation / setRotateOrientation
these are distinct from the existing getRotateAxis / setRotateAxis
(from MEL), because they operate on quaternions, which are what the
transform "actually" stores under the hood - and so it seems potentially
useful to give direct access.
- general: expand types of objects that AttributeSpec constructor accepts -
str, Attribute object, AttributeSpec object, MPlug, MObject
- nodetypes: make DependNode.deleteAttr work with Attribute
- datatypes: expand set of things you can construct a Quaternion with: lists
of floats, ints, another Quaternion, an MQuaternion, axis-angle, rotate
vector-to-vector
- nodetypes: added an undoable Camera.setNearFarClippingPlanes
- system: UndoChunk can take an optional chunk "name" to show up in undo list
- nodetypes: make creation of RenderLayer() / DisplayLayer() use mel cmds
this way, they are hooked up to renderLayerManager / displayLayerManager
also, gives more options on creation. However, they are created empty by
default, to match old behavior

----------------------------------
Bug Fixes
----------------------------------
- uitypes.OptionMenu.getItemArray() now fixed, and returns PyUI objects
- nodetypes: fixed issue with DependNode.attrSpec incorrectly caching dynamic
attrs
- datatypes: fix getPlugValue for Angle and Time plugs (would error previously)
- core: Added defensive code to prevent callback id leaks in some scenarios
...thanks David Lassonde!
- core: fixed bug where api commands that errored would still create an undo
entry
- nodetypes: THblendShape was incorrectly mapped to kPluginSkinCluster
- nodetypes: fix DagNode.exists() (was raising error in some situations)
- general: fix indexing components with an iterable - ie, myMesh.f[(1,2,5)]
- nodetypes: fix for ikHandle not returning PyNodes (issue 410)
- general: fix for parenting with grouping of args; fixes issue 406
- virtual nodes: fix for plugins.PyNodeMethod
- nodetypes: fix for creating PyNode wraps for node types added outside of
plugin init - ie, some mtoa nodes get created outside of the plugin init
- core: fix for plugin unloaded callback when using plugin name with extension -
ie, pm.unloadPlugin("myPlugin.py")
- nodetypes: make TransferAttribute use MFnWeightGeometryFilter
- nodetypes: AnimCurve.addKey / evaluate / AnimCurve.findClosest now work for
all curve types, not just time-to-float types
- nodetypes: fix for creation of Locator() - thanks bob-white!
- nodetypes: fix DisplayLayer.removeMembers - thanks Akshay!
- general: deal with connectAttr error that contains unicode
(https://github.com/LumaPictures/pymel/issues/402)
- nodetypes: fix bug when creating AngleBetween node
(https://github.com/LumaPictures/pymel/issues/416)


==================================

1.0.10

==================================

----------------------------------
Changes
----------------------------------
- default testing engine changes to pytest (from nose)
- remove ply as requirement, as we have pymel.util.external.ply
- utilitytypes: make LazyLoadModule a class, not func

----------------------------------
Additions
----------------------------------
- added support for 2018
- system: add FileReference.nodes(recursive=True) flag
- Adding pm.isModified function (replacement for cmds.file(q=1, modified=1)
(thanks, bob-white!)
- Added file reference remove flags (thanks, wesbondie!)
- added mergeNamespaceWithParent and mergeNamespaceWithRoot to
FileReference.remove to match docs (thanks mjmvisser!)
- add kwargs support to getClassfication - issue 343 (thanks kartikg3!)
- plugins: add FileTranslator plugin helper base class to pymel.api.plugins
- util.enum: add Enum.itervalues
- maintenance: make stub generation more general-purpose; add cli
- stubs: improvements to PEP484 pyi stub file generation
- tests support pytest now

----------------------------------
Bug Fixes
----------------------------------
- fix for Attribute equality for compound multi attrs
- cmds.file(new=1, type='mayaAscii') will crash maya - pm.newFile() will now
automatically ignore any type/typ flags to avoid this - issue 346
(thanks bob-white!)
- fix for mesh.numTriangles() raising a TypeErorr - issue 388
(thanks kartikg3!)
- fix for uitypes.Menu.getItemArray exceptions (thanks bob-white!)
- plogging: fix for setting of root logging level (thanks sdalgo!)
- fix to deal with nodes showing up multiple times in inheritance tree from
cmds.nodeType (ie, aiSkyDomeLight)
- ipymel now working again with modern versions of IPython
- fix for PyNode becoming invalid if instance is reparented in some situations
- deprecated api-wrapped functions weren't returning values
- dynamically create PyNodes from nodetypes - fixes issue with some maya node
types that can't get detected on plugin load
- fix for hasParent/hasChild/isParentOf/isChildOf with underworld nodes
- pm.parent will set PyNodes fed in to use the correct instance / parent
- better fix for mayapy segfaults (run maya.standalone.uninitialize)
- factories: some functions using MFloatPoint weren't doing unit conversion
- some node types that are dag nodes don't work with MFnDagNode - however,
.nodeName() should still work (as that doesn't need MFnDagNode)
- nodetypes: attempt to deal with crash with instances;
get it when you add an instance of an object, and then access the old object;
this doesn't completely solve the issue, but it may be impossible to avoid
completely without a patch for the underlying problem from autodesk
- fix for pm.listNamespaces() returning duplicates weed out - issue 380
(thanks mjmvisser!)
- datatypes: fix to deal with new swig-generated setattr in 2018
- factories: fix for fromInternalUnits with ref-casts
- factories: fix for isMayaType, for weird types
(ie, TadskAssetInstanceNode_TdependNode, which is a parent of adskMaterial)
- factories: prefer non-deprecated api methods
- startup: fix some hangs on exit in maya 2016.51
- pymel.conf: fix name of fix_linux_mayapy_segfault
- stubs: fix for detection of os.environ


==================================

1.0.9

==================================

----------------------------------
Changes
----------------------------------
- turn fixMayapy2011SegFault on by default, control with config

----------------------------------
Additions
----------------------------------
- added support for 2017
- Added support for PySide2

----------------------------------
Bug Fixes
----------------------------------
- arrays: fix error messages for non-existent axes (issue 369)
- general: remove hard-coded getSetAttrCmds; also fix tests (default is short attr names)
- general: Fix for showNamespaces breaking ls
- general: Mesh*.connected* raises error if list is empty (issue 367)
- general: Fix a bug where parenting to a non-existent node did not raise an error
- language: restore gFilterUIDefaultAttributeFilterList, in prep for autodesk fix
- ui: textField and text lose their type (issue 349)


==================================

Page 1 of 3

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.