Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 0 additions & 4 deletions apps/debugger/.babelrc

This file was deleted.

16 changes: 0 additions & 16 deletions apps/debugger/.browserslistrc

This file was deleted.

17 changes: 0 additions & 17 deletions apps/debugger/src/app/app.tsx

This file was deleted.

27 changes: 0 additions & 27 deletions apps/debugger/src/app/debugger.ts

This file was deleted.

Empty file removed apps/debugger/src/assets/.gitkeep
Empty file.
3 changes: 0 additions & 3 deletions apps/debugger/src/environments/environment.prod.ts

This file was deleted.

6 changes: 0 additions & 6 deletions apps/debugger/src/environments/environment.ts

This file was deleted.

Binary file removed apps/debugger/src/favicon.ico
Binary file not shown.
15 changes: 0 additions & 15 deletions apps/debugger/src/index.html

This file was deleted.

9 changes: 0 additions & 9 deletions apps/debugger/src/main.tsx

This file was deleted.

7 changes: 0 additions & 7 deletions apps/debugger/src/polyfills.ts

This file was deleted.

1 change: 0 additions & 1 deletion apps/debugger/src/styles.css

This file was deleted.

9 changes: 0 additions & 9 deletions apps/debugger/tsconfig.app.json

This file was deleted.

16 changes: 0 additions & 16 deletions apps/debugger/tsconfig.json

This file was deleted.

15 changes: 0 additions & 15 deletions apps/debugger/tsconfig.spec.json

This file was deleted.

17 changes: 0 additions & 17 deletions apps/debugger/webpack.config.js

This file was deleted.

2 changes: 1 addition & 1 deletion apps/remix-ide-e2e/src/commands/debugTransaction.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ function checkStyle (browser: NightwatchBrowser, index: number, callback: VoidFu

debugBtn && debugBtn.click()
}, [index], function () {
browser.waitForElementVisible('*[data-id="buttonNavigatorJumpPreviousBreakpoint"]').perform(() => callback())
callback()
})
}

