Skip to content

Commit

Permalink
refactor!: remove 'cache-dotcache' key
Browse files Browse the repository at this point in the history
  • Loading branch information
ahal committed Jan 7, 2025
1 parent 44938ec commit fe7762e
Show file tree
Hide file tree
Showing 4 changed files with 0 additions and 25 deletions.
22 changes: 0 additions & 22 deletions src/taskgraph/transforms/run/run_task.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,6 @@
run_task_schema = Schema(
{
Required("using"): "run-task",
# if true, add a cache at ~worker/.cache, which is where things like pip
# tend to hide their caches. This cache is never added for level-1 tasks.
# TODO Once bug 1526028 is fixed, this and 'use-caches' should be merged.
Required("cache-dotcache"): bool,
# Which caches to use. Only one of 'include-caches' or 'exclude-caches'
# may be specified at a time. If 'include-caches' is specified, it may
# take a boolean in which case either all (True) or no (False) caches
Expand Down Expand Up @@ -119,7 +115,6 @@ def common_setup(config, task, taskdesc, command):


worker_defaults = {
"cache-dotcache": False,
"checkout": True,
"sparse-profile": None,
"run-as-root": False,
Expand All @@ -146,16 +141,6 @@ def docker_worker_run_task(config, task, taskdesc):
command = run.pop("run-task-command", ["/usr/local/bin/run-task"])
common_setup(config, task, taskdesc, command)

if run.get("cache-dotcache"):
worker["caches"].append(
{
"type": "persistent",
"name": "{project}-dotcache".format(**config.params),
"mount-point": "{workdir}/.cache".format(**run),
"skip-untrusted": True,
}
)

run_command = run["command"]

# dict is for the case of `{'task-reference': str}`.
Expand Down Expand Up @@ -188,13 +173,6 @@ def generic_worker_run_task(config, task, taskdesc):
common_setup(config, task, taskdesc, command)

worker.setdefault("mounts", [])
if run.get("cache-dotcache"):
worker["mounts"].append(
{
"cache-name": "{project}-dotcache".format(**config.params),
"directory": "{workdir}/.cache".format(**run),
}
)
worker["mounts"].append(
{
"content": {
Expand Down
1 change: 0 additions & 1 deletion taskcluster/kinds/check/kind.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ task-defaults:
run:
using: run-task
cwd: '{checkout}'
cache-dotcache: true

tasks:
type:
Expand Down
1 change: 0 additions & 1 deletion taskcluster/kinds/doc/kind.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ task-defaults:
run:
using: run-task
cwd: '{checkout}'
cache-dotcache: true

tasks:
generate:
Expand Down
1 change: 0 additions & 1 deletion taskcluster/kinds/test/kind.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ task-defaults:
run:
using: run-task
cwd: '{checkout}'
cache-dotcache: true

tasks:
unit:
Expand Down

0 comments on commit fe7762e

Please sign in to comment.