mirror of
https://github.com/digital-asset/daml.git
synced 2024-09-20 01:07:18 +03:00
32ca8fb831
* telemetry: use an extra cache directory for telemetry If the sdk's `.daml` directory is not writable, telemetry fails and kills the IDE. We add a new assistant environment variable "DAML_CACHE". If set, this directory is used for telemetry cache data. Fixes #8396. CHANGELOG_BEGIN CHANGELOG_END * try creating directory * check for already existing machine id file * set DAML_CACHE to read-only in assistant integration tests
84 lines
1.9 KiB
Python
84 lines
1.9 KiB
Python
# Copyright (c) 2021 Digital Asset (Switzerland) GmbH and/or its affiliates. All rights reserved.
|
|
# SPDX-License-Identifier: Apache-2.0
|
|
|
|
load("//bazel_tools:haskell.bzl", "da_haskell_library", "da_haskell_test")
|
|
load("@os_info//:os_info.bzl", "is_windows")
|
|
|
|
da_haskell_library(
|
|
name = "da-hs-base",
|
|
srcs = glob(["src/**/*.hs"]),
|
|
hackage_deps = [
|
|
"aeson-pretty",
|
|
"aeson",
|
|
"ansi-terminal",
|
|
"async",
|
|
"base",
|
|
"base16-bytestring",
|
|
"base64-bytestring",
|
|
"binary",
|
|
"blaze-html",
|
|
"bytestring",
|
|
"conduit",
|
|
"containers",
|
|
"deepseq",
|
|
"directory",
|
|
"dlist",
|
|
"extra",
|
|
"filepath",
|
|
"hashable",
|
|
"http-conduit",
|
|
"http-types",
|
|
"lens",
|
|
"monad-loops",
|
|
"mtl",
|
|
"optparse-applicative",
|
|
"pretty-show",
|
|
"pretty",
|
|
"random",
|
|
"safe",
|
|
"safe-exceptions",
|
|
"stm",
|
|
"tar-conduit",
|
|
"tasty-hunit",
|
|
"tasty-quickcheck",
|
|
"tasty",
|
|
"template-haskell",
|
|
"text",
|
|
"time",
|
|
"transformers-base",
|
|
"transformers",
|
|
"unordered-containers",
|
|
"unix-compat",
|
|
"utf8-string",
|
|
"uuid",
|
|
"vector",
|
|
] + ([] if is_windows else ["unix"]),
|
|
src_strip_prefix = "src",
|
|
visibility = ["//visibility:public"],
|
|
deps = [
|
|
"//:sdk-version-hs-lib",
|
|
"//daml-assistant:daml-project-config",
|
|
],
|
|
)
|
|
|
|
da_haskell_test(
|
|
name = "da-hs-base-tests",
|
|
srcs = glob(["tests/**/*.hs"]),
|
|
hackage_deps = [
|
|
"aeson",
|
|
"extra",
|
|
"tasty",
|
|
"base",
|
|
"directory",
|
|
"tasty-hunit",
|
|
"text",
|
|
],
|
|
main_function = "Telemetry.main",
|
|
visibility = ["//visibility:public"],
|
|
deps = [
|
|
":da-hs-base",
|
|
"//daml-assistant:daml-project-config",
|
|
"//libs-haskell/test-utils",
|
|
],
|
|
)
|