Skip to content

Commit

Permalink
fix: stack trace with str value of intspeed.
Browse files Browse the repository at this point in the history
* We should be casting int for comparing interface speeds.
* Add new CI job for latest branch

fixes: #535
Change-Id: Id4748bf76f79d804c9063a8482308eb9447e6b03
  • Loading branch information
sadsfae committed Oct 7, 2024
1 parent 79c56e5 commit 34ecc3e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion container/server/container-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ services:
environment:
SQLALCHEMY_DATABASE_URI: "postgresql://postgres:postgres@quads_db:5432/quads"
volumes:
- /var/lib/jenkins/workspace/Quads-2.1:/opt/quads:z
- /var/lib/jenkins/workspace/QUADS-2.1-Latest:/opt/quads:z
networks:
podman:
ipv4_address: 10.88.0.11
2 changes: 1 addition & 1 deletion src/quads/server/blueprints/interfaces.py
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ def create_interface(hostname: str) -> Response:
return make_response(jsonify(response), 400)

speed = data.get("speed")
if speed and not speed > 0:
if int(speed) and not int(speed) > 0:
response = {
"status_code": 400,
"error": "Bad Request",
Expand Down

0 comments on commit 34ecc3e

Please sign in to comment.