Skip to content

Commit

Permalink
Feature/pdct 1671 s3 back up for bulk import (#247)
Browse files Browse the repository at this point in the history
* Comment s3 backup logic back in + test refactor

* Bump patch version

* Bump patch version again

* Move validation functions to the validation service

* Use a simple aws client without config to connect to s3

* Bump patch version
  • Loading branch information
annaCPR authored Nov 18, 2024
1 parent 91cca75 commit da4c7cd
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
5 changes: 3 additions & 2 deletions app/clients/aws/s3bucket.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,11 @@
from typing import Any
from urllib.parse import quote_plus, urlsplit

import boto3
from botocore.exceptions import ClientError
from pydantic import BaseModel

from app.clients.aws.client import AWSClient, get_s3_client
from app.clients.aws.client import AWSClient
from app.errors import RepositoryError

_LOGGER = logging.getLogger(__name__)
Expand Down Expand Up @@ -125,7 +126,7 @@ def upload_ingest_json_to_s3(
json.dump(data, file, indent=4)
return

s3_client = get_s3_client()
s3_client = boto3.client("s3", region_name="eu-west-2")

context = S3UploadContext(
bucket_name=ingest_upload_bucket,
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "admin_backend"
version = "2.17.10"
version = "2.17.11"
description = ""
authors = ["CPR-dev-team <[email protected]>"]
packages = [{ include = "app" }, { include = "tests" }]
Expand Down

0 comments on commit da4c7cd

Please sign in to comment.