Skip to content

Commit 36e2f0f

Browse files
authored
Merge pull request #2062 from codalab/develop
Merge develop into master (1.21.1)
2 parents d26ef68 + 734ebe0 commit 36e2f0f

File tree

21 files changed

+523
-261
lines changed

21 files changed

+523
-261
lines changed

.circleci/config.yml

Lines changed: 20 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -15,39 +15,49 @@ jobs:
1515
#
1616
# In another terminal:
1717
# $ open vnc://0.0.0.0:5900
18-
name: Download and start X for VNC viewing
18+
name: "Setup: Enable VNC access"
1919
command: |
2020
sudo apt-get update
2121
sudo apt-get install -y x11vnc
2222
# x11vnc -forever -nopw
2323
background: true
2424

25-
- run: cp .env_circleci .env
25+
- run:
26+
name: "Setup: Copy environment variables"
27+
command: cp .env_circleci .env
2628

2729

2830
- run:
29-
name: Making gross directories for minio, cannot be made by docker for some reason
31+
name: "Setup: Create directories for MinIO (cannot be made by docker for some reason)"
3032
command: |
3133
sudo mkdir -p var/minio/public
3234
sudo mkdir -p var/minio/private
3335
3436
- run:
35-
name: Build containers and collect static
37+
name: "Docker: Build containers and collect static files"
3638
command: |
3739
docker compose -f docker-compose.yml -f docker-compose.selenium.yml up -d
3840
docker compose -f docker-compose.yml -f docker-compose.selenium.yml exec django python manage.py collectstatic --noinput
3941
40-
- run: docker-compose exec django flake8 src/
41-
- run: docker pull codalab/codalab-legacy:py37 # not available without "not e2e" tests as they pull ahead of time
42-
- run: docker pull codalab/codalab-legacy:py3 # not available without "not e2e" tests as they pull ahead of time
43-
- run: docker pull vergilgxw/autotable:v2 # not available without "not e2e" tests as they pull ahead of time
42+
- run:
43+
name: "Lint: Check code style with flake8"
44+
command: docker-compose exec django flake8 src/
45+
46+
47+
- run:
48+
name: "Docker: Pull required images"
49+
# not available without "not e2e" tests as they pull ahead of time
50+
command: |
51+
docker pull codalab/codalab-legacy:py37
52+
docker pull codalab/codalab-legacy:py3
53+
docker pull vergilgxw/autotable:v2
4454
4555
- run:
46-
name: pytest
56+
name: "Tests: Run unit/integration tests (excluding e2e)"
4757
command: docker compose -f docker-compose.yml -f docker-compose.selenium.yml exec django py.test src/ -m "not e2e"
4858

4959
- run:
50-
name: e2e tests
60+
name: "Tests: Run end-to-end (E2E) tests"
5161
command: docker compose -f docker-compose.yml -f docker-compose.selenium.yml exec django py.test src/tests/functional/ -m e2e
5262
no_output_timeout: 60m
5363

.github/CODE_OF_CONDUCT.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ This Code of Conduct applies to all interactions related to this project, includ
3131

3232
## 5. Reporting Issues
3333

34-
If you witness or experience any behavior that violates this Code of Conduct, please report it to **info@codalab.org**. All reports will be reviewed and handled confidentially.
34+
If you witness or experience any behavior that violates this Code of Conduct, please report it to **info@codabench.org**. All reports will be reviewed and handled confidentially.
3535

3636
## 6. Enforcement
3737

@@ -49,7 +49,7 @@ This Code of Conduct is adapted from the [Contributor Covenant](https://www.cont
4949
---
5050

5151
### Questions?
52-
If you have any questions or concerns, please reach out to **info@codalab.org**.
52+
If you have any questions or concerns, please reach out to **info@codabench.org**.
5353

5454

5555

compute_worker/celery_config.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,11 @@
11
import os
2-
2+
import ssl
33

44
broker_url = os.environ.get('BROKER_URL')
5-
broker_use_ssl = os.environ.get('BROKER_USE_SSL', False)
5+
if os.environ.get('BROKER_USE_SSL', False):
6+
broker_use_ssl = {
7+
"cert_reqs": ssl.CERT_NONE,
8+
}
69
worker_concurrency = 1
710
worker_prefetch_multiplier = 1
811
task_acks_late = True

compute_worker/compute_worker.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
import websockets
2222
import yaml
2323
from billiard.exceptions import SoftTimeLimitExceeded
24-
from celery import Celery, task, utils
24+
from celery import Celery, shared_task, utils
2525
from kombu import Queue, Exchange
2626
from urllib3 import Retry
2727

@@ -113,7 +113,7 @@ class ExecutionTimeLimitExceeded(Exception):
113113
# The main compute worker entrypoint, this is how a job is ran at the highest
114114
# level.
115115
# -----------------------------------------------------------------------------
116-
@task(name="compute_worker_run")
116+
@shared_task(name="compute_worker_run")
117117
def run_wrapper(run_args):
118118
logger.info(f"Received run arguments: {run_args}")
119119
run = Run(run_args)
@@ -632,6 +632,9 @@ async def _run_program_directory(self, program_dir, kind):
632632
logger.warning(
633633
"Program directory missing metadata, assuming it's going to be handled by ingestion"
634634
)
635+
# Copy submission files into prediction output
636+
# This is useful for results submissions but wrongly uses storage
637+
shutil.copytree(program_dir, self.output_dir)
635638
return
636639
else:
637640
raise SubmissionException("Program directory missing 'metadata.yaml/metadata'")

0 commit comments

Comments
 (0)