remix lib linting done

fixAnalyzerTest
aniket-engg 4 years ago
parent c63d39985a
commit e08c349367
  1. 4
      libs/remix-analyzer/src/solidity-analyzer/index.ts
  2. 4
      libs/remix-analyzer/src/solidity-analyzer/modules/staticAnalysisCommon.ts
  3. 2
      libs/remix-analyzer/tsconfig.lib.json
  4. 16
      libs/remix-lib/.eslintrc
  5. 2
      libs/remix-lib/src/code/disassembler.js
  6. 1
      libs/remix-lib/src/execution/txRunner.js
  7. 1
      libs/remix-lib/src/universalDapp.js
  8. 9
      nx.json
  9. 21349
      package-lock.json
  10. 2
      package.json
  11. 28
      workspace.json

@ -1,7 +1,7 @@
'use strict'
import { AstWalker } from 'remix-astwalker'
import { AstWalker } from '@remix-project/remix-astwalker'
import list from './modules/list'
import { CompilationResult, AnalyzerModule, AnalysisReportObj, AnalysisReport } from 'types'
import { CompilationResult, AnalyzerModule, AnalysisReportObj, AnalysisReport } from '../types'
type ModuleObj = {
name: string

@ -3,8 +3,8 @@
import { FunctionDefinitionAstNode, ModifierDefinitionAstNode, ParameterListAstNode, ForStatementAstNode,
WhileStatementAstNode, VariableDeclarationAstNode, ContractDefinitionAstNode, InheritanceSpecifierAstNode,
MemberAccessAstNode, BinaryOperationAstNode, FunctionCallAstNode, ExpressionStatementAstNode, UnaryOperationAstNode,
IdentifierAstNode, IndexAccessAstNode, BlockAstNode, AssignmentAstNode, InlineAssemblyAstNode, IfStatementAstNode, CompiledContractObj, ABIParameter } from "types"
import { util } from 'remix-lib'
IdentifierAstNode, IndexAccessAstNode, BlockAstNode, AssignmentAstNode, InlineAssemblyAstNode, IfStatementAstNode, CompiledContractObj, ABIParameter } from "../../types"
import { util } from '@remix-project/remix-lib'
type SpecialObjDetail = {
obj: string

@ -4,7 +4,7 @@
"module": "commonjs",
"outDir": "../../dist/out-tsc",
"declaration": true,
"rootDir": "./src",
"rootDir": "./",
"types": ["node"]
},
"exclude": ["**/*.spec.ts"],

@ -0,0 +1,16 @@
{
"extends": "../../.eslintrc",
"rules": {
"@typescript-eslint/no-var-requires": "off",
"@typescript-eslint/no-empty-function": "off",
"@typescript-eslint/no-unused-vars": "off",
"@typescript-eslint/no-this-alias": "off"
},
"env": {
"browser": true,
"amd": true,
"node": true,
"es6": true
},
"ignorePatterns": ["!**/*"]
}

@ -11,7 +11,9 @@ const createExpressions = function (instructions) {
expr.functional = false
if (expr.name === 'JUMPDEST') {
expr.label = 'label' + (++labels)
// eslint-disable-next-line no-empty
} else if (expr.name.slice(0, 3) === 'DUP') {
// eslint-disable-next-line no-empty
} else if (expr.name.slice(0, 4) === 'SWAP') {
} else if (expr.out <= 1 && expr.in <= expressions.length) {
let error = false

@ -56,6 +56,7 @@ class TxRunner {
}
this.event.trigger('transactionBroadcasted', [resp])
var listenOnResponse = () => {
// eslint-disable-next-line no-async-promise-executor
return new Promise(async (resolve, reject) => {
const result = await tryTillReceiptAvailable(resp, this.executionContext)
tx = await tryTillTxAvailable(resp, this.executionContext)

@ -377,6 +377,7 @@ module.exports = class UniversalDApp {
if (error && (typeof (error) !== 'string')) {
if (error.message) error = error.message
else {
// eslint-disable-next-line no-empty
try { error = 'error: ' + JSON.stringify(error) } catch (e) {}
}
}

@ -19,12 +19,15 @@
}
},
"projects": {
"remix-astwalker": {
"tags": []
},
"remix-lib": {
"tags": []
},
"remix-astwalker": {
"tags": [],
"implicitDependencies": [
"remix-lib"
]
},
"remix-analyzer": {
"tags": [],
"implicitDependencies": [

21349
package-lock.json generated

File diff suppressed because it is too large Load Diff

@ -145,8 +145,10 @@
"@fortawesome/fontawesome-free": "^5.8.1",
"@nrwl/eslint-plugin-nx": "^9.4.4",
"@nrwl/linter": "^9.3.0",
"@nrwl/node": "^9.4.5",
"@nrwl/workspace": "9.2.4",
"@remix-project/remix-analyzer": "0.5.2",
"@remix-project/remix-astwalker": "0.5.2",
"@remix-project/remix-debug": "0.4.4",
"@remix-project/remix-lib": "0.4.29",
"@remix-project/remix-simulator": "0.1.9-beta.5",

@ -99,17 +99,13 @@
}
},
"build": {
"builder": "@nrwl/workspace:run-commands",
"builder": "@nrwl/node:package",
"options": {
"commands": [
{
"command": "rm -rf ../../dist"
},
{
"command": "./../../node_modules/.bin/npm-run-all build"
}
],
"cwd": "libs/remix-analyzer"
"outputPath": "dist/libs/remix-analyzer",
"tsConfig": "libs/remix-analyzer/tsconfig.lib.json",
"packageJson": "libs/remix-analyzer/package.json",
"main": "libs/remix-analyzer/src/index.ts",
"assets": ["libs/remix-analyzer/*.md"]
}
}
}
@ -201,14 +197,14 @@
"schematics": {},
"architect": {
"lint": {
"builder": "@nrwl/workspace:run-commands",
"builder": "@nrwl/linter:lint",
"options": {
"commands": [
{
"command": "./../../node_modules/.bin/npm-run-all lint"
}
"linter": "eslint",
"config": "libs/remix-lib/.eslintrc",
"files": [
"libs/remix-lib/**/*.js"
],
"cwd": "libs/remix-lib"
"exclude": ["**/node_modules/**", "libs/remix-lib/test/**/*"]
}
},
"test": {

Loading…
Cancel
Save