Fix deprecation messages caused by recent changes to Duration.
Merge pull request #2241 from jmdavis/duration

Fix deprecation messages caused by recent changes to Duration.