I suspect that the path is filled in by the editor, when you duplicate it there. It kind of makes sense that you wouldn't have a path in a duplicate. The easy answer is to copy the path name when you duplicate them in code. I'd make a new property with set_meta() to store it, just in case setting the actual path caused problems.