Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[query] Make memory follow mill module structure #14773

Open
wants to merge 2 commits into
base: ps-12-17-move_mill_modules_into_subdirectory
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
The diff you're trying to view is too large. We only load the first 3000 changed files.
20 changes: 10 additions & 10 deletions build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -832,7 +832,7 @@ steps:
cd /io/repo/hail

time tar czf test.tar.gz -C python test pytest.ini
time tar czf resources.tar.gz -C src/test resources
time tar czf resources.tar.gz -C modules/src/test resources
time tar czf data.tar.gz -C python/hail/docs data
time TESTNG_SPLITS=5 python3 generate_splits.py
time tar czf splits.tar.gz testng-splits-*.xml
Expand Down Expand Up @@ -965,7 +965,7 @@ steps:
export GOOGLE_APPLICATION_CREDENTIALS=/test-gsa-key/key.json
export AZURE_APPLICATION_CREDENTIALS=/test-gsa-key/key.json
python3 -m hailtop.aiotools.copy 'null' '[
{"from": "src/test/resources",
{"from": "modules/src/test/resources",
"to": "{{ global.test_storage_uri }}/{{ token }}/test/resources"},
{"from": "python/hail/docs/data",
"to": "{{ global.test_storage_uri }}/{{ token }}/doctest/data"}
Expand All @@ -976,8 +976,8 @@ steps:
valueFrom: default_ns.name
mountPath: /test-gsa-key
inputs:
- from: /repo/hail/src/test/resources
to: /io/repo/hail/src/test/resources
- from: /repo/hail/modules/src/test/resources
to: /io/repo/hail/modules/src/test/resources
- from: /repo/hail/python/hail/docs/data
to: /io/repo/hail/python/hail/docs/data
dependsOn:
Expand All @@ -996,8 +996,8 @@ steps:
script: |
set -ex
cd /io
mkdir -p src/test
tar xzf resources.tar.gz -C src/test
mkdir -p modules/src/test
tar xzf resources.tar.gz -C modules/src/test
tar xzf splits.tar.gz
export HAIL_TEST_SKIP_R=1
java -cp hail-test.jar:$SPARK_HOME/jars/* org.testng.TestNG -listener is.hail.LogTestListener testng-splits-$HAIL_RUN_IMAGE_SPLIT_INDEX.xml
Expand Down Expand Up @@ -3636,8 +3636,8 @@ steps:
script: |
set -ex
cd /io
mkdir -p src/test
tar xzf resources.tar.gz -C src/test
mkdir -p modules/src/test
tar xzf resources.tar.gz -C modules/src/test

export HAIL_CLOUD={{ global.cloud }}
export HAIL_DEFAULT_NAMESPACE={{ default_ns.name }}
Expand Down Expand Up @@ -3696,8 +3696,8 @@ steps:
export HAIL_DEFAULT_NAMESPACE={{ default_ns.name }}

cd /io
mkdir -p src/test
tar xzf resources.tar.gz -C src/test
mkdir -p modules/src/test
tar xzf resources.tar.gz -C modules/src/test
java -Xms7500M -Xmx7500M \
-cp hail-test.jar:$SPARK_HOME/jars/* \
org.testng.TestNG \
Expand Down
13 changes: 8 additions & 5 deletions hail/build.mill
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ import mill.scalalib.Assembly._
import mill.scalalib.TestModule.TestNg
import mill.scalalib.scalafmt.ScalafmtModule
import mill.util.Jvm
import os.Path

object Settings {
val hailMajorMinorVersion = "0.2"
Expand Down Expand Up @@ -72,7 +73,7 @@ object Deps {
}
}

trait HailScalaModule extends SbtModule with ScalafmtModule with ScalafixModule { outer =>
trait HailScalaModule extends ScalafmtModule with ScalafixModule { outer =>
override def scalaVersion: T[String] = build.env.scalaVersion()

override def javacOptions: T[Seq[String]] = Seq(
Expand Down Expand Up @@ -106,7 +107,7 @@ trait HailScalaModule extends SbtModule with ScalafmtModule with ScalafixModule
override def bspCompileClasspath: T[Agg[UnresolvedPath]] =
super.bspCompileClasspath() ++ resources().map(p => UnresolvedPath.ResolvedPath(p.path))

trait HailTests extends SbtTests with TestNg with ScalafmtModule with ScalafixModule {
ehigham marked this conversation as resolved.
Show resolved Hide resolved
trait HailScalaTests extends ScalaTests with TestNg with ScalafmtModule with ScalafixModule {
override def forkArgs: T[Seq[String]] = Seq("-Xss4m", "-Xmx4096M")

override def ivyDeps: T[Agg[Dep]] =
Expand All @@ -124,7 +125,9 @@ trait HailScalaModule extends SbtModule with ScalafmtModule with ScalafixModule
}
}

object `package` extends RootModule with HailScalaModule { outer =>
object `package` extends RootModule with SbtModule with HailScalaModule { outer =>

override def millSourcePath: Path = super.millSourcePath / "modules"

object env extends Module {
def scalaVersion: T[String] = Task.Input {
Expand Down Expand Up @@ -260,11 +263,11 @@ object `package` extends RootModule with HailScalaModule { outer =>
)

override def sources: T[Seq[PathRef]] = Task.Sources {
Seq(PathRef(this.millSourcePath / os.up / "src" / env.debugOrRelease() / "java"))
Seq(PathRef(this.millSourcePath / "src" / env.debugOrRelease()))
}
}

object test extends HailTests {
object test extends SbtTests with HailScalaTests {
override def resources: T[Seq[PathRef]] = outer.resources() ++ super.resources()

override def assemblyRules: Seq[Rule] = outer.assemblyRules ++ Seq(
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Loading