Skip to content

I am running truffle migrate --reset #3650

@MustaqAhamed

Description

@MustaqAhamed

Prerequisites

  • Write a descriptive title.
  • Make sure you are able to repro it on the latest released version
  • Search the existing issues, especially the pinned issues.

Exception report

System.ArgumentOutOfRangeException: The value must be greater than or equal to zero and less than the console's buffer size in that dimension.
Parameter name: top
Actual value was -1.
   at System.Console.SetCursorPosition(Int32 left, Int32 top)
   at Microsoft.PowerShell.PSConsoleReadLine.ForceRender()
   at Microsoft.PowerShell.PSConsoleReadLine.Paste(Nullable`1 key, Object arg)
   at Microsoft.PowerShell.PSConsoleReadLine.ProcessOneKey(ConsoleKeyInfo key, Dictionary`2 dispatchTable, Boolean ignoreIfNoAction, Object arg)
   at Microsoft.PowerShell.PSConsoleReadLine.InputLoop()
   at Microsoft.PowerShell.PSConsoleReadLine.ReadLine(Runspace runspace, EngineIntrinsics engineIntrinsics)
-----------------------------------------------------------------------
PS C:\Users\HP\Downloads\Dream-Killers-Fake-Product-Detection-using-Blockchain-application-main> truffle migrate --reset 
C:\Users\HP\Downloads\Dream-Killers-Fake-Product-Detection-using-Blockchain-application-main\truffle-config.js:8
export const contracts_directory = './contracts/';
^^^^^^

SyntaxError: Unexpected token 'export'
    at Object.compileFunction (node:vm:352:18)
    at wrapSafe (node:internal/modules/cjs/loader:1031:15)
    at Module._compile (node:internal/modules/cjs/loader:1065:27)
    at Object.Module._extensions..js (node:internal/modules/cjs/loader:1153:10)
    at Module.load (node:internal/modules/cjs/loader:981:32)
    at Function.Module._load (node:internal/modules/cjs/loader:822:12)
    at Module.require (node:internal/modules/cjs/loader:1005:19)
    at require (node:internal/modules/cjs/helpers:102:18)
    at Function.load (C:\Users\HP\AppData\Roaming\npm\node_modules\truffle\build\webpack:\packages\config\dist\index.js:152:1)
    at Function.detect (C:\Users\HP\AppData\Roaming\npm\node_modules\truffle\build\webpack:\packages\config\dist\index.js:144:1)
    at Object.module.exports [as run] (C:\Users\HP\AppData\Roaming\npm\node_modules\truffle\build\webpack:\packages\core\lib\commands\migrate\run.js:12:1)
    at runCommand (C:\Users\HP\AppData\Roaming\npm\node_modules\truffle\build\webpack:\packages\core\lib\command-utils.js:297:1)
Truffle v5.8.1 (core: 5.8.1)
Node v16.13.0

Screenshot

How do I fix it for running my project?
image

Environment data

Oops, something went wrong.  Please report this bug with the details below.
Report on GitHub: https://github.com/lzybkr/PSReadLine/issues/new
-----------------------------------------------------------------------
Last 1 Keys:
 Ctrl+v

Exception:
System.ArgumentOutOfRangeException: The value must be greater than or equal to zero and less than the console's buffer size in that dimension.
Parameter name: top
Actual value was -1.
   at System.Console.SetCursorPosition(Int32 left, Int32 top)
   at Microsoft.PowerShell.PSConsoleReadLine.ForceRender()
   at Microsoft.PowerShell.PSConsoleReadLine.Paste(Nullable`1 key, Object arg)
   at Microsoft.PowerShell.PSConsoleReadLine.ProcessOneKey(ConsoleKeyInfo key, Dictionary`2 dispatchTable, Boolean ignoreIfNoAction, Object arg)
   at Microsoft.PowerShell.PSConsoleReadLine.InputLoop()
   at Microsoft.PowerShell.PSConsoleReadLine.ReadLine(Runspace runspace, EngineIntrinsics engineIntrinsics)
-----------------------------------------------------------------------
PS C:\Users\HP\Downloads\Dream-Killers-Fake-Product-Detection-using-Blockchain-application-main> truffle migrate --reset 
C:\Users\HP\Downloads\Dream-Killers-Fake-Product-Detection-using-Blockchain-application-main\truffle-config.js:8
export const contracts_directory = './contracts/';
^^^^^^

SyntaxError: Unexpected token 'export'
    at Object.compileFunction (node:vm:352:18)
    at wrapSafe (node:internal/modules/cjs/loader:1031:15)
    at Module._compile (node:internal/modules/cjs/loader:1065:27)
    at Object.Module._extensions..js (node:internal/modules/cjs/loader:1153:10)
    at Module.load (node:internal/modules/cjs/loader:981:32)
    at Function.Module._load (node:internal/modules/cjs/loader:822:12)
    at Module.require (node:internal/modules/cjs/loader:1005:19)
    at require (node:internal/modules/cjs/helpers:102:18)
    at Function.load (C:\Users\HP\AppData\Roaming\npm\node_modules\truffle\build\webpack:\packages\config\dist\index.js:152:1)
    at Function.detect (C:\Users\HP\AppData\Roaming\npm\node_modules\truffle\build\webpack:\packages\config\dist\index.js:144:1)
    at Object.module.exports [as run] (C:\Users\HP\AppData\Roaming\npm\node_modules\truffle\build\webpack:\packages\core\lib\commands\migrate\run.js:12:1)
    at runCommand (C:\Users\HP\AppData\Roaming\npm\node_modules\truffle\build\webpack:\packages\core\lib\command-utils.js:297:1)
