Skip to content

Commit

Permalink
Update build definition
Browse files Browse the repository at this point in the history
  • Loading branch information
mn-mikke committed Nov 13, 2023
1 parent 77c4391 commit b9be04a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 25 deletions.
17 changes: 1 addition & 16 deletions h2o-py-mlflow-flavor/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -15,21 +15,6 @@ ext {
testsPath = file("tests")
}

//
// Create a file with version for Python dist task
//
task createVersionFiles() {
doLast {
file("${buildDir}/h2o_mlflow_flavor/").mkdirs()
File version_file = new File("${buildDir}/h2o_mlflow_flavor/", "version.txt")
version_file.write(PROJECT_VERSION)

File build_file = new File("${buildDir}/h2o_mlflow_flavor/", "buildinfo.txt")
build_file.write(buildVersion.toString())
}
}


task copySrcFiles(type: Copy) {
from ("${projectDir}") {
include "setup.py"
Expand All @@ -41,7 +26,7 @@ task copySrcFiles(type: Copy) {
into "${buildDir}"
}

task buildDist(type: Exec, dependsOn: [createVersionFiles, copySrcFiles]) {
task buildDist(type: Exec, dependsOn: [copySrcFiles]) {
workingDir buildDir
doFirst {
file("${buildDir}/tmp").mkdirs()
Expand Down
10 changes: 1 addition & 9 deletions h2o-py-mlflow-flavor/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,7 @@
with open(os.path.join(here, 'DESCRIPTION.rst'), encoding='utf-8') as f:
long_description = f.read()

version = "0.1.0-SNAPSHOT"
# Get the version from the relevant file
with open(os.path.join(here, 'h2o_mlflow_flavor/version.txt'), encoding='utf-8') as f:
version = f.read()

version = "0.1.0"
packages = find_packages(exclude=["tests*"])
print("Found packages: %r" % packages)

Expand Down Expand Up @@ -69,10 +65,6 @@
keywords='ML Flow, H2O-3',

packages=packages,
package_data={"h2o": [
"version.txt", # version file
"buildinfo.txt" # buildinfo file
]},

# run-time dependencies
install_requires=["mlflow>=1.29.0"]
Expand Down

0 comments on commit b9be04a

Please sign in to comment.