2012-12-08 21 views
1

我試圖推動本地工作應用的Heroku但正如我說我得到這個錯誤推打2.0.x版本應用的Heroku問題

 [info] Compiling 20 Scala sources and 12 Java sources to /tmp/build_mhfyee4j841a/target/scala-2.9.1/classes... 
     [error] /tmp/build_mhfyee4j841a/target/scala-2.9.1/src_managed/main/views/html/showitem.template.scala:74: value showItem is not a member of controllers.ReverseApplication 
     [error]    <a href=""""),_display_(Seq[Any](/*45.21*/routes/*45.27*/.Application.showItem(p.id, Items.slugify(p.title)))),format.raw/*45.78*/("""" ><img width="110" height="110" alt=""""),_display_(Seq[Any](/*45.118*/p/*45.119*/.title)),format.raw/*45.125*/("""" src=""""),_display_(Seq[Any](/*45.133*/p/*45.134*/.picture)),format.raw/*45.142*/(""""></a> 
     [error]                     ^
     [error] one error found 
     [error] {file:/tmp/build_mhfyee4j841a/}quoiacheter/compile:compile: Compilation failed 
     [error] Total time: 25 s, completed Dec 8, 2012 8:07:38 PM 
!  Failed to build app with sbt 
!  Heroku push rejected, failed to compile Play 2.0 - java app 

的應用程序是在本地,你罰款運行前可以在這裏看到的應該有一個錯誤的部分showitem模板

<p> 
    @for(p <- Items.getRelated(item.categories.get(0).id)) { 
       <a href="@routes.Items.showItem(p.id, Items.slugify(p.title))" ><img width="110" height="110" alt="@p.title" src="@p.picture"></a> 
    } 
</p> 

的Heroku認爲我打電話@routes.Application.showItem,而不是@routes.Items.showItem!你可以在這裏看到我的路線文件的相關部分:

... 
# ITEMS   
GET  /items/:id/:title   controllers.Items.showItem(id: Long,title: String) 
... 
+0

當你在本地運行'play clean'然後'play stage'時會發生什麼? –

回答

0

發生這種情況的唯一原因是,如果你的git庫是不是最新的,不知何故在混帳回購協議呼籲Application,不Items。請檢查您是否真的在本地對git進行了更改。