-
-
Notifications
You must be signed in to change notification settings - Fork 11.3k
Hue #40150
Hue #40150
Changes from 4 commits
c555f5c
7be40f8
375b934
5753a26
12cec72
3f48634
25276fb
74acf9b
a1dc5dd
162547e
a6b5230
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,157 @@ | ||
class Hue < Formula | ||
desc "Hue is a Web interface for analyzing data with Apache Hadoop." | ||
homepage "http://gethue.com/" | ||
url "https://github.com/cloudera/hue/archive/release-3.8.1.tar.gz" | ||
# version "3.8.1" # redundant with version scanned from URL | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Please remove this comment. |
||
sha256 "582777f567b9f4a34e4ce58cfd5ed24aff15f3e02f193e7990329d8cb0161a8a" | ||
|
||
# system dependencies - either Homebrew or Mac OS versions | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Please remove this comment. |
||
depends_on :java | ||
depends_on :python | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Adding a There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Done. |
||
depends_on :mysql | ||
|
||
depends_on "maven" => :build | ||
depends_on "openssl" => :optional | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This needs to be mandatory or you need to find a way to tell Hue's build scripts not to build against openssl There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I made the dependency on "openssl" the default, and added an option to allow the use of system installed OpenSSL
|
||
depends_on "gmp" | ||
|
||
patch :DATA | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Can you please submit this patch to the upstream developers of this project and add a link to the upstream patch submission and explanation of why the patch is needed in a comment in the formula file. Thanks! |
||
|
||
def install | ||
# patched the Makefile vars to install to ${PREFIX}/libexec | ||
system "make", "-j", "1", "install", "PREFIX=#{prefix}" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Use There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Done. |
||
|
||
(libexec/"desktop/conf").install "desktop/conf.dist/hue.ini" | ||
etc.install_symlink "#{libexec}/desktop/conf/hue.ini" | ||
|
||
bin.install_symlink "#{libexec}/build/env/bin/hue" | ||
end | ||
|
||
test do | ||
fork do | ||
system "#{bin}/hue", "runserver" | ||
end | ||
sleep(6) | ||
|
||
begin | ||
system "curl", "-s", "-S", "-f", "-L", "http://localhost:8000" | ||
assert_equal 0, $?.exitstatus | ||
ensure | ||
sleep(2) | ||
system "pkill", "-f", "hue" | ||
end | ||
end | ||
end | ||
__END__ | ||
diff --git a/desktop/core/ext-py/tablib-develop/setup.py b/desktop/core/ext-py/tablib-develop/setup.py | ||
index fb16546..6f3bcfe 100755 | ||
--- a/desktop/core/ext-py/tablib-develop/setup.py | ||
+++ b/desktop/core/ext-py/tablib-develop/setup.py | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why is this patch necessary and has it been submitted upstream? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Would Hue need this or a rebase on latest tablib? (that way you don't need this here) |
||
@@ -36,36 +36,46 @@ if sys.argv[-1] == 'test': | ||
os.system('py.test test_tablib.py') | ||
sys.exit() | ||
|
||
-setup( | ||
- name='tablib', | ||
- version=tablib.__version__, | ||
- description='Format agnostic tabular data library (XLS, JSON, YAML, CSV)', | ||
- long_description=(open('README.rst').read() + '\n\n' + | ||
- open('HISTORY.rst').read()), | ||
- author='Kenneth Reitz', | ||
- author_email='[email protected]', | ||
- url='http://python-tablib.org', | ||
- packages=[ | ||
- 'tablib', 'tablib.formats', | ||
- 'tablib.packages', | ||
+packages = [ | ||
+ 'tablib', 'tablib.formats', | ||
+ 'tablib.packages', | ||
+ 'tablib.packages.omnijson', | ||
+ 'tablib.packages.unicodecsv' | ||
+] | ||
+ | ||
+if sys.version_info[0] == 2: | ||
+ packages.extend([ | ||
'tablib.packages.xlwt', | ||
- 'tablib.packages.xlwt3', | ||
'tablib.packages.xlrd', | ||
- 'tablib.packages.xlrd3', | ||
- 'tablib.packages.omnijson', | ||
'tablib.packages.odf', | ||
- 'tablib.packages.odf3', | ||
'tablib.packages.openpyxl', | ||
'tablib.packages.openpyxl.shared', | ||
'tablib.packages.openpyxl.reader', | ||
'tablib.packages.openpyxl.writer', | ||
+ 'tablib.packages.yaml' | ||
+ ]) | ||
+else: | ||
+ packages.extend([ | ||
+ 'tablib.packages.xlwt3', | ||
+ 'tablib.packages.xlrd3', | ||
+ 'tablib.packages.odf3', | ||
'tablib.packages.openpyxl3', | ||
'tablib.packages.openpyxl3.shared', | ||
'tablib.packages.openpyxl3.reader', | ||
'tablib.packages.openpyxl3.writer', | ||
- 'tablib.packages.yaml', | ||
- 'tablib.packages.unicodecsv' | ||
- ], | ||
+ 'tablib.packages.yaml3' | ||
+ ]) | ||
+ | ||
+setup( | ||
+ name='tablib', | ||
+ version=tablib.__version__, | ||
+ description='Format agnostic tabular data library (XLS, JSON, YAML, CSV)', | ||
+ long_description=(open('README.rst').read() + '\n\n' + | ||
+ open('HISTORY.rst').read()), | ||
+ author='Kenneth Reitz', | ||
+ author_email='[email protected]', | ||
+ url='http://python-tablib.org', | ||
+ packages=packages, | ||
license='MIT', | ||
classifiers=( | ||
'Development Status :: 5 - Production/Stable', | ||
|
||
diff --git a/desktop/core/ext-py/parquet-python/parquet/bitstring.py b/desktop/core/ext-py/parquet-python/parquet/bitstring.py | ||
index ab807a2..7203c94 100644 | ||
--- a/desktop/core/ext-py/parquet-python/parquet/bitstring.py | ||
+++ b/desktop/core/ext-py/parquet-python/parquet/bitstring.py | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Same question here. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Patch has been submitted upstream. |
||
@@ -1,7 +1,5 @@ | ||
- | ||
SINGLE_BIT_MASK = [1 << x for x in range(7, -1, -1)] | ||
|
||
-] | ||
|
||
class BitString(object): | ||
|
||
@@ -10,7 +8,6 @@ class BitString(object): | ||
self.offset = offset if offset is not None else 0 | ||
self.length = length if length is not None else 8 * len(data) - self.offset | ||
|
||
- | ||
def __getitem__(self, key): | ||
try: | ||
start = key.start | ||
@@ -18,5 +15,5 @@ class BitString(object): | ||
except AttributeError: | ||
if key < 0 or key >= length: | ||
raise IndexError() | ||
- byte_index, bit_offset = divmod(self.offset + key), 8) | ||
- return self.bytes[byte_index] & SINGLE_BIT_MASK[bit_offset] | ||
\ No newline at end of file | ||
+ byte_index, bit_offset = (divmod(self.offset + key), 8) | ||
+ return self.bytes[byte_index] & SINGLE_BIT_MASK[bit_offset] | ||
diff --git a/Makefile.vars.priv b/Makefile.vars.priv | ||
index 79bc443..e17e192 100644 | ||
--- a/Makefile.vars.priv | ||
+++ b/Makefile.vars.priv | ||
@@ -53,7 +53,7 @@ BLD_DIR_DOC := $(BLD_DIR)/docs | ||
|
||
# Installation directory | ||
PREFIX ?= /usr/local | ||
-INSTALL_DIR ?= $(PREFIX)/hue | ||
+INSTALL_DIR ?= $(PREFIX)/libexec | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Looks like you could pass this on the command line instead of patching, i.e. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yeah, that was the first thing I tried. When I set INSTALL_DIR from the command line, I get the following error when the first Hue web submodule is installed:
It looks like this is happening inside this target: https://github.com/cloudera/hue/blob/master/Makefile.sdk#L245 So, I'd need to patch anyways. I'm going to open an issue with Hue. For now, patching the INSTALL_DIR variable instead of setting it on the command line works fine. |
||
INSTALL_APPS_DIR ?= $(INSTALL_DIR)/desktop/apps | ||
|
||
ifeq ($(INSTALL_DIR),$(patsubst /%,%,$(INSTALL_DIR))) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can use
https://
here.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good point but gethue.com does not have https yet, it will break the page on modern browsers
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Right it breaks the page.