Expand Down
1 change: 0 additions & 1 deletion apps/remix-ide-e2e/src/commands/goToVMTraceStep.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ function goToVMtraceStep (browser: NightwatchBrowser, step: number, incr: number
browser.execute(function () {
return document.querySelector('#stepdetail').innerHTML
}, [], function (result) {
console.log('goToVMtraceStep', result)
if (typeof result.value === 'string' && ( result.value.indexOf('vm trace step:') !== -1 && result.value.indexOf(step.toString()) !== -1)) {
done()
} else if (incr > 1000) {
Expand Down
3 changes: 1 addition & 2 deletions apps/remix-ide-e2e/src/tests/ballot.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -39,11 +39,10 @@ module.exports = {
'Debug Ballot / delegate': function (browser: NightwatchBrowser) {
browser.pause(500)
.click('*[data-id="txLoggerDebugButton0x41fab8ea5b1d9fba5e0a6545ca1a2d62fff518578802c033c2b9a031a01c31b3"]')
.waitForElementVisible('*[data-id="buttonNavigatorJumpPreviousBreakpoint"]')
.pause(2000)
// .clickLaunchIcon('debugger')
.click('*[data-id="buttonNavigatorJumpPreviousBreakpoint"]')
.pause(2000)
.waitForElementVisible('#stepdetail')
.goToVMTraceStep(79)
.pause(1000)
.checkVariableDebug('soliditystate', stateCheck)
Expand Down
2 changes: 0 additions & 2 deletions apps/remix-ide-e2e/src/tests/ballot_0_4_11.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -50,10 +50,8 @@ module.exports = {
browser.pause(500)
.click('*[data-id="txLoggerDebugButton0x41fab8ea5b1d9fba5e0a6545ca1a2d62fff518578802c033c2b9a031a01c31b3"]')
.pause(2000)
.waitForElementVisible('*[data-id="buttonNavigatorJumpPreviousBreakpoint"]')
.click('*[data-id="buttonNavigatorJumpPreviousBreakpoint"]')
.pause(2000)
.waitForElementVisible('#stepdetail')
.goToVMTraceStep(20)
.pause(1000)
.checkVariableDebug('callstackpanel', ["0x692a70D2e424a56D2C6C27aA97D1a86395877b3A"])
Expand Down
4 changes: 1 addition & 3 deletions apps/remix-ide-e2e/src/tests/debugger.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,6 @@ module.exports = {
.createContract('"tokenName", "symbol"')
.debugTransaction(2)
.pause(2000)
.waitForElementVisible('#stepdetail')
.goToVMTraceStep(10)
.getEditorValue((content) => {
browser.assert.ok(content.indexOf(`constructor (string memory name_, string memory symbol_) public {
Expand Down Expand Up @@ -118,8 +117,7 @@ module.exports = {
.clickInstance(2)
.clickFunction('test1 - transact (not payable)', {types: 'bytes userData', values: '0x000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000015b38da6a701c568545dcfcb03fcb875f56beddc4'})
.debugTransaction(4)
.pause(2000)
.waitForElementVisible('#stepdetail')
.pause(2000)
.goToVMTraceStep(261)
.pause(1000)
/*
Expand Down
7 changes: 5 additions & 2 deletions apps/remix-ide/src/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ const CompilersArtefacts = require('./app/compiler/compiler-artefacts')
const CompileTab = require('./app/tabs/compile-tab')
const SettingsTab = require('./app/tabs/settings-tab')
const AnalysisTab = require('./app/tabs/analysis-tab')
const { DebuggerTab } = require('./app/tabs/debugger-tab')
const DebuggerTab = require('./app/tabs/debugger-tab')
const TestTab = require('./app/tabs/test-tab')
const FilePanel = require('./app/panels/file-panel')
const Editor = require('./app/editor/editor')
Expand Down Expand Up @@ -370,7 +370,10 @@ Please make a backup of your contracts and start using http://remix.ethereum.org
registry.get('fileproviders/browser').api
)
const analysis = new AnalysisTab(registry)
const debug = new DebuggerTab()
const debug = new DebuggerTab(
blockchain,
registry.get('editor').api,
registry.get('offsettolinecolumnconverter').api)
const test = new TestTab(
registry.get('filemanager').api,
registry.get('offsettolinecolumnconverter').api,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,10 @@ export default class FetchAndCompile extends Plugin {
* Returns compilation data
*
* @param {string} contractAddress - Address of the contrac to resolve
* @param {string} deployedBytecode - deployedBytecode of the contract
* @param {string} targetPath - Folder where to save the compilation arfefacts
* @param {string} compilersartefacts - Object containing a mapping of compilation results (byContractAddress and __last)
* @return {CompilerAbstract} - compilation data targeting the given @arg contractAddress
*/
async resolve (contractAddress, codeAtAddress, targetPath) {
async resolve (contractAddress, targetPath, web3) {
contractAddress = ethutil.toChecksumAddress(contractAddress)
const compilersartefacts = globalRegistry.get('compilersartefacts').api

Expand All @@ -53,6 +52,7 @@ export default class FetchAndCompile extends Plugin {
if (!this.sourceVerifierNetWork.includes(network.name)) return localCompilation()

// check if the contract if part of the local compilation result
const codeAtAddress = await web3.eth.getCode(contractAddress)
const compilation = localCompilation()
if (compilation) {
let found = false
Expand Down
15 changes: 0 additions & 15 deletions apps/remix-ide/src/app/components/local-plugin.js
Original file line number Diff line number Diff line change
Expand Up @@ -67,20 +67,11 @@ module.exports = class LocalPlugin {
this.profile[key] = e.target.value
}

updateMethods ({ target }) {
if (target.value) {
try {
this.profile.methods = target.value.split(',')
} catch (e) {}
}
}

/** The form to create a local plugin */
form () {
const name = this.profile.name || ''
const url = this.profile.url || ''
const displayName = this.profile.displayName || ''
const methods = (this.profile.methods && this.profile.methods.join(',')) || ''
const radioSelection = (key, label, message) => {
return this.profile[key] === label
? yo`<div class="radio">
Expand All @@ -103,12 +94,6 @@ module.exports = class LocalPlugin {
<label for="plugin-displayname">Display Name</label>
<input class="form-control" onchange="${e => this.updateDisplayName(e)}" value="${displayName}" id="plugin-displayname" data-id="localPluginDisplayName" placeholder="Name in the header">
</div>

<div class="form-group">
<label for="plugin-methods">Api (comma separated list of methods name)</label>
<input class="form-control" onchange="${e => this.updateMethods(e)}" value="${methods}" id="plugin-methods" data-id="localPluginMethods" placeholder="Name in the header">
</div>

<div class="form-group">
<label for="plugin-url">Url <small>(required)</small></label>
<input class="form-control" onchange="${e => this.updateUrl(e)}" value="${url}" id="plugin-url" data-id="localPluginUrl" placeholder="ex: https://localhost:8000">
Expand Down
15 changes: 5 additions & 10 deletions apps/remix-ide/src/app/editor/editor.js
Original file line number Diff line number Diff line change
Expand Up @@ -174,34 +174,29 @@ class Editor extends Plugin {
const breakpoints = e.editor.session.getBreakpoints()
for (const k in breakpoints) {
if (k === row.toString()) {
this.triggerEvent('breakpointCleared', [this.currentSession, row])
this.event.trigger('breakpointCleared', [this.currentSession, row])
e.editor.session.clearBreakpoint(row)
e.stop()
return
}
}
this.setBreakpoint(row)
this.triggerEvent('breakpointAdded', [this.currentSession, row])
this.event.trigger('breakpointAdded', [this.currentSession, row])
e.stop()
})

// Do setup on initialisation here
this.editor.on('changeSession', () => {
this._onChange()
this.triggerEvent('sessionSwitched', [])
this.event.trigger('sessionSwitched', [])
this.editor.getSession().on('change', () => {
this._onChange()
this.sourceHighlighters.discardAllHighlights()
this.triggerEvent('contentChanged', [])
this.event.trigger('contentChanged', [])
})
})
}

triggerEvent (name, params) {
this.event.trigger(name, params) // internal stack
this.emit(name, ...params) // plugin stack
}

onActivation () {
this.on('sidePanel', 'focusChanged', (name) => this.sourceHighlighters.hideHighlightsExcept(name))
this.on('sidePanel', 'pluginDisabled', (name) => this.sourceHighlighters.discardHighlight(name))
Expand Down Expand Up @@ -252,7 +247,7 @@ class Editor extends Plugin {
window.clearTimeout(this.saveTimeout)
}
this.saveTimeout = window.setTimeout(() => {
this.triggerEvent('requiringToSaveCurrentfile', [])
this.event.trigger('requiringToSaveCurrentfile', [])
}, 5000)
}

Expand Down
Loading