Anonymous | Login
Project:
RSS
  
News | My View | View Issues | Roadmap | Summary

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0046306
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Retail Modules] Web POS Hardware Managermajoralways2021-04-20 12:112021-05-10 07:45
Reporterjoniturralde93View Statuspublic 
Assigned Toranjith_qualiantech_com 
PriorityurgentResolutionfixedFixed in VersionRR21Q3
StatusclosedFix in branchFixed in SCM revision
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Review Assigned To
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0046306: Number format exception in RFIDencoding

DescriptionIn this line:
https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.poshwmanager.sources/-/blob/master/project/src/com/openbravo/pos/util/RFIDEncoding.java#L58 [^]

.leftPad(String.valueOf(Integer.parseInt(binaryCompanyPrefix, 2)), 13 - partition, '0');


There are cases where binaryCompanyPrefix is too large for the int type and it is necessary to use Long.

Long.parseLong instead of Integer.parseInt

Edit:
- It seems BigInteger could be needed in some circumstances.
- It would be nice to have a log added where we get printed the scanned tag in case some of these conversions fail.
Steps To ReproduceJust use screen mode with RFID and enter this tag:
E2806890000050031ED6C16D

Or debug that part of the code and manually modify the value of binaryCompanyPrefix
Proposed SolutionLong.parseLong instead of Integer.parseInt

Edit:
- It seems BigInteger could be needed in some circumstances.
- It would be nice to have a log added where we get printed the scanned tag in case some of these conversions fail.
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]

-  Notes
(0127528)
hgbot (developer)
2021-04-26 07:56

Merge Request created: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.poshwmanager/-/merge_requests/15 [^]
(0127529)
hgbot (developer)
2021-04-26 07:57

Merge Request created: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.poshwmanager.sources/-/merge_requests/22 [^]
(0127920)
hgbot (developer)
2021-05-10 07:45

Repository: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.poshwmanager.sources [^]
Changeset: c6a02d0dd9580134fbcd740cf5807628cffe6e15
Author: Ranjith S R <ranjith@qualiantech.com>
Date: 2021-04-29T13:09:50+05:30
URL: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.poshwmanager.sources/-/commit/c6a02d0dd9580134fbcd740cf5807628cffe6e15 [^]

Related to ISSUE-46306: Replaced Integer with Long when parsing EPC

---
M project/src/com/openbravo/pos/util/RFIDEncoding.java
---
(0127921)
hgbot (developer)
2021-05-10 07:45

Merge request merged: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.poshwmanager.sources/-/merge_requests/22 [^]
(0127922)
hgbot (developer)
2021-05-10 07:45

Directly closing issue as related merge request is already approved.

Repository: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.poshwmanager [^]
Changeset: 03f05a75434254bcc7893a1824044f4fa4259e06
Author: Ranjith S R <ranjith@qualiantech.com>
Date: 2021-04-28T11:05:19+05:30
URL: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.poshwmanager/-/commit/03f05a75434254bcc7893a1824044f4fa4259e06 [^]

Fixed ISSUE-46306: Replaced Integer with Long when parsing EPC

---
M bin/poshw.jar
M bin/rev.id
---
(0127923)
hgbot (developer)
2021-05-10 07:45

Merge request merged: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.poshwmanager/-/merge_requests/15 [^]

- Issue History
Date Modified Username Field Change
2021-04-20 12:11 joniturralde93 New Issue
2021-04-20 12:11 joniturralde93 Assigned To => Retail
2021-04-20 12:11 joniturralde93 Resolution time => 1620684000
2021-04-20 12:11 joniturralde93 Triggers an Emergency Pack => No
2021-04-21 09:38 joniturralde93 Description Updated View Revisions
2021-04-21 09:38 joniturralde93 Steps to Reproduce Updated View Revisions
2021-04-21 09:38 joniturralde93 Proposed Solution updated
2021-04-21 15:20 ranjith_qualiantech_com Assigned To Retail => ranjith_qualiantech_com
2021-04-26 07:56 hgbot Note Added: 0127528
2021-04-26 07:57 hgbot Note Added: 0127529
2021-05-05 14:39 ranjith_qualiantech_com Status new => scheduled
2021-05-10 07:45 hgbot Note Added: 0127920
2021-05-10 07:45 hgbot Note Added: 0127921
2021-05-10 07:45 hgbot Resolution open => fixed
2021-05-10 07:45 hgbot Status scheduled => closed
2021-05-10 07:45 hgbot Fixed in Version => RR21Q3
2021-05-10 07:45 hgbot Note Added: 0127922
2021-05-10 07:45 hgbot Note Added: 0127923


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker