Граф коммитов

372 Коммитов

Автор SHA1 Сообщение Дата
Jeremy Meng a28e8f0795 [EngSys] move to vendored version of cross-env via dev-tool
***NO_CI***

- apply the transformation

- update samples' README
2024-11-02 00:48:06 +00:00
Jeremy Meng 980f3cbb89 [EngSys] move `uglify-js` to dev-tool vendored
- add dep to `uglify-js` in dev-tool

- rush update

- replace "uglifyjs" with "dev-tool run vendored yglifyjs"

- remove dependency to "uglifyjs" in sdk packages

***NO_CI***
2024-10-30 18:01:20 +00:00
Jeremy Meng 6a2c7300eb [eslint-plugin] add rule "@typescript-eslint/consistent-type-imports": "warn"
- apply lint:fix results

- revert fixes that are not related to consistent-type-imports and cases error

- regenerate .api.md files

- format

- update core-comparison diff
2024-10-30 15:48:52 +00:00
Jeremy Meng 1cae9db8e1 [EngSys] remove "audit" NPM script and it's related file
as we no longer use it and rely on GitHub security features.

***NO_CI***
2024-10-25 19:28:06 +00:00
Jeremy Meng 59bb0809ba [EngSys] use vendored version of `mkdirp` and `rimraf` from dev-tool
also remove dependency on `@microsoft/api-extractor` as we already move to
`dev-tool run extract-api` which calls api-extractor Api instead.

