Skip to content

prepare 5.0-rc4 #172

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

Merged
merged 59 commits into from
Nov 14, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
59 commits
Select commit Hold shift + click to select a range
ba975a5
tf 2.7
previ Jan 21, 2022
e437748
revert tf 2.1
previ Jan 22, 2022
9d5fdf4
bump numpy ver
previ Jan 23, 2022
7c7ee87
bump requirements_stub
previ Jan 24, 2022
ba9729e
bump requirements_stub
previ Jan 24, 2022
80c3b6f
led ws2812b
previ Jan 25, 2022
e14de56
led ws2812b
previ Jan 25, 2022
bcbba45
led ws2812b
previ Jan 25, 2022
f2c224a
led ws2812b
previ Jan 26, 2022
140285d
add listMusicPackages api
previ Jan 29, 2022
d88b342
fix musicPackage export
previ Jan 30, 2022
cfab93b
remove coderbot-copy.py
previ Jan 30, 2022
c90ccf8
fix music package removal
previ Feb 1, 2022
db7bfde
Merge branch 'develop' of https://github.com/CoderBotOrg/backend into…
previ Feb 1, 2022
1c69018
v1 feature parity
previ Feb 1, 2022
0cefff7
fix #155
previ Feb 6, 2022
a6eec09
fix program status and log with v2
previ Feb 7, 2022
d1d3882
update ci
previ Feb 8, 2022
55023d5
add default activity init
previ Mar 6, 2022
5763bc8
add default activity init
previ Mar 7, 2022
a3f291b
add default activity
previ Mar 9, 2022
ca1b990
activity default parameters
previ Mar 12, 2022
c096602
bullseye wip
previ May 28, 2022
fa63bb4
bullseye wip
previ May 29, 2022
5d50a5e
Update audioControls.py
previ May 29, 2022
0f3e5f6
bullseye wip
previ May 29, 2022
1266d83
Update audio.py
previ Jun 8, 2022
e032049
update stock activities
previ Jun 8, 2022
d58a6d8
Update program.py
previ Jun 11, 2022
94e2c76
Update activity_default.json
previ Jun 12, 2022
a1ec6ac
Update coderbot.py
previ Jun 18, 2022
ea027ed
no longer init_activities
previ Jun 28, 2022
c71cfc7
move init_activities on frontend for i18n
previ Jun 28, 2022
795fd4c
fix v4.1 bugs
previ Jul 3, 2022
06ad987
fix 4.1 bugs
previ Jul 3, 2022
a5699ba
fix 4.1 bugs
previ Jul 3, 2022
e6b0ffb
fix 4.1 bugs
previ Jul 3, 2022
0cadf12
fix 4.1 bugs
previ Jul 3, 2022
6dc5198
fix v4.1 bugs
previ Jul 3, 2022
94985a5
fix 4.1 bugs
previ Jul 4, 2022
76b850a
fix 4.1 bugs
previ Jul 4, 2022
216b1f8
fix 4.1 bugs
previ Jul 4, 2022
3dc0eb3
fix 4.1 bugs
previ Jul 5, 2022
02d3601
fix 4.1 bugs
previ Jul 6, 2022
5de8c00
Update wifi.py
previ Jul 7, 2022
86bcc8d
Update wifi.py
previ Jul 8, 2022
9ab32b3
add CONTRIBUTING.md (#162)
avivace Jul 8, 2022
66441fa
merge master
previ Jul 8, 2022
5454eaa
fix event
previ Aug 13, 2022
cc4792a
Refactor API (#166)
previ Oct 23, 2022
f378bd4
Refactor api v3 (#167)
previ Oct 25, 2022
0920d25
wip #164
previ Oct 26, 2022
e78c71f
wip #164
previ Oct 26, 2022
6a32faa
wip #164
previ Oct 26, 2022
a82fe38
wip #164
previ Oct 27, 2022
5f84450
wip #164
previ Oct 27, 2022
53537b3
wip #164
previ Oct 27, 2022
4b106cb
merge master into develop
previ Oct 27, 2022
2f64fe2
parent 4b106cba48d5a8efb0a29c9d81566edaf563f651
previ Oct 30, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
5 changes: 2 additions & 3 deletions .circleci/config.yml → .circleci/_config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ jobs:
build:
docker:
# specify the version you desire here
- image: coderbot/coderbot-ci:3.9-bullseye-ffmpeg
- image: coderbot/coderbot-ci:3.9-bullseye

working_directory: ~/repo

Expand Down Expand Up @@ -39,7 +39,7 @@ jobs:
name: run tests
command: |
. venv/bin/activate
export PYTHONPATH=./stub:test
export PYTHONPATH=./coderbot:./stub:./test
mkdir test-reports
python3 -m unittest test/coderbot_test.py 2>&1 | tee test-reports/test_report.txt
python3 -m unittest test/camera_test.py 2>&1 | tee test-reports/test_report.txt
Expand All @@ -51,4 +51,3 @@ jobs:

- store_test_results:
path: test-reports/

119 changes: 119 additions & 0 deletions .github/workflows/build_backend.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,119 @@
# This workflow will do a clean install of node dependencies, cache/restore them, build the source code and run tests across different versions of node
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions

name: build CoderBot backend

on: push

jobs:
test:
runs-on: ubuntu-latest
container: coderbot/coderbot-ci:3.9-bullseye-slim
steps:
- uses: actions/checkout@v3 # Checking out the repo
- run: pip install -r docker/stub/requirements.txt
- run: |
export PYTHONPATH=./coderbot:./stub:./test
mkdir test-reports
python3 -m unittest test/coderbot_test.py 2>&1 | tee test-reports/test_report.txt
python3 -m unittest test/camera_test.py 2>&1 | tee test-reports/test_report.txt
#python3 -m unittest test/cnn_test.py 2>&1 | tee test-reports/test_report.txt
echo "test complete"
- run: |
export PYTHONPATH=./stub:./coderbot:./test
python3 coderbot/main.py > coderbot.log &
sleep 30
apt-get install -y python3-venv
mkdir -p schemathesis
python3 -m venv schemathesis
. schemathesis/bin/activate
pip install schemathesis
st run --endpoint 'activities' --hypothesis-max-examples=10 --request-timeout=20 http://localhost:5000/api/v1/openapi.json
#st run --endpoint 'media' --hypothesis-max-examples=10 --request-timeout=20 http://localhost:5000/api/v1/openapi.json
st run --endpoint 'control/speak' --hypothesis-max-examples=10 --request-timeout=20 http://localhost:5000/api/v1/openapi.json
st run --endpoint 'control/stop' --hypothesis-max-examples=10 --request-timeout=20 http://localhost:5000/api/v1/openapi.json
st run --endpoint 'music' --hypothesis-max-examples=10 --request-timeout=20 http://localhost:5000/api/v1/openapi.json
st run --endpoint 'programs' --hypothesis-max-examples=10 --request-timeout=20 http://localhost:5000/api/v1/openapi.json
echo "openapi test complete"

release-backend:
needs: [test]
runs-on: ubuntu-latest
steps:
- name: Docker meta
id: meta
uses: docker/metadata-action@v4
with:
# list of Docker images to use as base name for tags
images: ghcr.io/coderbotorg/backend
# generate Docker tags based on the following events/attributes
tags: |
# always latest
type=raw,value=latest
# branch event
type=ref,event=branch
# tag event
type=ref,event=tag
# pull request event
type=ref,event=pr
# push event
type=sha,enable=true,prefix=git-,format=short
- uses: actions/checkout@v3 # Checking out the repo
- name: Set up QEMU
uses: docker/setup-qemu-action@v2
- name: Set up Docker Buildx
id: buildx
uses: docker/setup-buildx-action@v2
- name: Login to DockerHub
uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build and push
uses: docker/build-push-action@v3
with:
push: true
build-args: CODERBOT_VERSION=${{github.ref_name}}-${{github.sha}}
platforms: linux/arm/v7
tags: ${{ steps.meta.outputs.tags }}
context: .
file: docker/Dockerfile
cache-from: type=registry,ref=ghcr.io/coderbotorg/backend:latest
cache-to: type=inline

release-stub:
needs: [test]
runs-on: ubuntu-latest
steps:
- name: Docker meta
id: meta
uses: docker/metadata-action@v4
with:
# list of Docker images to use as base name for tags
images: ghcr.io/coderbotorg/backend
# generate Docker tags based on the following events/attributes
tags: |
# always latest
type=raw,value=stub-latest
- uses: actions/checkout@v3 # Checking out the repo
- name: Set up Docker Buildx
id: buildx
uses: docker/setup-buildx-action@v2
- name: Login to DockerHub
uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build and push
uses: docker/build-push-action@v3
with:
push: true
build-args: CODERBOT_VERSION=${{github.ref_name}}-${{github.sha}}
platforms: linux/amd64
tags: ${{ steps.meta.outputs.tags }}
context: .
file: docker/stub/Dockerfile
cache-from: type=registry,ref=ghcr.io/coderbotorg/backend:stub-latest
cache-to: type=inline
21 changes: 7 additions & 14 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -33,28 +33,21 @@
*.sqlite

# Pictures taken
photos/*.jpg
photos/*.mp4
photos/*.h264
photos/*.json
media/*.jpeg
media/*.mp4
saved_photos

#cnn models
cnn_models/*
cnn_models/cache/*

# Sounds recorded
sounds/*.wav

# Logs
logs/*.log
logs/*.log.*

# User programs
data/*.data

# Tutorial
static/blockly-tutorial
data/*.json

# OS generated files #
######################
Expand Down Expand Up @@ -88,12 +81,12 @@ coderbot.cfg

swagger-ui/

# Photos
photos/metadata.json

# Uploaded updates folder
updatePackages/
updatePackages

# firmware
firmware/

# test
cassette.yaml
.hypothesis
45 changes: 0 additions & 45 deletions activity.py

This file was deleted.

Loading