fixes #2500
fixed parent publishing
fixed tests
Merge pull request #2529 from digi604/publish_position

publish order stays correct