Skip to content

Error when loading with irb: "uninitialized constant Coinbase (NameError)" #234

@Makazone

Description

@Makazone

Description

It appears that the top-level module Coinbase is not defined before the first require_relative 'coinbase/client'. The code in api_client.rb defines module Coinbase::Client. This causes Ruby to fail when trying to access Coinbase::Client because Ruby doesn’t recognize the Coinbase module yet.

To reproduce (using ruby 2.7.5 and 3+):

  1. Launch IRB.
  2. Run require 'coinbase'
  3. Observe the "uninitialized constant Coinbase (NameError)" error.

Will submit a PR with a suggested fix!

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