Skip to content

Commit f3940cf

Browse files
Merge pull request microsoft#1031 from Dhruvkumar-Microsoft/psl-TASfeature
fix: Updated the Pylint and test pipeline path and resoved the pylint issues
2 parents 0a313d5 + 82926e3 commit f3940cf

13 files changed

Lines changed: 85 additions & 24 deletions

File tree

.github/requirements.txt

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
fastapi==0.137.1
2+
uvicorn==0.49.0
3+
autogen-agentchat==0.7.5
4+
azure-cosmos==4.16.1
5+
azure-monitor-opentelemetry==1.8.8
6+
azure-monitor-events-extension==0.1.0
7+
azure-identity==1.25.3
8+
python-dotenv==1.2.2
9+
python-multipart==0.0.32
10+
opentelemetry-api==1.40.0
11+
opentelemetry-sdk==1.40.0
12+
opentelemetry-exporter-otlp-proto-grpc==1.40.0
13+
opentelemetry-instrumentation-fastapi==0.61b0
14+
opentelemetry-instrumentation-openai==0.61.0
15+
opentelemetry-exporter-otlp-proto-http==1.40.0
16+
17+
semantic-kernel[azure]==1.32.2
18+
azure-ai-projects==1.0.0b11
19+
openai==1.84.0
20+
azure-ai-inference==1.0.0b9
21+
azure-search-documents==12.1.0b1
22+
azure-ai-evaluation==1.11.0
23+
24+
# Date and internationalization
25+
babel==2.18.0
26+
27+
# Testing tools
28+
pytest==8.4.2 # Compatible version for pytest-asyncio
29+
pytest-asyncio==0.24.0
30+
pytest-cov==5.0.0

.github/workflows/pylint.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ on:
55
paths:
66
- 'src/backend/**/*.py'
77
- 'src/mcp_server/**/*.py'
8-
- 'src/backend/requirements.txt'
8+
- '.github/requirements.txt'
99
- '.flake8'
1010
- '.github/workflows/pylint.yml'
1111

@@ -27,7 +27,7 @@ jobs:
2727
- name: Install dependencies
2828
run: |
2929
python -m pip install --upgrade pip
30-
pip install -r src/backend/requirements.txt
30+
pip install -r .github/requirements.txt
3131
pip install flake8 # Ensure flake8 is installed explicitly
3232
3333
- name: Run flake8 and pylint

.github/workflows/test.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ on:
1313
- 'src/**/pyproject.toml'
1414
- 'pytest.ini'
1515
- 'conftest.py'
16-
- 'src/backend/requirements.txt'
16+
- '.github/requirements.txt'
1717
- '.github/workflows/test.yml'
1818
pull_request:
1919
types:
@@ -31,7 +31,7 @@ on:
3131
- 'src/mcp_server/**/*.py'
3232
- 'pytest.ini'
3333
- 'conftest.py'
34-
- 'src/backend/requirements.txt'
34+
- '.github/requirements.txt'
3535
- 'src/**/pyproject.toml'
3636
- '.github/workflows/test.yml'
3737

@@ -56,7 +56,7 @@ jobs:
5656
- name: Install dependencies
5757
run: |
5858
python -m pip install --upgrade pip
59-
pip install -r src/backend/requirements.txt
59+
pip install -r .github/requirements.txt
6060
6161
- name: Check if test files exist
6262
id: check_tests

azure.yaml

Lines changed: 38 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,42 @@ requiredVersions:
77
hooks:
88
postdeploy:
99
windows:
10-
run: infra/scripts/post_deploy.ps1
10+
run: |
11+
# Detect if running in Git Bash or similar Bash environment
12+
if ($env:SHELL -like "*bash*" -or $env:MSYSTEM) {
13+
# Running in Git Bash/MSYS2 environment
14+
Write-Host ""
15+
Write-Host "===============================================================" -ForegroundColor Yellow
16+
Write-Host " POST-DEPLOYMENT STEPS (Bash)" -ForegroundColor Green
17+
Write-Host "===============================================================" -ForegroundColor Yellow
18+
Write-Host ""
19+
20+
Write-Host " Upload Team Configurations, index sample data and create the Knowledge base from content Packs" -ForegroundColor White
21+
Write-Host " 👉 Run the following command in Bash:" -ForegroundColor White
22+
Write-Host " bash infra/scripts/post_deploy.sh" -ForegroundColor Cyan
23+
Write-Host ""
24+
25+
Write-Host "🌐 Access your deployed Frontend application at:" -ForegroundColor Green
26+
Write-Host " https://$env:webSiteDefaultHostname" -ForegroundColor Cyan
27+
Write-Host ""
28+
} else {
29+
# Running in PowerShell
30+
Write-Host ""
31+
Write-Host "===============================================================" -ForegroundColor Yellow
32+
Write-Host " POST-DEPLOYMENT STEP (PowerShell) " -ForegroundColor Green
33+
Write-Host "===============================================================" -ForegroundColor Yellow
34+
Write-Host ""
35+
36+
Write-Host " Upload Team Configurations, index sample data and create the Knowledge base from content Packs" -ForegroundColor White
37+
Write-Host " 👉 Run the following command in PowerShell:" -ForegroundColor White
38+
Write-Host " infra\scripts\post_deploy.ps1" -ForegroundColor Cyan
39+
Write-Host ""
40+
41+
Write-Host "🌐 Access your deployed Frontend application at:" -ForegroundColor Green
42+
Write-Host " https://$env:webSiteDefaultHostname" -ForegroundColor Cyan
43+
Write-Host ""
44+
}
45+
1146
shell: pwsh
1247
interactive: true
1348
posix:
@@ -23,9 +58,9 @@ hooks:
2358
printf "${Green} POST-DEPLOYMENT STEPS (Bash)\n"
2459
printf "${Yellow}===============================================================${NC}\n\n"
2560
26-
printf "Upload Team Configurations and index sample data:\n"
61+
printf "Upload Team Configurations, index sample data and create the Knowledge base from content Packs:\n"
2762
printf " 👉 Run the following command in Bash:\n"
28-
printf " ${Blue}bash infra/scripts/selecting_team_config_and_data.sh${NC}\n\n"
63+
printf " ${Blue}bash infra/scripts/post_deploy.sh${NC}\n\n"
2964
3065
printf "🌐 Access your deployed Frontend application at:\n"
3166
printf " ${Blue}https://%s${NC}\n\n" "$webSiteDefaultHostname"

src/backend/api/router.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@
1818
rai_validate_team_config)
1919
from fastapi import (APIRouter, BackgroundTasks, File, HTTPException, Query,
2020
Request, UploadFile, WebSocket, WebSocketDisconnect)
21-
from models.messages import WebsocketMessageType
2221
from orchestration.connection_config import (connection_config,
2322
orchestration_config, team_config)
2423
from orchestration.orchestration_manager import OrchestrationManager
@@ -315,7 +314,6 @@ async def process_request(
315314
)
316315
await memory_store.add_plan(plan)
317316

318-
319317
track_event_if_configured(
320318
"Plan_Created",
321319
{
@@ -1430,6 +1428,7 @@ async def get_plan_by_id(
14301428
logging.error(f"Error retrieving plan: {str(e)}")
14311429
raise HTTPException(status_code=500, detail="Internal server error occurred")
14321430

1431+
14331432
@app_router.get("/images/{blob_name:path}")
14341433
async def get_generated_image(blob_name: str):
14351434
"""Proxy a generated image from Azure Blob Storage."""

src/backend/app.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,6 @@
3030
# Azure monitoring
3131

3232

33-
34-
3533
@asynccontextmanager
3634
async def lifespan(app: FastAPI):
3735
"""Manage FastAPI application lifecycle - startup and shutdown."""

src/backend/callbacks/response_handlers.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -145,4 +145,4 @@ async def streaming_agent_response_callback(
145145
)
146146
logger.debug("Streaming chunk (agent=%s final=%s len=%d)", agent_id, is_final, len(cleaned))
147147
except Exception as e:
148-
logger.error("streaming_agent_response_callback error: %s", e)
148+
logger.error("streaming_agent_response_callback error: %s", e)

src/backend/common/models/messages.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
# Enumerations
1515
# ---------------------------------------------------------------------------
1616

17+
1718
class DataType(str, Enum):
1819
session = "session"
1920
plan = "plan"

src/backend/common/utils/agent_utils.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,4 +39,4 @@ async def get_database_team_agent_id(
3939
Exception
4040
) as ex: # Consider narrowing this to specific exceptions if possible
4141
logging.error("Failed to initialize Get database team agent: %s", ex)
42-
return agent_id
42+
return agent_id

src/backend/common/utils/team_utils.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -247,4 +247,4 @@ async def rai_validate_team_config(
247247
return True, ""
248248
except Exception as e:
249249
logging.error("Error validating team configuration content: %s", e)
250-
return False, "Unable to validate team configuration content. Please try again."
250+
return False, "Unable to validate team configuration content. Please try again."

0 commit comments

Comments
 (0)