Skip to content

feat: support multiple version solc and dev doc#846

Merged
kyonRay merged 1 commit intoFISCO-BCOS:devfrom
HelloAldis:dev
May 7, 2024
Merged

feat: support multiple version solc and dev doc#846
kyonRay merged 1 commit intoFISCO-BCOS:devfrom
HelloAldis:dev

Conversation

@HelloAldis
Copy link
Contributor

  1. support multiple version solc in console contract2java、deploy contract
  2. support solidity devdoc for contract2java

1. support multiple version solc in console contract2java、deploy contract
2. support solidity devdoc for contract2java
@sonarqubecloud
Copy link

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
No data about Duplication

See analysis details on SonarCloud

String smBinFilePath = smBinFile.getAbsolutePath();
FileUtils.writeStringToFile(
new File(abiDir + "/sm/" + contractName + ".abi"), abiAndBin.getAbi());
FileUtils.writeStringToFile(smAbiFile, abiAndBin.getAbi());

Check notice

Code scanning / CodeQL

Deprecated method or constructor invocation

Invoking [FileUtils.writeStringToFile](1) should be avoided because it has been deprecated.

File devdocFile = new File(docDir + contractName + ".devdoc");
if (!StringUtils.isEmpty(abiAndBin.getDevdoc())) {
FileUtils.writeStringToFile(devdocFile, abiAndBin.getDevdoc());

Check notice

Code scanning / CodeQL

Deprecated method or constructor invocation

Invoking [FileUtils.writeStringToFile](1) should be avoided because it has been deprecated.
logger.info(
"deploy contract {} with '--parallel-analysis' or '-p'", contractName);
inputParams.remove(lastIndexOf);
logger.info("deploy contract {} with '-p'", contractName);

Check failure

Code scanning / CodeQL

Insertion of sensitive information into log files

This [potentially sensitive information](1) is written to a log file.
if (lastIndexOf != -1) {
isContractParallelAnalysis = true;
inputParams.remove(lastIndexOf);
logger.info("deploy contract {} with '--parallel-analysis'", contractName);

Check failure

Code scanning / CodeQL

Insertion of sensitive information into log files

This [potentially sensitive information](1) is written to a log file.
version = ConsoleUtils.convertStringToVersion(inputParams.get(lastIndexOf + 1));
inputParams.remove(lastIndexOf);
inputParams.remove(lastIndexOf);
logger.info("deploy contract {} with '-v'", contractName);

Check failure

Code scanning / CodeQL

Insertion of sensitive information into log files

This [potentially sensitive information](1) is written to a log file.
version = ConsoleUtils.convertStringToVersion(inputParams.get(lastIndexOf + 1));
inputParams.remove(lastIndexOf);
inputParams.remove(lastIndexOf);
logger.info("deploy contract {} with '--sol-version'", contractName);

Check failure

Code scanning / CodeQL

Insertion of sensitive information into log files

This [potentially sensitive information](1) is written to a log file.
logger.debug(
"compileSolToBinAndAbi, solc version:{} ,basePath: {}",
Version.V0_8_11,
solFile.getParentFile().getCanonicalPath());

Check failure

Code scanning / CodeQL

Insertion of sensitive information into log files

This [potentially sensitive information](1) is written to a log file.
@kyonRay kyonRay merged commit d4ebca8 into FISCO-BCOS:dev May 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants