-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Dynamodb simplification #769
Conversation
* Fixed exempt paths, init swagger docs * open api documentation - initial start * putting open api docs into openapi directory within backend * remove debug print * rename some open api yamls * open api github action * 🎨 Format Python code with psf/black * github action fix * gh action fix * open api validator install cmd fix * spectral * rename file * typo * fix * debug * swagger cli * fix * typo * gh action debug * --no color args * ensure all files get validated by swagger-cli * created yaml file for default dataset * Added yaml files for all apis and updates dlapi.openapi.yaml * removed duplicates from dlpai and edited updateUserProgressData descriptions * removed duplicate keys from dlpapi * corrected types --------- Co-authored-by: Faris Durrani <fdurrani@mythics.com> Co-authored-by: karkir0003 <karkir0003@users.noreply.github.com> Co-authored-by: Austin Tsang <47958374+Dashrekker@users.noreply.github.com>
* attempt at ecr put image: * relaxed ecr rules to push every time * skipped tests * new commands * mini docker * complete example * complete * example * reverted example * fixed Dockerfile
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remaining comments which cannot be posted as a review comment to avoid GitHub Rate Limit
pyright
backend/endpoints/trainspace_endpoints.py|90 col 36| Expected 0 positional arguments (reportGeneralTypeIssues)
backend/endpoints/trainspace_endpoints.py|120 col 41| Expected 0 positional arguments (reportGeneralTypeIssues)
backend/endpoints/trainspace_endpoints.py|147 col 28| Expected 0 positional arguments (reportGeneralTypeIssues)
backend/endpoints/utils.py|21 col 17| Expression of type "ExecutionData" cannot be assigned to declared type "dict[Unknown, Unknown]"
"ExecutionData" is incompatible with "dict[Unknown, Unknown]" (reportGeneralTypeIssues)
import os | ||
import traceback | ||
import datetime | ||
from werkzeug.utils import secure_filename |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [pyright] reported by reviewdog 🐶
Import "werkzeug.utils" could not be resolved (reportMissingImports)
|
||
from flask import Flask, request, send_from_directory |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [pyright] reported by reviewdog 🐶
Import "flask" could not be resolved (reportMissingImports)
) | ||
from backend.middleware import middleware | ||
from flask_cors import CORS | ||
from flasgger import Swagger |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [pyright] reported by reviewdog 🐶
Import "flasgger" could not be resolved (reportMissingImports)
from backend.middleware import middleware | ||
from flask_cors import CORS | ||
from flasgger import Swagger | ||
from flasgger.utils import swag_from |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [pyright] reported by reviewdog 🐶
Import "flasgger.utils" could not be resolved (reportMissingImports)
from backend.common.utils import * | ||
from backend.firebase_helpers.firebase import init_firebase | ||
from backend.middleware import middleware | ||
from backend.aws_helpers.dynamo_db_utils.learnmod_db import ( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [pyright] reported by reviewdog 🐶
Import "backend.aws_helpers.dynamo_db_utils.learnmod_db" could not be resolved (reportMissingImports)
created: str = None | ||
data_source: str = None | ||
dataset_data: dict = None | ||
name: str = None |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [pyright] reported by reviewdog 🐶
Expression of type "None" cannot be assigned to declared type "str"
Type "None" cannot be assigned to type "str" (reportGeneralTypeIssues)
data_source: str = None | ||
dataset_data: dict = None | ||
name: str = None | ||
parameters_data: dict = None |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [pyright] reported by reviewdog 🐶
Expression of type "None" cannot be assigned to declared type "dict[Unknown, Unknown]"
Type "None" cannot be assigned to type "dict[Unknown, Unknown]" (reportGeneralTypeIssues)
dataset_data: dict = None | ||
name: str = None | ||
parameters_data: dict = None | ||
review_data: str = None |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [pyright] reported by reviewdog 🐶
Expression of type "None" cannot be assigned to declared type "str"
Type "None" cannot be assigned to type "str" (reportGeneralTypeIssues)
name: str = None | ||
parameters_data: dict = None | ||
review_data: str = None | ||
status: str = None |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [pyright] reported by reviewdog 🐶
Expression of type "None" cannot be assigned to declared type "str"
Type "None" cannot be assigned to type "str" (reportGeneralTypeIssues)
|
||
|
||
def getAllUserTrainspaceData(user_id: str) -> str: | ||
def updateStatus(trainspace_id: str, status: str, entryData: dict = None) -> bool: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [pyright] reported by reviewdog 🐶
Expression of type "None" cannot be assigned to parameter of type "dict[Unknown, Unknown]"
Type "None" cannot be assigned to type "dict[Unknown, Unknown]" (reportGeneralTypeIssues)
Dynamodb simplification
What user problem are we solving?
To simplify the dynamodb utils CRUD functions
Testing Methodology
Endpoints have their unit test cases in the MD file