NullPointerException in getFormulaLocal() with custom GlobalizationSettings

After updating to aspose-cells-21.4 (java) we are facing an Issue with getFormulaLocal() when using a custom GlobalizationSettings-Object.
An internal call to getListSeparator() throws an NPE:

java.lang.NullPointerException
	at com.aspose.cells.GlobalizationSettings.getListSeparator(Unknown Source)
	at com.aspose.cells.zafc.<init>(Unknown Source)
	at com.aspose.cells.zadt.<init>(Unknown Source)
	at com.aspose.cells.zadt.<init>(Unknown Source)
	at com.aspose.cells.zadt.<init>(Unknown Source)
	at com.aspose.cells.Cell.getFormulaLocal(Unknown Source)

So far this happens only with Version 21.4. Other Versions tested (21.2., 21.3, 20.7) don’t show this behavior.

Here is a minimal testcase for reproducing the error:

	public static void main(String[] args) throws Exception
	{
		Workbook wb = new Workbook();
		
		//Happens only when setting a custom settings object
		wb.getSettings().setGlobalizationSettings(new GlobalizationSettings() {});
		
		Worksheet sheet = wb.getWorksheets().get(0);
		Cell cell = sheet.getCells().get("A1");
		cell.setFormula("=1=1");
	
		//This call throws an NPE
		System.out.println(cell.getFormulaLocal());
	}

Any hints?

@oklein,

After an initial test, I am able to reproduce the issue as you mentioned using your code segment. I found an Issue with Cell.getFormulaLocal() method when using a custom GlobalizationSettings-Object.
An internal call to getListSeparator() throws an NPE. I have logged a ticket with an id “CELLSJAVA-43459”.for your issue. We will look into it soon.

Once we have an update on it, we will let you know.

@oklein,

We are pleased to inform you that your issue is fixed now. We will soon provide you the fixed version after passing QA and including other enhancements and fixes.

@oklein

Please try our latest fix:
aspose-cells-21.4.6-java.zip (7.3 MB)

We tried the fix, which seems to solve the problem. I consider the case as closed.
Big tanks to the team for the fast response and providing the fix so quickly, your support is exemplary!

Kind regards,
Oliver

@oklein,

You are always welcome.

Should you have further queries or issue, feel free to write us back.

The issues you have found earlier (filed as CELLSJAVA-43459) have been fixed in this update.