Top "Exception" questions

An exception is an unusual condition that requires deviation from the program's normal flow.

Mockito test a void method throws an exception

I have a method with a void return type. It can also throw a number of exceptions so I'd like …

java exception mocking mockito
How to write trycatch in R

I want to write trycatch code to deal with error in downloading from the web. url <- c( "http://…

r exception exception-handling try-catch r-faq
Given final block not properly padded

I am trying to implement password based encryption algorithm, but I get this exception: javax.crypto.BadPaddingException: Given final block …

java exception encryption cryptography javax.crypto
How to retry after exception?

I have a loop starting with for i in range(0, 100). Normally it runs correctly, but sometimes it fails due to …

python loops exception try-except
Error: Registry key 'Software\JavaSoft\Java Runtime Environment'\CurrentVersion'?

When I run: C:\Users\ashahria\Downloads>java -jar schemaSpy_5.0.0.jar I get the error below. What is wrong? …

java exception environment runtimeexception
Exception in thread "main" java.lang.UnsupportedClassVersionError: a (Unsupported major.minor version 51.0)

Possible Duplicate: unsupported major .minor version 51.0 I installed JDK7, a simple hello word program gets compile but when I run …

java exception java-7 unsupported-class-version
Why does writeObject throw java.io.NotSerializableException and how do I fix it?

I have this exception and I don't understand why it would be thrown or, how I should handle it. try { …

java exception serialization notserializableexception
What is difference between Errors and Exceptions?

Possible Duplicate: Differences betweeen Exception and Error How can I differentiate between Errors and Exceptions in Java?

java exception
Rethrowing exceptions in Java without losing the stack trace

In C#, I can use the throw; statement to rethrow an exception while preserving the stack trace: try { ... } catch (Exception …

java exception
Getting the exception value in Python

If I have that code: try: some_method() except Exception, e: How can I get this Exception value (string representation …

python exception