Skip to content

Commit

Permalink
merge with main, address conflicts
Browse files Browse the repository at this point in the history
  • Loading branch information
awharrison-28 committed Jul 17, 2023
2 parents 9dc1234 + 5721ac4 commit 8ff3d76
Show file tree
Hide file tree
Showing 725 changed files with 31,779 additions and 19,885 deletions.
19 changes: 19 additions & 0 deletions .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# @microsoft/octo-semantickernel-pr-dotnet owns any files in the dotnet
# directory at the root of the repository and any of its
# subdirectories.
/dotnet/ @microsoft/octo-semantickernel-pr-dotnet

# @microsoft/octo-semantickernel-pr-python owns any files in the python
# directory at the root of the repository and any of its
# subdirectories.
/python/ @microsoft/octo-semantickernel-pr-python

# @microsoft/octo-semantickernel-pr-python owns any files in the java
# directory at the root of the repository and any of its
# subdirectories.
/java/ @microsoft/octo-semantickernel-pr-java

# @microsoft/octo-semantickernel-pr-apps owns any files in the samples
# directory at the root of the repository and any of its
# subdirectories.
/samples/ @microsoft/octo-semantickernel-pr-apps
9 changes: 5 additions & 4 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,11 @@ A clear and concise description of what you expected to happen.
**Screenshots**
If applicable, add screenshots to help explain your problem.

