Skip to content

Instantly share code, notes, and snippets.

View msyyc's full-sized avatar

Yuchao Yan msyyc

  • Microsoft
  • Shanghai, China
View GitHub Profile

This issue is to collect some cases during typespec migration which could be referred by dev or bot so that we could reduce effort for typespec migration in the future.

IMPORTANT:

  • Each dev has a comment to contribute your case which may cost you much and may be useful you think for others to refer to
  • Each case contains short description and one commit
  • The commit shall focus on one specific scenario including tyepsec change and related swagger change (e.g. here)
  • If you find the case is out of date, left the reason then deprecate it like: missing location: commit-id (it is out of date)
@msyyc
msyyc / MPG-LRO.md
Last active December 25, 2023 05:13
@msyyc
msyyc / form_data_design.md
Last active December 13, 2023 01:58
"multipart/form-data" design for Python SDK (Only for DPG model)

Typespec

For the following Typespec definition about "multipart/form-data":

...
model MultiPartRequest {
  id: string;
  profileImage: bytes;
}
@msyyc
msyyc / changelog.md
Last active September 22, 2023 07:20
How to generate SDK changelog

Follow the following steps to generate SDK changelog:

  1. Prepare environment (only need once)
(venv-dev) PS D:\dev\azure-sdk-for-python> python .\scripts\dev_setup.py -p azure-core
  1. Generate code report for last release
(venv-dev) PS D:\dev\azure-sdk-for-python> python -m packaging_tools.code_report --last-pypi azure-mgmt-rdbms
@msyyc
msyyc / multi_client_package_version.md
Created June 22, 2022 10:48
Design to solve version problem in multi client package

Problem

For multi client configuration(like azure-purview-administration), current python codegen does not generate _version.py in package folder which is needed by setup.py. What's worse, customers need to edit the file manually to update version number before they release package which is very inconvenient.

Solution

To solve the problem, we need new Plugin in python codegen. The new Plugin will generate necessary files(_version.py, etc) for multi client package. Customers will configure like:

image