Incorrect RawOffset loading Appointment from ics file

Hi

Evaluating Aspose.Email for Java 4.3.0, I receive the error;

class com.aspose.email.system.exceptions.ArgumentException: Given TimeZone cannot be understood. Incorrect RawOffset:“12:00:00” or unknown ID:“Pacific/Auckland”

when loading a valid ics file, or even when using your example code to create an appointment.

e.g. this line causes the error
Appointment calDoc = Appointment.load(“c:\test.ics”);

This happens on both Windows 7 & 8.1 PCs.

Using the following lines;
System.out.println(java.util.Locale.getDefault().toString());
System.out.println(TimeZone.getDefault().getID());
System.out.println(TimeZone.getDefault().getRawOffset());

results in;
en_NZ
Pacific/Auckland
43200000

This post seems the same, but I can’t access it Free Support Forum - aspose.com

Can you please advise a fix/workaround? Thanks

Hi Peter,

Thank you for writing to us.

Could you please provide us with a sample file that we can use to reproduce this issue at our end? We’ll look into it and assist you further in this regard.

Thanks Kashif

Please try this one, it generates the error. JRE 1.6.0.

Best regards

Hi Peter,

Thank you for providing the sample file. I was able to reproduce the issue at my end using the latest version of Aspose.Email for Java 4.4.0 and have logged it as NETWRKJAVA-33399 in our bug tracking system. Our development team will further investigate the issue and we’ll update you here once there is some information available in this regard.

Thanks Kashif

Works OK if I change the PC timezone to Fiji, e.g.
en_NZ
Pacific/Fiji
43200000

makes me feel a bit warmer too…

Hi Peter,

Since the issue has already been logged for investigation by development team, we’ll update you here once there is some information available in this regard.

Hi Kashif

Can you please advise progress on this, thanks.

Update:
The same applies using Europe/Paris, e.g. Incorrect RawOffset:“01:00:00” or unknown ID:“Europe/Paris”, however Europe/Berlin, Europe/Prague, Europe/Belgrade etc are OK.

It is also related to the PC timezone, not the timezone specified in the ICS file. For example, if TimeZone.getDefault().getID() returns “Europe/Paris”, loading any ics file will fail, regardless of the timezones specified within it.

So maybe the question is why doesn’t Aspose Email for Java understand some valid timezone IDs?

Incidentally we have bought the product - I’m not sure if this makes a difference to support.

Regards

Hi Peter,


Could you please try it with the latest version of Aspose.Email for Java 4.7.0? The issue has been fixed in an earlier version and should work for you now. If the issue still persists with this latest version , please provide us with some sample files that we can use to investigate this issue further and report it to our development team. We are sorry for the inconvenience caused to you in this regard.

Hi Kashif

This is using Aspose.Email for Java v4.7.0.

Sample ICS file (test.ics);
BEGIN:VCALENDAR
VERSION:1.0
BEGIN:VTIMEZONE
TZID:America/New_York
LAST-MODIFIED:19870101T000000Z
BEGIN:STANDARD
DTSTART:19971026T020000
RDATE:19971026T020000
TZOFFSETFROM:-0400
TZOFFSETTO:-0500
TZNAME:EST
END:STANDARD
BEGIN:DAYLIGHT
DTSTART:19971026T020000
RDATE:19970406T020000
TZOFFSETFROM:-0500
TZOFFSETTO:-0400
TZNAME:EDT
END:DAYLIGHT
END:VTIMEZONE
BEGIN:VEVENT
DTSTART;TZID=America/New_York:20120328T073000
DTEND;TZID=America/New_York:20120328T093000
SUMMARY:Test Appt Summary
LOCATION:Test Appt Loc
DESCRIPTION:Test Appt Desc
PRIORITY:3
END:VEVENT
END:VCALENDAR

Sample code;
String defTZ = TimeZone.getDefault().getID();
System.out.println("Default TZ " + defTZ);
String useTZ = “Europe/Paris”;
System.out.println("Using TZ " + useTZ);
TimeZone.setDefault(TimeZone.getTimeZone(useTZ));

String testPathStr = “c:\temp\test.ics”;
Appointment calDoc = Appointment.load(testPathStr);
System.out.println("Description = " + calDoc.getDescription());

System.out.println("Reset TZ to " + defTZ);
TimeZone.setDefault(TimeZone.getTimeZone(defTZ));


This fails with the error above.

1. If I change the timezone to say Europe/Berlin, it loads OK.
2. If I remove the Timezone info from the ICS file, it loadS OK.


The affected Timezones seem to be;
Africa/Cairo
America/Anchorage
America/Argentina/Buenos_Aires
Europe/Paris
Pacific/Apia
Pacific/Auckland
Australia/Darwin
Australia/Sydney

Regards

Hi Peter,


We are working over this query and will soon share our feedback with you here. We apologize for the delay incurred in this regard.

Hi Peter,

Thank you for sharing your concern with us.

I was able to reproduce this issue at my end using the latest version of Aspose.Email for Java 4.7.0 and have logged it as NETWRKJAVA-33433 in our issue tracking system for further investigation by our development team. Once there is any information available in this regard, I'll update you here via this thread.

We are sorry for any inconvenience caused to you.

Hi Kashif

Is there a fix yet?

Thanks

Hi Peter,


Both your issues are already fixed. Please try it with the latest version of Aspose.Email for Java 5.5.0 and share your feedback with us.

The issues you have found earlier (filed as ) have been fixed in this update. This message was posted using BugNotificationTool from Downloads module by MuzammilKhan