**Desktop (please complete the following information):**
- OS: [e.g. Windows]
**Platform**
- OS: [e.g. Windows, Mac]
- IDE: [e.g. Visual Studio, VS Code]
- NuGet Package Version [e.g. 0.1.0]
- Language: [e.g. C#, Python]
- Source: [e.g. NuGet package version 0.1.0, pip package version 0.1.0, main branch of repository]

**Additional context**
Add any other context about the problem here.
Add any other context about the problem here.
43 changes: 36 additions & 7 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,34 +5,63 @@

version: 2
updates:
# Maintain dependencies for nuget
- package-ecosystem: "nuget"
directory: "samples/apps/copilot-chat-app/webapi"
schedule:
interval: "weekly"
day: "monday"
labels:
- "copilot chat"
- "dependencies"

# Maintain dependencies for nuget
- package-ecosystem: "nuget"
directory: "dotnet/"
schedule:
interval: "daily"
interval: "weekly"
day: "monday"
ignore:
# For all System.* and Microsoft.Extensions/Bcl.* packages, ignore all major version updates
- dependency-name: "System.*"
update-types: ["version-update:semver-major"]
- dependency-name: "Microsoft.Extensions.*"
update-types: ["version-update:semver-major"]
- dependency-name: "Microsoft.Bcl.*"
update-types: ["version-update:semver-major"]
labels:
- ".NET"
- "dependencies"

# Maintain dependencies for nuget
- package-ecosystem: "nuget"
directory: "samples/"
directory: "samples/dotnet"
schedule:
interval: "daily"

interval: "weekly"
day: "monday"

# Maintain dependencies for npm
- package-ecosystem: "npm"
directory: "samples/apps"
schedule:
interval: "daily"
interval: "weekly"
day: "monday"

# Maintain dependencies for pip
- package-ecosystem: "pip"
directory: "python/"
schedule:
interval: "daily"
interval: "weekly"
day: "monday"
labels:
- "python"
- "dependencies"

# Maintain dependencies for github-actions
- package-ecosystem: "github-actions"
# Workflow files stored in the
# default location of `.github/workflows`
directory: "/"
schedule:
interval: "daily"
interval: "weekly"
day: "monday"
31 changes: 24 additions & 7 deletions .github/labeler.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
# Add 'kernel' label to any change within Connectors, Extensions, Skills, and tests directories
kernel:
- "dotnet/src/Connectors/**/*"
- "dotnet/src/Extensions/**/*"
- "dotnet/src/Skills/**/*"
- "dotnet/src/IntegrationTests/**/*"
- "dotnet/src/SemanticKernel.UnitTests/**/*"
- dotnet/src/Connectors/**/*
- dotnet/src/Extensions/**/*
- dotnet/src/Skills/**/*
- dotnet/src/IntegrationTests/**/*
- dotnet/src/SemanticKernel.UnitTests/**/*

# Add 'kernel.core' label to any change within the 'SemanticKernel', 'SemanticKernel.Abstractions', or 'SemanticKernel.MetaPackage' directories
kernel.core:
Expand All @@ -16,11 +16,28 @@ kernel.core:
python:
- python/**/*

# Add 'java' label to any change within the 'java' directory
java:
- java/**/*

# Add 'samples' label to any change within the 'samples' directory
samples:
- samples/**/*

# Add '.NET' label to any change within samples or kernel 'dotnet' directories.
.NET:
- dotnet/src/**/*
- samples/**/dotnet/**/*
- dotnet/**/*

# Add 'copilot chat' label to any change within the 'samples/apps/copilot-chat-app' directory
copilot chat:
- samples/apps/copilot-chat-app/**/*

# Add 'documentation' label to any change within the 'docs' directory, or any '.md' files
documentation:
- docs/**/*
- '**/*.md'

# Add 'memory' label to any memory connectors in dotnet/ or python/
memory:
- dotnet/src/Connectors/Connectors.Memory.*/**/*
- python/semantic_kernel/connectors/memory/**/*
9 changes: 5 additions & 4 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
### Motivation and Context

<!-- Thank you for your contribution to the semantic-kernel repo!
Please help reviewers and future users, providing the following information:
1. Why is this change required?
Expand All @@ -7,16 +8,16 @@ Please help reviewers and future users, providing the following information:
4. If it fixes an open issue, please link to the issue here.
-->


### Description

<!-- Describe your changes, the overall approach, the underlying design.
These notes will help understanding how your code works. Thanks! -->


### Contribution Checklist

<!-- Before submitting this PR, please make sure: -->

- [ ] The code builds clean without any errors or warnings
- [ ] The PR follows SK Contribution Guidelines (https://github.com/microsoft/semantic-kernel/blob/main/CONTRIBUTING.md)
- [ ] The code follows the .NET coding conventions (https://learn.microsoft.com/dotnet/csharp/fundamentals/coding-style/coding-conventions) verified with `dotnet format`
- [ ] The PR follows the [SK Contribution Guidelines](https://github.com/microsoft/semantic-kernel/blob/main/CONTRIBUTING.md) and the [pre-submission formatting script](https://github.com/microsoft/semantic-kernel/blob/main/CONTRIBUTING.md#dev-scripts) raises no violations
- [ ] All unit tests pass, and I have added new tests where possible
- [ ] I didn't break anyone :smile:
59 changes: 59 additions & 0 deletions .github/workflows/copilot-chat-package.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
#
# This workflow will package the Copilot Chat application for deployment.
#

name: copilot-chat-package

on:
pull_request:
branches: [ "main", "feature*" ]
paths:
- 'samples/apps/copilot-chat-app/**'
push:
branches: [ "main", "feature*" ]
paths:
- 'samples/apps/copilot-chat-app/**'

concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true

permissions:
contents: read

jobs:
build:
strategy:
fail-fast: false
matrix:
include:
- { dotnet: '6.0', configuration: Release, os: ubuntu-latest }

runs-on: ${{ matrix.os }}
env:
NUGET_CERT_REVOCATION_MODE: offline
steps:
- uses: actions/checkout@v3
with:
clean: true

- name: Pull container dotnet/sdk:${{ matrix.dotnet }}
run: docker pull mcr.microsoft.com/dotnet/sdk:${{ matrix.dotnet }}

- name: Package Copilot Chat WebAPI
run: |
chmod +x $(pwd)/samples/apps/copilot-chat-app/deploy/package-webapi.sh;
docker run --rm -v $(pwd):/app -w /app -e GITHUB_ACTIONS='true' mcr.microsoft.com/dotnet/sdk:${{ matrix.dotnet }} /bin/sh -c "/app/samples/apps/copilot-chat-app/deploy/package-webapi.sh --no-zip";
- name: Set version tag
id: versiontag
run: |
VERSION_TAG="$(date +'%Y%m%d').${{ github.run_number }}.${{ github.run_attempt }}"
echo $VERSION_TAG
echo "versiontag=$VERSION_TAG" >> $GITHUB_OUTPUT
- name: Upload package to artifacts
uses: actions/upload-artifact@v3
with:
name: copilotchat-webapi-${{ steps.versiontag.outputs.versiontag }}
path: ./samples/apps/copilot-chat-app/deploy/publish
131 changes: 71 additions & 60 deletions .github/workflows/copilot-chat-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ name: Copilot Chat Tests
on:
workflow_dispatch:
push:
branches: [ "main", "feature*" ]
paths:
- 'samples/apps/copilot-chat-app/**'
branches: ["main"]
paths:
- "samples/apps/copilot-chat-app/**"

permissions:
contents: read
Expand All @@ -17,70 +17,81 @@ jobs:
runs-on: ubuntu-latest
timeout-minutes: 30
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v3

- uses: actions/setup-node@v3
with:
node-version: 16
cache-dependency-path: samples/apps/copilot-chat-app/webapp/yarn.lock
cache: 'yarn'
- uses: actions/setup-node@v3
with:
node-version: 16
cache-dependency-path: samples/apps/copilot-chat-app/webapp/yarn.lock
cache: "yarn"

- name: Setup .NET
uses: actions/setup-dotnet@v3
with:
dotnet-version: 6.0.x
- name: Setup .NET
uses: actions/setup-dotnet@v3
with:
dotnet-version: 6.0.x

- name: Install dependencies
run: yarn install
- name: Install dependencies
run: yarn install

- name: Install Playwright Browsers
run: yarn playwright install --with-deps
- name: Install Playwright Browsers
run: yarn playwright install --with-deps

- name: Update AIService configuration
working-directory: samples/apps/copilot-chat-app/webapi
env:
AzureOpenAI__ApiKey: ${{ secrets.AZUREOPENAI__APIKEY }}
AzureOpenAI__Endpoint: ${{ secrets.AZUREOPENAI__ENDPOINT }}
run: |
dotnet dev-certs https
dotnet user-secrets set "AIService:Key" "$AzureOpenAI__ApiKey"
dotnet user-secrets set "AIService:Endpoint" "$AzureOpenAI__Endpoint"
- name: Update AIService configuration
working-directory: samples/apps/copilot-chat-app/webapi
env:
AzureOpenAI__ApiKey: ${{ secrets.AZUREOPENAI__APIKEY }}
AzureOpenAI__Endpoint: ${{ secrets.AZUREOPENAI__ENDPOINT }}
run: |
dotnet dev-certs https
dotnet user-secrets set "AIService:Key" "$AzureOpenAI__ApiKey"
dotnet user-secrets set "AIService:Endpoint" "$AzureOpenAI__Endpoint"
- name: Start service in background
working-directory: samples/apps/copilot-chat-app/webapi
run: |
dotnet run > service-log.txt 2>&1 &
for attempt in {0..20}; do
jobs
echo 'Waiting for service to start...';
if curl -k https://localhost:40443/healthz; then
echo;
echo 'Service started';
break;
fi;
- name: Start service in background
working-directory: samples/apps/copilot-chat-app/webapi
run: |
dotnet run > service-log.txt 2>&1 &
for attempt in {0..20}; do
jobs
echo 'Waiting for service to start...';
if curl -k https://localhost:40443/healthz; then
echo;
echo 'Service started';
break;
fi;
sleep 5;
done
sleep 5;
done
- name: Run Playwright tests
env:
REACT_APP_BACKEND_URI: https://localhost:40443/
REACT_APP_AAD_CLIENT_ID: ${{ secrets.COPILOT_CHAT_REACT_APP_AAD_CLIENT_ID }}
REACT_APP_AAD_AUTHORITY: https://login.microsoftonline.com/common
REACT_APP_TEST_USER_ACCOUNT: ${{ secrets.COPILOT_CHAT_TEST_USER_ACCOUNT }}
REACT_APP_TEST_USER_PASSWORD: ${{ secrets.COPILOT_CHAT_TEST_USER_PASSWORD }}
run: yarn playwright test
- name: Run Playwright tests
env:
REACT_APP_BACKEND_URI: https://localhost:40443/
REACT_APP_AAD_CLIENT_ID: ${{ secrets.COPILOT_CHAT_REACT_APP_AAD_CLIENT_ID }}
REACT_APP_AAD_AUTHORITY: https://login.microsoftonline.com/common

- uses: actions/upload-artifact@v3
if: always()
with:
name: playwright-report
path: samples/apps/copilot-chat-app/webapp/playwright-report/
retention-days: 30
REACT_APP_TEST_USER_ACCOUNT1: ${{ secrets.COPILOT_CHAT_TEST_USER_ACCOUNT1 }}
REACT_APP_TEST_USER_PASSWORD1: ${{ secrets.COPILOT_CHAT_TEST_USER_PASSWORD1 }}
REACT_APP_TEST_USER_ACCOUNT2: ${{ secrets.COPILOT_CHAT_TEST_USER_ACCOUNT2 }}
REACT_APP_TEST_USER_PASSWORD2: ${{ secrets.COPILOT_CHAT_TEST_USER_PASSWORD2 }}

- uses: actions/upload-artifact@v3
if: always()
with:
name: service-log
path: samples/apps/copilot-chat-app/webapi/service-log.txt
retention-days: 30
REACT_APP_TEST_JIRA_EMAIL: ${{ secrets.COPILOT_CHAT_TEST_JIRA_EMAIL }}
REACT_APP_TEST_JIRA_ACCESS_TOKEN: ${{ secrets.COPILOT_CHAT_TEST_JIRA_ACCESS_TOKEN }}
REACT_APP_TEST_JIRA_SERVER_URL: ${{ secrets.COPILOT_CHAT_TEST_JIRA_SERVER_URL }}

REACT_APP_TEST_GITHUB_ACCESS_TOKEN: ${{ secrets.GITHUB_TOKEN }}
REACT_APP_TEST_GITHUB_ACCOUNT_OWNER: ${{ secrets.COPILOT_CHAT_TEST_GITHUB_ACCOUNT_OWNER }}
REACT_APP_TEST_GITHUB_REPOSITORY_NAME: ${{ secrets.COPILOT_CHAT_TEST_GITHUB_REPOSITORY_NAME }}
run: yarn playwright test

- uses: actions/upload-artifact@v3
if: always()
with:
name: playwright-report
path: samples/apps/copilot-chat-app/webapp/playwright-report/
retention-days: 30

- uses: actions/upload-artifact@v3
if: always()
with:
name: service-log
path: samples/apps/copilot-chat-app/webapi/service-log.txt
retention-days: 30
Loading

0 comments on commit 8ff3d76

Please sign in to comment.