[
https://issues.apache.org/jira/browse/THRIFT-696?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12830218#action_12830218
]
Bryan Duxbury commented on THRIFT-696:
--------------------------------------
We used to have it work this way, but it lead to difficulties. The advised way
to require Thrift generated code in Ruby is to add the directory containing the
types to the load path and then require the name of the file without any path.
> require statements should reference from current directory
> ----------------------------------------------------------
>
> Key: THRIFT-696
> URL: https://issues.apache.org/jira/browse/THRIFT-696
> Project: Thrift
> Issue Type: Improvement
> Components: Compiler (Ruby)
> Reporter: Paul Ingles
> Priority: Minor
> Attachments: rb_require_from_current_dir.patch
>
>
> Currently, require statements just use require 'some_constants' or
> 'some_types'. When you move the generated code into part of another project
> that is below the top-level directory the requires are no longer valid.
> I've patched the code to instead use the require as:
> File.join(File.dirname(__FILE__), 'some_constants'))
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.