You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jan 12, 2021. It is now read-only.
Running Findbugs on EWD revealed the following instances of issue DMI_HARDCODED_ABSOLUTE_FILENAME
[INFO] Hard coded reference to an absolute pathname in org.finra.jtaf.ewd.impl.DefaultSessionFactory.getFFBinary(String) [org.finra.jtaf.ewd.impl.DefaultSessionFactory] At DefaultSessionFactory.java:[line 573] DMI_HARDCODED_ABSOLUTE_FILENAME
[INFO] Hard coded reference to an absolute pathname in org.finra.jtaf.ewd.impl.DefaultSessionFactory.getFFBinary(String) [org.finra.jtaf.ewd.impl.DefaultSessionFactory] At DefaultSessionFactory.java:[line 572] DMI_HARDCODED_ABSOLUTE_FILENAME
The text was updated successfully, but these errors were encountered:
This is an array that contains the possible locations of the firefox.exe file in a method that's supposed to return the Firefox binary. I do not see an easy solution here.
File[] possibleLocations = { new File(filePath != null ? filePath : ""), new File("C:\\Program Files\\Mozilla Firefox\\firefox.exe"), new File("C:\\Program Files (x86)\\Mozilla Firefox\\firefox.exe"), };
I think that in this case it probably makes sense to filter/suppress the error. The error was probably created to prevent the case where someone just hard-codes a single path and it will explode if it's not there. In our case these hard-coded paths are in a list of default possible locations, and it's expected that the user will specify their own path if the defaults are inadequate.
Also, the suggested workarounds after googling around (such as storing them in properties files) might even be worse.
If we choose to go with a filter I think there is an annotation we can use for findbugs or we can make an exclusion file which we reference in the POM. If we do the latter it will be part of #137 .
Running Findbugs on EWD revealed the following instances of issue DMI_HARDCODED_ABSOLUTE_FILENAME
[INFO] Hard coded reference to an absolute pathname in org.finra.jtaf.ewd.impl.DefaultSessionFactory.getFFBinary(String) [org.finra.jtaf.ewd.impl.DefaultSessionFactory] At DefaultSessionFactory.java:[line 573] DMI_HARDCODED_ABSOLUTE_FILENAME
[INFO] Hard coded reference to an absolute pathname in org.finra.jtaf.ewd.impl.DefaultSessionFactory.getFFBinary(String) [org.finra.jtaf.ewd.impl.DefaultSessionFactory] At DefaultSessionFactory.java:[line 572] DMI_HARDCODED_ABSOLUTE_FILENAME
The text was updated successfully, but these errors were encountered: