irmen / Pyrolite

Java and .NET client interface for Pyro5 protocol
MIT License
178 stars 47 forks source link

Fixes #57 pickle of java.sql.Date objects misses month offset. #58

Closed daanmohlmann closed 6 years ago

daanmohlmann commented 6 years ago

These Date objects are converted to a java Calendar object which has zero-based months, instead of starting at 1 as expected. This results in a month less when picking in java.

Thanks a bunch :)

irmen commented 6 years ago

@daanmohlmann thanks for the PR I appreciate it. But it is incomplete, signalled by the failing unit test. Can you also fix the DateTimeConstructor in this PR in a similar fashion, to make the test pass again?

daanmohlmann commented 6 years ago

@irmen, Thanks for the feedback. You're absolutely right and I actually noticed that today, but didn't run into the problem as I'm using dates with year, month and day, which takes a different path in the DateTimeConstructor apparently.

I've updated the constructor and ran the tests, they're all green now :)

Thank you for the quick action!

irmen commented 6 years ago

release 4.22 should be available on maven central shortly

daanmohlmann commented 6 years ago

Dankjewel Irmen!

Hij staat op maven central, en ik kan waarschijnlijk verder. Veel dank voor je inspanningen.