Truffle v5.8.1 (core: 5.8.1)
Node v16.13.0

Steps to reproduce

run truffle migrate --reset

Expected behavior

Oops, something went wrong. Please report this bug with the details below.
Report on GitHub: https://github.com/lzybkr/PSReadLine/issues/new

Last 1 Keys:
Ctrl+v

Exception:
System.ArgumentOutOfRangeException: The value must be greater than or equal to zero and less than the console's buffer size in that dimension.
Parameter name: top
Actual value was -1.
at System.Console.SetCursorPosition(Int32 left, Int32 top)
at Microsoft.PowerShell.PSConsoleReadLine.ForceRender()
at Microsoft.PowerShell.PSConsoleReadLine.Paste(Nullable1 key, Object arg) at Microsoft.PowerShell.PSConsoleReadLine.ProcessOneKey(ConsoleKeyInfo key, Dictionary2 dispatchTable, Boolean ignoreIfNoAction, Object arg)
at Microsoft.PowerShell.PSConsoleReadLine.InputLoop()
at Microsoft.PowerShell.PSConsoleReadLine.ReadLine(Runspace runspace, EngineIntrinsics engineIntrinsics)

PS C:\Users\HP\Downloads\Dream-Killers-Fake-Product-Detection-using-Blockchain-application-main> truffle migrate --reset
C:\Users\HP\Downloads\Dream-Killers-Fake-Product-Detection-using-Blockchain-application-main\truffle-config.js:8
export const contracts_directory = './contracts/';
^^^^^^

SyntaxError: Unexpected token 'export'
at Object.compileFunction (node:vm:352:18)
at wrapSafe (node:internal/modules/cjs/loader:1031:15)
at Module._compile (node:internal/modules/cjs/loader:1065:27)
at Object.Module._extensions..js (node:internal/modules/cjs/loader:1153:10)
at Module.load (node:internal/modules/cjs/loader:981:32)
at Function.Module._load (node:internal/modules/cjs/loader:822:12)
at Module.require (node:internal/modules/cjs/loader:1005:19)
at require (node:internal/modules/cjs/helpers:102:18)
at Function.load (C:\Users\HP\AppData\Roaming\npm\node_modules\truffle\build\webpack:\packages\config\dist\index.js:152:1)
at Function.detect (C:\Users\HP\AppData\Roaming\npm\node_modules\truffle\build\webpack:\packages\config\dist\index.js:144:1)
at Object.module.exports [as run] (C:\Users\HP\AppData\Roaming\npm\node_modules\truffle\build\webpack:\packages\core\lib\commands\migrate\run.js:12:1)
at runCommand (C:\Users\HP\AppData\Roaming\npm\node_modules\truffle\build\webpack:\packages\core\lib\command-utils.js:297:1)
Truffle v5.8.1 (core: 5.8.1)
Node v16.13.0

Actual behavior

Oops, something went wrong. Please report this bug with the details below.
Report on GitHub: https://github.com/lzybkr/PSReadLine/issues/new

Last 1 Keys:
Ctrl+v

Exception:
System.ArgumentOutOfRangeException: The value must be greater than or equal to zero and less than the console's buffer size in that dimension.
Parameter name: top
Actual value was -1.
at System.Console.SetCursorPosition(Int32 left, Int32 top)
at Microsoft.PowerShell.PSConsoleReadLine.ForceRender()
at Microsoft.PowerShell.PSConsoleReadLine.Paste(Nullable1 key, Object arg) at Microsoft.PowerShell.PSConsoleReadLine.ProcessOneKey(ConsoleKeyInfo key, Dictionary2 dispatchTable, Boolean ignoreIfNoAction, Object arg)
at Microsoft.PowerShell.PSConsoleReadLine.InputLoop()
at Microsoft.PowerShell.PSConsoleReadLine.ReadLine(Runspace runspace, EngineIntrinsics engineIntrinsics)

PS C:\Users\HP\Downloads\Dream-Killers-Fake-Product-Detection-using-Blockchain-application-main> truffle migrate --reset
C:\Users\HP\Downloads\Dream-Killers-Fake-Product-Detection-using-Blockchain-application-main\truffle-config.js:8
export const contracts_directory = './contracts/';
^^^^^^

SyntaxError: Unexpected token 'export'
at Object.compileFunction (node:vm:352:18)
at wrapSafe (node:internal/modules/cjs/loader:1031:15)
at Module._compile (node:internal/modules/cjs/loader:1065:27)
at Object.Module._extensions..js (node:internal/modules/cjs/loader:1153:10)
at Module.load (node:internal/modules/cjs/loader:981:32)
at Function.Module._load (node:internal/modules/cjs/loader:822:12)
at Module.require (node:internal/modules/cjs/loader:1005:19)
at require (node:internal/modules/cjs/helpers:102:18)
at Function.load (C:\Users\HP\AppData\Roaming\npm\node_modules\truffle\build\webpack:\packages\config\dist\index.js:152:1)
at Function.detect (C:\Users\HP\AppData\Roaming\npm\node_modules\truffle\build\webpack:\packages\config\dist\index.js:144:1)
at Object.module.exports [as run] (C:\Users\HP\AppData\Roaming\npm\node_modules\truffle\build\webpack:\packages\core\lib\commands\migrate\run.js:12:1)
at runCommand (C:\Users\HP\AppData\Roaming\npm\node_modules\truffle\build\webpack:\packages\core\lib\command-utils.js:297:1)
Truffle v5.8.1 (core: 5.8.1)
Node v16.13.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions