Skip to content

Commit

Permalink
Merge branch 'master' into upgrade-api-server-dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
bisgaard-itis committed Dec 10, 2024
2 parents 92dc0b0 + e9bc718 commit a3be13e
Show file tree
Hide file tree
Showing 7 changed files with 35 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ class CreditClassification(StrAutoEnum):

class PricingPlanClassification(StrAutoEnum):
TIER = auto()
LICENSE = auto()


class PricingInfo(BaseModel):
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
"""add LICENSE type to pricing plan
Revision ID: 4d007819e61a
Revises: 38c9ac332c58
Create Date: 2024-12-09 14:25:45.024814+00:00
"""
import sqlalchemy as sa
from alembic import op

# revision identifiers, used by Alembic.
revision = "4d007819e61a"
down_revision = "38c9ac332c58"
branch_labels = None
depends_on = None


def upgrade():
op.execute(sa.DDL("ALTER TYPE pricingplanclassification ADD VALUE 'LICENSE'"))


def downgrade():
# ### commands auto generated by Alembic - please adjust! ###
pass
# ### end Alembic commands ###
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ class PricingPlanClassification(str, enum.Enum):
"""

TIER = "TIER"
LICENSE = "LICENSE"


resource_tracker_pricing_plans = sa.Table(
Expand Down
3 changes: 2 additions & 1 deletion services/api-server/openapi.json
Original file line number Diff line number Diff line change
Expand Up @@ -6469,7 +6469,8 @@
"PricingPlanClassification": {
"type": "string",
"enum": [
"TIER"
"TIER",
"LICENSE"
],
"title": "PricingPlanClassification"
},
Expand Down
3 changes: 2 additions & 1 deletion services/resource-usage-tracker/openapi.json
Original file line number Diff line number Diff line change
Expand Up @@ -378,7 +378,8 @@
"PricingPlanClassification": {
"type": "string",
"enum": [
"TIER"
"TIER",
"LICENSE"
],
"title": "PricingPlanClassification"
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11432,6 +11432,7 @@ components:
type: string
enum:
- TIER
- LICENSE
title: PricingPlanClassification
PricingPlanToServiceAdminGet:
properties:
Expand Down
5 changes: 3 additions & 2 deletions services/web/server/tests/unit/isolated/test_tracing.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,15 @@
def mock_webserver_service_environment(
monkeypatch: pytest.MonkeyPatch, mock_webserver_service_environment: EnvVarsDict
) -> EnvVarsDict:

return mock_webserver_service_environment | setenvs_from_dict(
monkeypatch.delenv("WEBSERVER_TRACING")
envs = mock_webserver_service_environment | setenvs_from_dict(
monkeypatch,
{
"TRACING_OPENTELEMETRY_COLLECTOR_ENDPOINT": "http://opentelemetry-collector",
"TRACING_OPENTELEMETRY_COLLECTOR_PORT": "4318",
},
)
return envs


def test_middleware_restrictions_opentelemetry_is_second_middleware(
Expand Down

0 comments on commit a3be13e

Please sign in to comment.