Skip to content

Commit

Permalink
Merge pull request #204 from spacetelescope/release/v0.4.43
Browse files Browse the repository at this point in the history
Release/v0.4.43
  • Loading branch information
raswaters authored May 10, 2024
2 parents 06b58da + 2be92dd commit 4d44300
Show file tree
Hide file tree
Showing 30 changed files with 258 additions and 11,042 deletions.
10 changes: 5 additions & 5 deletions .github/workflows/pytest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,12 @@ jobs:
uses: actions/checkout@v2

- name: install requirements
run: |
run: |
pip install .[dev]
pip install numpy scikit-learn tensorflow --upgrade-strategy only-if-needed
pip install numpy scikit-learn==1.4.1.post1 tensorflow==2.15.0.post1 --upgrade-strategy only-if-needed
- name: run pytest code coverage check
run: |
run: |
pytest \
--verbose \
--cov=calcloud \
Expand Down Expand Up @@ -54,9 +54,9 @@ jobs:
uses: actions/checkout@v2

- name: install requirements
run: |
run: |
pip install .[dev]
pip install numpy scikit-learn tensorflow --upgrade-strategy only-if-needed
pip install numpy scikit-learn==1.4.1.post1 tensorflow==2.15.0.post1 --upgrade-strategy only-if-needed
- name: run pytest
run: pytest -rP
1 change: 1 addition & 0 deletions calcloud/batch.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
particularly pagination for the list and describe jobs functions which let
them act on job counts > 100 jobs.
"""

import argparse
import json
import datetime
Expand Down
1 change: 1 addition & 0 deletions calcloud/common.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
""" a module to hold some common configuration items that various scripts may need """

from botocore.config import Config

# we need some mitigation of potential API rate restrictions for the (especially) Batch API
Expand Down
1 change: 0 additions & 1 deletion calcloud/exit_codes.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
generic values of 0 or 1 to prevent conflicts with these codes.
"""


_MEMORY_ERROR_NAMES = ["SUBPROCESS_MEMORY_ERROR", "CALDP_MEMORY_ERROR", "CONTAINER_MEMORY_ERROR", "OS_MEMORY_ERROR"]


Expand Down
1 change: 1 addition & 0 deletions calcloud/io.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
It hides the structure of the messaging system and provides a
simple API for putting, getting, listing, and deleting messages.
"""

import sys
import os
import doctest
Expand Down
1 change: 1 addition & 0 deletions calcloud/lambda_submit.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
handlers for more information on how jobs are initiated and
retried.
"""

import time
import os

Expand Down
1 change: 1 addition & 0 deletions calcloud/log.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@
>>> _ = log.set_verbose(old_verbose)
"""

import sys
import os
import logging
Expand Down
1 change: 1 addition & 0 deletions calcloud/model_ingest.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
See ModelIngest/lambda_scrape.py for more information on how model data is ingested to DDB.
"""

import boto3
import sys
import numpy as np
Expand Down
1 change: 1 addition & 0 deletions calcloud/plan.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
of job definitions with increasing memory requirements until the job later
succeeds with sufficient memory or exhausts all retries.
"""

import sys
import os
from collections import namedtuple
Expand Down
1 change: 1 addition & 0 deletions calcloud/s3.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
bucket_name, object_path = s3_split_path(s3_path)
"""

import os
import os.path

Expand Down
1 change: 1 addition & 0 deletions calcloud/timing.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"""This module provides functions and classes used to track and compute
rate metrics.
"""

from collections import Counter
import datetime
import os
Expand Down
6 changes: 3 additions & 3 deletions changelog.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
- default base docker image set to CALDP_20231201_CAL_final
- default crds update to hst_1123.pmap
- updated lambda runtime from python 3.7 to python 3.11
- default base docker image set to CALDP_20240509_CAL_final
- default crds update to hst_1155.pmap
- SSL certificate workflow updates to pull certificates from the ITSD S3 bucket
16 changes: 5 additions & 11 deletions iac/codebuild/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -27,21 +27,15 @@ RUN set -ex \
RUN mkdir -p /etc/ssl/certs && \
mkdir -p /etc/pki/ca-trust/source/anchors

COPY tls-ca-bundle.pem /etc/pki/ca-trust/source/anchors/stsci-tls-ca-bundle.pem

COPY tls-ca-bundle.pem /etc/ssl/certs/stsci-tls-ca-bundle.pem
COPY STSCICA.crt /etc/ssl/certs/STSCICA.crt
COPY STSCICA.crt /etc/pki/ca-trust/source/anchors/STSCICA.crt

RUN update-ca-trust

# These should only happen once
ENV REQUESTS_CA_BUNDLE=/etc/ssl/certs/stsci-tls-ca-bundle.pem
ENV CURL_CA_BUNDLE=/etc/ssl/certs/stsci-tls-ca-bundle.pem
ENV NODE_EXTRA_CA_CERTS=/etc/ssl/certs/stsci-tls-ca-bundle.pem

#RUN curl -L https://rpm.nodesource.com/setup_16.x | bash - && \
# yum install -y nodejs

#ENV NODE_16_VERSION="16.15.1"
ENV REQUESTS_CA_BUNDLE=/etc/pki/ca-trust/extracted/pem/tls-ca-bundle.pem
ENV CURL_CA_BUNDLE=/etc/pki/ca-trust/extracted/pem/tls-ca-bundle.pem
ENV NODE_EXTRA_CA_CERTS=/etc/pki/ca-trust/extracted/pem/tls-ca-bundle.pem

RUN yum install https://rpm.nodesource.com/pub_16.x/nodistro/repo/nodesource-release-nodistro-1.noarch.rpm -y
RUN yum install nodejs -y --setopt=nodesource-nodejs.module_hotfixes=1
Expand Down
3 changes: 1 addition & 2 deletions iac/codebuild/copy-cert
Original file line number Diff line number Diff line change
Expand Up @@ -30,15 +30,14 @@ def run(cmd, cwd=".", timeout=100):

def get_cert(cert_path, local_path):
run(f"cp {cert_path} {local_path}")
#os.system(f"cp {cert_path} {local_path}") # Using os module temporarily
print(f"Copied {cert_path} to {local_path}.")


def main(cert_path, local_cert_path):
try:
get_cert(cert_path, local_cert_path)
except:
print("Skipping update of tls-ca-bundle.pem needed to build on science platforms.")
print("Skipping update of tls-ca-bundle.pem.")
return 0
print("Cert update complete.")
return 0
Expand Down
Loading

0 comments on commit 4d44300

Please sign in to comment.