***NO_CI***
2024-10-23 17:53:07 +00:00
Wes Haggard 1c50b6ac49
Switch to TME test subscription (#31329) 2024-10-14 18:19:12 -07:00
Jeremy Meng 652a7ffa89 [eslint-plugin] fix ts-naming-options rule issue
***NO_CI***

Currently the rule only handles the case of

```ts
  clientMethod(options: MethodOptions) {}
```

but not when the options bag parameter has a default value

```ts
  clientMethod(options: MethodOptions = {}) {}
```

This change adds code to handle the latter.

- Add two unit tests

- Update the affected packages to suppress this rule as a warning

- react to the fix
2024-10-02 16:40:01 +00:00
Matthew Podwysocki 61c8b9aae4 [EngSys] Add update-snippets to all package.json files ***NO_CI*** 2024-09-26 17:59:37 +00:00
Daniel Getu 3398d73db5
[Search] Regenerate with 2024-09-01-preview spec (#31133) 2024-09-24 23:34:03 -07:00
Jeremy Meng 4cd2a59317
[EngSys] fix formatting (#31181)
This is the result of `rush format`, correcting several formatting issues introduced in the last NO_CI commit.
2024-09-20 16:19:37 -07:00
Jeremy Meng a7b3656a05 [EngSys] upgrade dev dependency `typescript` version to `~5.6.2`
***NO_CI***

- replace version to "~5.6.2"
- rush update
- add `"skipLibCheck": true` for several packages that are affected by https://github.com/vitest-dev/vitest/issues/4688

- [formrecognizer] help TypeScript to understand with more explicit type

- [schema-registry-{avro,json}] skip lib check due to lru-cache issue with the Iterator TReturn change

https://github.com/isaacs/node-lru-cache/issues/348
2024-09-19 18:07:31 -07:00
Jeremy Meng d5f6d677ec [EngSys] standardize OSS copyright header
- [eslint-plugin] github-source-headers rule should use "MIT License".

  This change updates our linter rule and the whole repository to have consistent
  license header.

***NO_CI***

- remove "All rights reserved." from header

- "MIT license" => "MIT License"
2024-08-27 13:01:38 -07:00
Jeremy Meng f04044e34e [eslint] remove ESLINT_USE_FLAT_CONFIG=true env variable
now that we have moved to eslint v9.

***NO_CI***
2024-08-26 12:52:48 -07:00
Jeremy Meng 5adb09d715 [engsys] upgrade dev dependency eslint to v9
***NO_CI***

- bump eslint version to ^9.9.0
- [eslint-plugin] remove eslint-plugin-import for now. Will re-visit until it supports eslint v9
2024-08-23 16:37:40 -07:00
Jeremy Meng 2ce3c5feb4 [eslint-plugin] upgrade typescript-eslint to v8
***NO_CI***

- bump typescript-eslint dependencies version to ~8.2.0

- [eslint-plugin] suppress new linting errors appearing with v8

- [eslint-plugin] react to removed typescript-eslint property

  related PR https://github.com/typescript-eslint/typescript-eslint/pull/9025

- [eslint-plugin] turn off @typescript-eslint/no-unused-expressions

  as no-unused-expressions is already reported by eslint

- [dev-tool] fix new linting errors

- Remove @typescript-eslint/ban-types that no longer exists

  and replace with more specific rules wherever applicable.

- [cosmosdb] combine the test eslint config with the main one

- delete catch expression when caught error is not used

- fix or suppress linting errors in code files
2024-08-23 10:19:23 -07:00
Deyaaeldeen Almahallawi b3bc86566d
[Search] Migrate to Bicep (#30855)
And update API versions

Live tests run:
https://dev.azure.com/azure-sdk/internal/_build/results?buildId=4070243&view=results
2024-08-21 21:22:06 -07:00
Jeremy Meng 6ea3729026
[eslint] fix linting issues for several packages (#30826)
These would appear once we moved to eslint flat config. They are not
detected
currently likely due to incorrect configurations.

- Remove TextEncoder/TextDecoder declarations as they are in global
scope on our
supported platforms

- Remove URL imports as they are in global scope on our supported
platforms.

- remove --ext from linting NPM scripts

- Fix issues linting README.md files

- Suppress error about crypto. The feature of adding it to global scope
is still experimental

- Fix build error in attestation. Neither browsers nor NodeJS has a
constructor parameter for TextEncoder

-
https://developer.mozilla.org/en-US/docs/Web/API/TextEncoder/TextEncoder

-
https://nodejs.org/docs/latest-v18.x/api/util.html#class-utiltextencoder
2024-08-21 14:01:39 -07:00
Jeremy Meng 405c244bb1 [linting] move perf tests to use eslint flat config
***NO_CI***

- add one flat config file for perf tests

- update NPM scripts of these packages to use that flat config for perf tests

  As eslint v8 still not switched to flat config by default, this change
  temporarily uses `cross-env` to set `ESLINT_USE_FLAT_CONFIG=true`

  Once we moved to eslint v9 the env var can be removed.
2024-08-15 10:56:56 -07:00
Azure SDK Bot 3fc97bba2c
Post release automated changes for search releases
<p dir="auto">Post release automated changes for azure-arm-search</p>
2024-07-29 11:05:39 -07:00
Ben Broderick Phillips 73193a2bab
Default to sub config file paths/svc connection for public + sovereign live tests (#30530)
This doesn't cover the many files still using secret sub configs with
custom principals, those will be migrated separately. This changes the
defaults to use file-based sub configs and service connections
everywhere else. It is intended to be merged after/alongside federated
auth mode becoming the default.

Relies on https://github.com/Azure/azure-sdk-tools/pull/8680
2024-07-25 16:07:48 -04:00
ZiWei Chen df7179214d
[mgmt] search release (#30014)
https://github.com/Azure/sdk-release-request/issues/5244
2024-07-25 18:37:17 +08:00
Daniel Getu 8ab8edad25
[Search] Merge samples and changelog for 2024-07 GA release (#30514)
### Packages impacted by this PR

@azure/search-documents

### Describe the problem that is addressed by this PR

Adds sample and changelog changes from the GA branch for 2024-07 release
#30494

### Checklists
- [x] Added impacted package name to the issue description
2024-07-24 08:19:53 -07:00
Jeremy Meng 3a68e456b2 [Samples] update "src/**.ts" to "src/**/*.ts" in tsconfig.json
Previously dev-tool has been fixed to generate correct include path in samples
tsconfig.json but samples were not updated.

This PR fixes the samples tsconfig.json in one run; otherwise with the recent
branch protection policy changes, when individual packages re-publish samples,
js-core team would have to approve the tsconfig.json changes.

***NO_CI***
2024-07-24 13:53:00 +00:00
Deyaaeldeen Almahallawi fe595c963c
[OpenAI] Add companion library (#30467)
WIP

---------

Co-authored-by: Minh-Anh Phan <minhanhphan@microsoft.com>
Co-authored-by: Minh-Anh Phan <111523473+minhanh-phan@users.noreply.github.com>
2024-07-22 16:57:28 -07:00
Jeremy Meng b93b62368b [EngSys] remove tsconfig.package.json
which only extends from tsconfig.json.  There might be more customization for
packages in the early days but not any more.

This PR removes it and updates packages to extends tsconfig.json directly

***NO_CI***
2024-07-16 13:27:25 +00:00
Jeremy Meng 1a09f43108 [EngSys] upgrade dev dependency `typescript` version to `~5.5.3`
***NO_CI***

- also include *.api.md updates due to the following TypeScript 5.5 change

https://www.typescriptlang.org/docs/handbook/release-notes/typescript-5-5.html#simplified-reference-directive-declaration-emit
2024-07-03 22:24:35 +00:00
Jeremy Meng 74dfa883b9 [EngSys] upgrade dep dependency `nyc` to ^17.0.0
***NO_CI***
2024-06-28 17:57:40 +00:00
Maor Leger 2e040fae8a Bump @azure/identity to 4.2.1 in samples ***NO_CI*** 2024-06-11 14:01:31 -07:00
Daniel Getu 9bacb64c14
[Search] Regenerate with 2024-05-01-preview spec (#29594) 2024-05-20 20:03:00 +00:00
Daniel Getu 357fd3ae00
[Search] Fix serialization performance issue (#29597) 2024-05-20 19:08:31 +00:00
Daniel Getu 6740f43da5
[Search] Refactor tests (#29595) 2024-05-20 17:57:46 +00:00
Daniel Getu b8d84c6442
[Search] Enable vector compression tests (#29596) 2024-05-10 10:12:47 -07:00
Daniel Getu ad24dc2cd8
[Search] Fix incorrectly generated enum variant name (#29601) 2024-05-09 15:32:02 -07:00
Daniel Getu 4c53b599a0
[Search] Miscellaneous small fixups (#29600) 2024-05-09 22:28:04 +00:00
Matthew Podwysocki cd3cf2e03e [EngSys] Update version of @azure-tools/test-utils ***NO_CI*** 2024-05-08 11:54:46 -07:00
Daniel Getu 395fd7e50e
[Search] Fix documentation for preview client (#29598) 2024-05-07 13:54:24 -07:00
Minh-Anh Phan c6e3c1fba7
[OpenAI] Add a specific OpenAI error model (#29135)
### Packages impacted by this PR
@azure/openai
@azure/openai-assistants
@azure/search-documents

### Issues associated with this PR
#29011

### Describe the problem that is addressed by this PR
Create an error model to represent OpenAI error shape. Update search, openai, openai assistants recordings

### What are the possible designs available to address the problem? If
there are more than one possible design, why was the one in this PR
chosen?


### Are there test cases added in this PR? _(If not, why?)_


### Provide a list of related PRs _(if any)_


### Command used to generate this PR:**_(Applicable only to SDK release
request PRs)_

### Checklists
- [ ] Added impacted package name to the issue description
- [ ] Does this PR needs any fixes in the SDK Generator?** _(If so,
create an Issue in the
[Autorest/typescript](https://github.com/Azure/autorest.typescript)
repository and link it here)_
- [ ] Added a changelog (if necessary)
2024-04-26 10:08:19 -07:00
Matthew Podwysocki 769c1b126e [EngSys] Update name of @azure-tools/test-utils ***NO_CI*** 2024-04-25 13:14:33 -07:00
Jeremy Meng e9561c1a52 [EngSys] back to use `nyc` for code coverage
now that we removed `esm` dependency, `nyc` should be working again, and `nyc`
appears to have better results than `c8` does.

***NO_CI***
2024-04-19 12:19:32 -07:00
Maor Leger 224f7c1c14 [EngSys] Migrate to dev-tool extract-api ***NO_CI*** 2024-04-19 18:13:41 +00:00
Maor Leger 446e9d831b [EngSys] Remove ESM dependency ***NO_CI*** 2024-04-19 15:45:48 +00:00
Minh-Anh Phan 7f9b182c4c
[OpenAI] Update documentation (#29323)
### Packages impacted by this PR


### Issues associated with this PR
#28445 #29259

### Describe the problem that is addressed by this PR
- Update README with correct BYOD example. 
- Update sample with path to audio file
- Update changelog with latest changes
- Update post release version bump
- Update function call sample to tool call
2024-04-18 17:46:50 -07:00
Jeremy Meng ffe81c5bcf [EngSys] upgrade dev dependency `mkdirp` to `^3.0.1`
***NO_CI***
2024-04-15 11:27:58 -07:00
Jeremy Meng 398494acd8 [EngSys] upgrade dev dependency `typescript` to `~5.4.5`
The only package that still stays on ~5.3.3 is search-document (tracked by issue #29283)

***NO_CI***
2024-04-11 23:19:38 +00:00
Azure SDK Bot a1fd92eb3c
Post release automated changes for search releases (#29008)
Post release automated changes for azure-arm-search
2024-04-10 21:04:51 +00:00
Minh-Anh Phan dea68e5854
[OpenAI] Update to 2024-03-01-preview API (#28991)
### Packages impacted by this PR
@azure/openai

### Issues associated with this PR


### Describe the problem that is addressed by this PR
Update the current package to the latest 2024-03-01-preview API. Refer
to Changelog for the full list of changes, including added features for
embeddings (dimensions), breaking changes for
bring your own data (change to snake casing, etc), support for log
probabilities, and more.

Co-authored-by: Daniel <danielgetu@microsoft.com>
Co-authored-by: Deyaaeldeen Almahallawi <dealmaha@microsoft.com>
2024-03-29 14:31:56 -07:00
Maor Leger d7173879bf [EngSys] C8 major version update ***NO_CI*** 2024-03-22 13:26:43 -05:00
Harsha Nalluru 8d3374a81a
[Perf] Make perf package public for consumption outside this repo (#28916)
### Packages impacted by this PR
`@azure-tools/test-perf`

### Describe the problem that is addressed by this PR
Making perf package public for consumption outside this repo.
This marks the initial release of the `@azure-tools/test-perf` library
to npm, providing a robust test utility framework that assists with the
performance testing of Azure SDKs for JS/TS.

### Key Concepts

1. **Introduction of PerfTest**: A test utility designed to execute
performance and stress tests for Azure SDK for JavaScript packages.
2. **Test Execution**: Tests are run asynchronously, influenced by
parameters like duration, iterations, and parallelism.
3. **Command Line Parameters**: Utilizes `minimist` for parsing command
line options into a `PerfOptionDictionary<string>` for test
configuration.
4. **Default Options**: Includes standard parameters such as `help`,
`no-cleanups`, `parallel`, `duration`, `warmup`, `iterations`,
`no-cleanup`, and `milliseconds-to-log`.
5. **Test Lifecycle**: Tests run repeatedly within the specified
`duration` and `iterations`, with a `warmup` period for runtime
optimization.
6. **Setup and Cleanup**: Features `globalSetup`/`globalCleanup` methods
for CPU-level preparation and `setup`/`cleanup` methods for
instance-specific state management.
2024-03-19 10:05:34 +00:00
ZiWei Chen 9b6fc5d15e
[mgmt] search release (#28886)
https://github.com/Azure/sdk-release-request/issues/5005
2024-03-19 14:40:11 +08:00
Daniel Getu d738efb7e2
[Search] Regenerate with 2024-03-01-Preview spec (#28576) 2024-03-17 06:59:30 +00:00