You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@fesod.apache.org by "nkuprins (via GitHub)" <gi...@apache.org> on 2026/08/27 16:26:40 UTC
[I] [Bug] Sheet-level locale(), useScientificFormat() and filedCacheLocation() are silently ignored when reading [fesod]
nkuprins opened a new issue, #1051:
URL: https://github.com/apache/fesod/issues/1051
### Search before asking
- [x] I searched in the [issues](https://github.com/apache/fesod/issues) and found nothing similar.
### Fesod version
main (89bcccff)
### JDK version
25
### Operating system
Linux
### Steps To Reproduce
Write one number with a format, then read it back as text twice, moving `.locale(...)` from before `.sheet(0)` to after it.
```java
@Data
public static class Invoice {
@DateTimeFormat("d MMMM yyyy")
private LocalDateTime issued;
@NumberFormat("#,##0.00")
private Double amount;
}
@Data
public static class InvoiceText {
private String issued;
private String amount;
}
Invoice invoice = new Invoice();
invoice.setIssued(LocalDateTime.of(2026, 1, 4, 0, 0));
invoice.setAmount(1234.5D);
FesodSheet.write(file, Invoice.class).sheet().doWrite(Collections.singletonList(invoice));
FesodSheet.read(file).head(InvoiceText.class).locale(Locale.GERMANY).sheet(0).doReadSync();
FesodSheet.read(file).head(InvoiceText.class).sheet(0).locale(Locale.GERMANY).doReadSync();
```
### Current Behavior
```
jvm default locale : en_US
locale() before sheet(0) : 4 Januar 2026 | 1.234,50
locale() after sheet(0) : 4 January 2026 | 1,234.50
```
Set on the sheet builder, `locale` is dropped without any warning
### Expected Behavior
```
locale() after sheet(0) : 4 Januar 2026 | 1.234,50
```
A sheet-level setting should win over the workbook-level one, as `autoTrim`, `autoStrip`, `use1904windowing` and `headRowNumber` already do.
### Anything else?
The cause is `ReadSheet.copyBasicParameter`, which misses 3 sets for these params.
### Are you willing to submit a PR?
- [x] I'm willing to submit a PR!
--
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: commits-unsubscribe@fesod.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@fesod.apache.org
For additional commands, e-mail: commits-help@fesod.apache.org
Re: [I] [Bug] Sheet-level locale(), useScientificFormat() and filedCacheLocation() are silently ignored when reading [fesod]
Posted by "delei (via GitHub)" <gi...@apache.org>.
delei closed issue #1051: [Bug] Sheet-level locale(), useScientificFormat() and filedCacheLocation() are silently ignored when reading
URL: https://github.com/apache/fesod/issues/1051
--
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: commits-unsubscribe@fesod.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@fesod.apache.org
For additional commands, e-mail: commits-help@fesod.apache.org