Uploaded image for project: 'Thrift'
  1. Thrift
  2. THRIFT-3384

generated code produces warning: already initialized constant

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Minor
    • Resolution: Unresolved
    • 0.10.0, 0.11.0
    • None
    • Ruby - Compiler
    • None
    • openSUSE
      ruby 2.1.3p242 (2014-09-19 revision 47630) [i586-linux-gnu]

    Description

      This is an excerpt from make check

         should read string with unicode characters
          should read binary
          should read long binary
        Thrift::JsonProtocolFactory
          should create a JsonProtocol
      
      namespaced generation
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/other_namespace/referenced_types.rb:11: warning: already initialized constant OtherNamespace::SomeEnum::ONE
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/flat/referenced_types.rb:11: warning: previous definition of ONE was here
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/other_namespace/referenced_types.rb:12: warning: already initialized constant OtherNamespace::SomeEnum::TWO
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/flat/referenced_types.rb:12: warning: previous definition of TWO was here
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/other_namespace/referenced_types.rb:13: warning: already initialized constant OtherNamespace::SomeEnum::VALUE_MAP
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/flat/referenced_types.rb:13: warning: previous definition of VALUE_MAP was here
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/other_namespace/referenced_types.rb:14: warning: already initialized constant OtherNamespace::SomeEnum::VALID_VALUES
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/flat/referenced_types.rb:14: warning: previous definition of VALID_VALUES was here
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/namespaced_spec_namespace/thrift_namespaced_spec_types.rb:14: warning: already initialized constant NamespacedSpecNamespace::Hello::GREETING
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/flat/thrift_namespaced_spec_types.rb:14: warning: previous definition of GREETING was here
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/namespaced_spec_namespace/thrift_namespaced_spec_types.rb:16: warning: already initialized constant NamespacedSpecNamespace::Hello::FIELDS
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/flat/thrift_namespaced_spec_types.rb:16: warning: previous definition of FIELDS was here
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/namespaced_spec_namespace/namespaced_nonblocking_service.rb:117: warning: already initialized constant NamespacedSpecNamespace::NamespacedNonblockingService::Greeting_args::ENGLISH
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/flat/namespaced_nonblocking_service.rb:117: warning: previous definition of ENGLISH was here
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/namespaced_spec_namespace/namespaced_nonblocking_service.rb:119: warning: already initialized constant NamespacedSpecNamespace::NamespacedNonblockingService::Greeting_args::FIELDS
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/flat/namespaced_nonblocking_service.rb:119: warning: previous definition of FIELDS was here
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/namespaced_spec_namespace/namespaced_nonblocking_service.rb:133: warning: already initialized constant NamespacedSpecNamespace::NamespacedNonblockingService::Greeting_result::SUCCESS
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/flat/namespaced_nonblocking_service.rb:133: warning: previous definition of SUCCESS was here
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/namespaced_spec_namespace/namespaced_nonblocking_service.rb:135: warning: already initialized constant NamespacedSpecNamespace::NamespacedNonblockingService::Greeting_result::FIELDS
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/flat/namespaced_nonblocking_service.rb:135: warning: previous definition of FIELDS was here
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/namespaced_spec_namespace/namespaced_nonblocking_service.rb:150: warning: already initialized constant NamespacedSpecNamespace::NamespacedNonblockingService::Block_args::FIELDS
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/flat/namespaced_nonblocking_service.rb:150: warning: previous definition of FIELDS was here
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/namespaced_spec_namespace/namespaced_nonblocking_service.rb:164: warning: already initialized constant NamespacedSpecNamespace::NamespacedNonblockingService::Block_result::SUCCESS
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/flat/namespaced_nonblocking_service.rb:164: warning: previous definition of SUCCESS was here
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/namespaced_spec_namespace/namespaced_nonblocking_service.rb:166: warning: already initialized constant NamespacedSpecNamespace::NamespacedNonblockingService::Block_result::FIELDS
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/flat/namespaced_nonblocking_service.rb:166: warning: previous definition of FIELDS was here
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/namespaced_spec_namespace/namespaced_nonblocking_service.rb:180: warning: already initialized constant NamespacedSpecNamespace::NamespacedNonblockingService::Unblock_args::N
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/flat/namespaced_nonblocking_service.rb:180: warning: previous definition of N was here
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/namespaced_spec_namespace/namespaced_nonblocking_service.rb:182: warning: already initialized constant NamespacedSpecNamespace::NamespacedNonblockingService::Unblock_args::FIELDS
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/flat/namespaced_nonblocking_service.rb:182: warning: previous definition of FIELDS was here
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/namespaced_spec_namespace/namespaced_nonblocking_service.rb:197: warning: already initialized constant NamespacedSpecNamespace::NamespacedNonblockingService::Unblock_result::FIELDS
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/flat/namespaced_nonblocking_service.rb:197: warning: previous definition of FIELDS was here
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/namespaced_spec_namespace/namespaced_nonblocking_service.rb:212: warning: already initialized constant NamespacedSpecNamespace::NamespacedNonblockingService::Shutdown_args::FIELDS
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/flat/namespaced_nonblocking_service.rb:212: warning: previous definition of FIELDS was here
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/namespaced_spec_namespace/namespaced_nonblocking_service.rb:227: warning: already initialized constant NamespacedSpecNamespace::NamespacedNonblockingService::Shutdown_result::FIELDS
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/flat/namespaced_nonblocking_service.rb:227: warning: previous definition of FIELDS was here
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/namespaced_spec_namespace/namespaced_nonblocking_service.rb:241: warning: already initialized constant NamespacedSpecNamespace::NamespacedNonblockingService::Sleep_args::SECONDS
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/flat/namespaced_nonblocking_service.rb:241: warning: previous definition of SECONDS was here
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/namespaced_spec_namespace/namespaced_nonblocking_service.rb:243: warning: already initialized constant NamespacedSpecNamespace::NamespacedNonblockingService::Sleep_args::FIELDS
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/flat/namespaced_nonblocking_service.rb:243: warning: previous definition of FIELDS was here
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/namespaced_spec_namespace/namespaced_nonblocking_service.rb:258: warning: already initialized constant NamespacedSpecNamespace::NamespacedNonblockingService::Sleep_result::FIELDS
      /home/jens/Arbeitsfläche/Thrift/lib/rb/spec/gen-rb/flat/namespaced_nonblocking_service.rb:258: warning: previous definition of FIELDS was here
        generated the right files
        did not generate the wrong files
        has a service class in the right place
        has a struct in the right place
        required an included file
        extended a service
      

      Attachments

        Activity

          People

            Unassigned Unassigned
            jensg Jens Geyer
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated: