codeconsole opened a new issue, #15147:
URL: https://github.com/apache/grails-core/issues/15147

   ### Expected Behavior
   
   this worked fine in every version prior to 7.0.0-RC2
   
   ```groovy
   "/contests/$id/submit(.$format)?" (controller: 'contest', action:'submit')
   ```
   
   ```groovy
   class ContestController {
       def submit(long id, long images) {}
   }
   ```
   
   results in 
   
   ```
   2025-10-16T10:15:25.907-07:00 ERROR 69893 --- [cat-handler-402] 
   o.g.web.errors.GrailsExceptionResolver   : Cannot cast object '1000311' with 
class 'java.lang.String' to class 'long'
   org.codehaus.groovy.runtime.typehandling.GroovyCastException: Cannot cast 
object '1000311' with class 'java.lang.String' to class 
   'long'
       at 
java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:104)
 
   ```
   
   which is weird because there is not a complete stack trace.
   
   Workaround:
   ```groovy
   class ContestController {
       def submit(long id, long images) {}
   }
   ```
   
   ### Actual Behaviour
   
   _No response_
   
   ### Steps To Reproduce
   
   _No response_
   
   ### Environment Information
   
   _No response_
   
   ### Example Application
   
   _No response_
   
   ### Version
   
   7.0.0


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to