# How to determine which scene is the new one upon duplication?

Let's say the user has multiple scenes, and some of them may be named Scene.001, etc.

If I do bpy.ops.scene.new(type='FULL_COPY'), how do I know which one is the new one?

Normally I'd expect the new scene to update the context and this to work:

bpy.ops.scene.new(type='FULL_COPY')
copy = bpy.context.scene


It does work if you type it into the console. However, that doesn't appear to be the case if I put this into an addon script (bpy.context.scene seems to update only after the operator is done, which is not useful).

Any ideas how I can determine which scene is the new one? Is this a bug?

• context.scene.name is up-to-date if I print it immediately after the call to scene.new(), please post your code. – CodeManX Dec 18 '14 at 23:38