Skip to content

Uncaught ReferenceError: Price is not defined (pricing.js) #7

Description

@quantverse

Hello,

the library crashes when attempting to stream prices:

Uncaught ReferenceError: Price is not defined
      at /home/xxx/yyy/zzz/node_modules/@oanda/v20/pricing.js:658:44
      at chunks.forEach.chunk (node_modules/@oanda/v20/context.js:137:33)
      at Array.forEach (<anonymous>)
      at IncomingMessage.response.on.d (node_modules/@oanda/v20/context.js:134:32)
      at addChunk (_stream_readable.js:263:12)
      at readableAddChunk (_stream_readable.js:250:11)
      at IncomingMessage.Readable.push (_stream_readable.js:208:10)
      at HTTPParser.parserOnBody (_http_common.js:139:22)
      at TLSSocket.socketOnData (_http_client.js:440:20)
      at addChunk (_stream_readable.js:263:12)
      at readableAddChunk (_stream_readable.js:250:11)
      at TLSSocket.Readable.push (_stream_readable.js:208:10)
      at TLSWrap.onread (net.js:607:20)

it is apparently missing Price object import, for instance by adding a line:

var Price = require('./pricing_common').Price;

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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