diff --git a/CHANGELOG.md b/CHANGELOG.md
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,3 +1,7 @@
+# 0.17.2
+
+* Fixed an incompatibility with MPD.hs an xmonad-contrib version 0.18+.
+
 # 0.17.1
 
 * Add window inversion module.
diff --git a/XMonad/Prompt/MPD.hs b/XMonad/Prompt/MPD.hs
--- a/XMonad/Prompt/MPD.hs
+++ b/XMonad/Prompt/MPD.hs
@@ -185,7 +185,9 @@
 -- @since 0.13.2
 addAndPlayAny :: RunMPD -> XPConfig -> [Metadata] -> X ()
 addAndPlayAny runMPD xp metas = do
-#if MIN_VERSION_xmonad_contrib(0,16,9)
+#if MIN_VERSION_xmonad_contrib(0,18,1)
+  hist <- historyCompletionP xp (showXPrompt (MPDPrompt "Search: ") ==)
+#elif MIN_VERSION_xmonad_contrib(0,16,9)
   hist <- historyCompletionP (showXPrompt (MPDPrompt "Search: ") ==)
 #else
   let hist = historyCompletionP (showXPrompt (MPDPrompt "Search: ") ==)
diff --git a/xmonad-extras.cabal b/xmonad-extras.cabal
--- a/xmonad-extras.cabal
+++ b/xmonad-extras.cabal
@@ -1,5 +1,5 @@
 name:               xmonad-extras
-version:            0.17.1
+version:            0.17.2
 homepage:           https://github.com/xmonad/xmonad-extras
 synopsis:           Third party extensions for xmonad with wacky dependencies
 description:        Various modules for xmonad that cannot be added to xmonad-contrib
@@ -86,7 +86,7 @@
         other-modules:   XMonad.Config.Alt.Types
 
     if flag(with_dbus)
-        build-depends: dbus >= 1.2 && < 1.3
+        build-depends: dbus >= 1.2 && < 1.4
         exposed-modules: XMonad.Actions.Invert
 
     exposed-modules: XMonad.Hooks.PerWindowKbdLayout
