Skip to content

Commit a4bb978

Browse files
authored
Merge branch 'main' into fix-17107-allowmultiple-inherited-csharp
2 parents c08bf2d + 1dd1db0 commit a4bb978

682 files changed

Lines changed: 21682 additions & 18582 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.config/service-branch-merge.json

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,18 @@
1616
"release/dev18.0": {
1717
"MergeToBranch": "main",
1818
"ExtraSwitches": "-QuietComments"
19+
},
20+
"main": {
21+
"MergeToBranch": "feature/net11-scouting",
22+
"ExtraSwitches": "-QuietComments",
23+
"ResetToTargetPaths": [
24+
"global.json",
25+
"eng/Version.Details.xml",
26+
"eng/Version.Details.props",
27+
"eng/Versions.props",
28+
"eng/common/**",
29+
"eng/TargetFrameworks.props"
30+
]
1931
}
2032
}
2133
}

.gitattributes

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,10 @@
99
*.fsproj text merge=union
1010
*.dbproj text merge=union
1111

12+
# Release notes are append-only unordered lists; union merge avoids conflicts
13+
# when multiple PRs each add an entry under the same heading.
14+
docs/release-notes/**/*.md text merge=union
15+
1216
# Standard to msysgit
1317
*.doc diff=astextplain
1418
*.DOC diff=astextplain
Lines changed: 169 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,169 @@
1+
---
2+
name: F# Release Announcement
3+
description: Craft F# release announcements for .NET preview/release milestones by tracing SDK→VMR→dotnet/fsharp commit ranges, analyzing release notes, PRs, and issues, then producing a markdown article.
4+
---
5+
6+
# 0. Resolve SDK branch names
7+
8+
User provides only a target release name (e.g., ".NET 11 Preview 2"). Derive everything else.
9+
10+
```bash
11+
# List all release branches in dotnet/sdk
12+
gh api repos/dotnet/sdk/branches --paginate -q '.[].name' | grep '^release/' | sort -V
13+
```
14+
15+
Branch naming pattern: `release/<major>.0.<band>xx-preview<N>` or `release/<major>.0.<band>xx`
16+
17+
From the listing, identify:
18+
1. **Target branch**: match release name to branch (e.g., ".NET 11 Preview 2" → `release/11.0.1xx-preview2`)
19+
2. **Previous branch**: prior preview or prior milestone (e.g., preview1 for preview2, or last stable for preview1)
20+
3. **Parallel stable branch**: highest `<major-1>.0.Xxx` branch (for exclusivity check)
21+
22+
# 1. Fetch previous announcement — DO NOT REPEAT
23+
24+
```
25+
gh api repos/dotnet/core/contents/release-notes -q '.[].name'
26+
```
27+
28+
Navigate to latest published `fsharp.md` under `release-notes/<major>/preview/*/`. Fetch it. Every item in it is excluded from output.
29+
30+
# 2. Resolve F# commit range
31+
32+
**CRITICAL**: Use SDK, not VMR branch. VMR branch may have newer F# than what SDK locked in.
33+
34+
### Get F# end commit (target release)
35+
36+
```
37+
# 1. SDK → VMR hash (find the Dependency for Microsoft.FSharp.Compiler, extract its Sha)
38+
gh api repos/dotnet/sdk/contents/eng/Version.Details.xml?ref=release/11.0.1xx-preview2 | jq -r '.content' | base64 -d | grep -A2 'Microsoft.FSharp.Compiler' | grep Sha | sed 's/.*>\([a-f0-9]*\)<.*/\1/'
39+
# Result: VMR_HASH
40+
41+
# 2. VMR → F# hash
42+
gh api repos/dotnet/dotnet/contents/src/source-manifest.json?ref=VMR_HASH | jq -r '.content' | base64 -d | jq -r '.repositories[] | select(.path=="fsharp") | .commitSha'
43+
# Result: FSHARP_END
44+
```
45+
46+
### Get F# start commit (previous release)
47+
48+
Repeat above with previous SDK branch (e.g., `release/11.0.1xx-preview1`).
49+
Result: `FSHARP_START`
50+
51+
### Cross-check with parallel SDK branch
52+
53+
Repeat for `release/10.0.3xx` (or current stable band). Compare F# hash. Determine if features are shared or exclusive.
54+
55+
# 3. Diff release notes
56+
57+
```bash
58+
git diff FSHARP_START..FSHARP_END -- docs/release-notes/ | grep '^+' | grep -v '^+++'
59+
```
60+
61+
Source files:
62+
- `docs/release-notes/.FSharp.Compiler.Service/*.md`
63+
- `docs/release-notes/.FSharp.Core/*.md`
64+
- `docs/release-notes/.Language/*.md`
65+
- `docs/release-notes/.VisualStudio/*.md`
66+
67+
### EXCLUDE
68+
69+
- Already in previous announcement
70+
- CI, infra, test-only, repo maintenance, dependency updates, localization
71+
- FCS-internal API (unless enables user scenario)
72+
- xUnit migration, build scripts, baseline updates
73+
74+
# 4. Investigate each entry via sub-agents
75+
76+
For each user-facing release note entry, spawn a sub-agent (explore or general-purpose) to investigate it independently. Each sub-agent writes its findings to a temp file.
77+
78+
```
79+
For each entry with PR #NUMBER:
80+
81+
Launch sub-agent with prompt:
82+
"""
83+
Investigate dotnet/fsharp PR #NUMBER.
84+
1. Get PR author, title, description, linked issues
85+
2. Get files changed — classify as: feature / bugfix / test-only / infra
86+
3. If feature or significant bugfix:
87+
- Find test files: git diff-tree --no-commit-id -r <MERGE_SHA> --name-only | grep -i test
88+
- Extract the most illustrative code sample from the tests (real F# code, not test harness)
89+
- Note benchmark data if PR description has any
90+
4. If author is NOT T-Gro, Copilot, or abonie → mark as community contributor
91+
5. Write findings to /tmp/release-notes/pr-NUMBER.md in this format:
92+
93+
## PR #NUMBER: <title>
94+
- Author: <login> (community: yes/no)
95+
- Type: feature | bugfix | api | perf | infra
96+
- One-line summary: <what changed for users>
97+
- Issue(s): #X, #Y
98+
- Code sample (if feature/api):
99+
```fsharp
100+
<code from tests>
101+
```
102+
- Benchmark (if perf):
103+
<table or numbers from PR>
104+
"""
105+
```
106+
107+
Run sub-agents in parallel (up to 5). Wait for all to complete. Read all `/tmp/release-notes/pr-*.md` files to assemble the full picture.
108+
109+
Skip entries where sub-agent classified as `infra` or `test-only`.
110+
111+
# 5. Write the article
112+
113+
## Attribution
114+
115+
- Community contributors: `Thanks to [**user**](https://github.com/user)` with link
116+
- NEVER mention: T-Gro, Copilot, abonie (internal)
117+
- Credit community even if their PR was superseded (e.g., "Inspired by [**user**]'s work in #XXXX")
118+
119+
## Structure
120+
121+
```markdown
122+
# F# in .NET XX Preview Y - Release Notes
123+
124+
Here's a summary of what's new in F# in this Preview Y release:
125+
126+
- [Highlight 1](#anchor)
127+
- [Highlight 2](#anchor)
128+
- [Category 1](#anchor)
129+
- [Category 2](#anchor)
130+
- [Bug fixes](#bug-fixes-and-other-improvements)
131+
132+
## Highlight 1 ← 1-3 sections, CODE SAMPLES from tests, minimal prose
133+
## Highlight 2
134+
## Category: Query fixes ← bullet list with issue links, no code
135+
## Category: IDE fixes ← bullet list
136+
## Bug fixes ← flat bullet list, prefixed by area (Nullness:, Scripts:, etc.)
137+
138+
F# updates:
139+
- [F# release notes](https://fsharp.github.io/fsharp-compiler-docs/release-notes/About.html)
140+
- [dotnet/fsharp repository](https://github.com/dotnet/fsharp)
141+
```
142+
143+
## Highlight selection (pick 1-3)
144+
145+
Rank by: language feature > new API > perf win with numbers > significant bug fix area
146+
Each MUST have code sample extracted from PR tests. No invented examples.
147+
148+
## Style
149+
150+
- One-sentence intro max, then code block or table
151+
- No fluff, no "we are excited", no "this release brings"
152+
- Bold key terms in bullet lists
153+
- Link every issue and PR number
154+
155+
# SDK branch naming
156+
157+
| Release | Branch |
158+
|---|---|
159+
| .NET 11 Preview N | `release/11.0.1xx-previewN` |
160+
| .NET 10.0.X00 | `release/10.0.Xxx` |
161+
162+
# Key files
163+
164+
| Repo | Path | Contains |
165+
|---|---|---|
166+
| dotnet/sdk | `eng/Version.Details.xml` | VMR commit SHA |
167+
| dotnet/dotnet | `src/source-manifest.json` | F# commit SHA |
168+
| dotnet/fsharp | `docs/release-notes/` | Per-version changelogs |
169+
| dotnet/core | `release-notes/` | Published announcements |

.github/copilot-instructions.md

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,11 +20,17 @@ Bootstrap contamination: early commits break compiler → later "fixes" still us
2020
## Test
2121

2222
Default: `-c Debug`
23+
2324
Use `-c Release` for: EmittedIL tests, Optimizer tests, full component runs
24-
spot check: `dotnet test <proj> --filter "Name~X" -c Debug`
25+
26+
spot check: `dotnet test <proj> [--filter-method|--filter-class] "<glob_pattern>" -c Debug`
27+
2528
full component: `dotnet test tests/FSharp.Compiler.ComponentTests -c Release`
29+
2630
IDE/service: `tests/FSharp.Compiler.Service.Tests`
31+
2732
VS integration: `vsintegration/` (Windows only)
33+
2834
update baselines: `TEST_UPDATE_BSL=1 <test command>`
2935

3036
## Spotcheck tests

.github/instructions/TypedTreePickle.instructions.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ It tests both directions:
6767

6868
Also run the import regression tests:
6969
```bash
70-
dotnet test tests/FSharp.Compiler.ComponentTests -c Release --filter "FullyQualifiedName~Import" /p:BUILDING_USING_DOTNET=true
70+
dotnet test tests/FSharp.Compiler.ComponentTests -c Release -- --filter-method "*Import*" /p:BUILDING_USING_DOTNET=true
7171
```
7272

7373
For a detailed example of what goes wrong when these rules are violated, see `docs/postmortems/regression-fs0229-bstream-misalignment.md`.

.github/skills/hypothesis-driven-debugging/SKILL.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ Before forming hypotheses, create the smallest possible reproduction:
3333
1. **Extract the failure**:
3434
```bash
3535
# For test failures - run just the failing test
36-
dotnet test --filter "FullyQualifiedName~YourTest"
36+
dotnet test -- --filter-method "*YourTest*"
3737

3838
# For build failures - try to isolate the problematic file
3939
# Create a minimal .fs file that reproduces the issue
@@ -49,7 +49,7 @@ Before forming hypotheses, create the smallest possible reproduction:
4949
## Minimal Reproduction
5050

5151
File: test-case.fs
52-
Command: dotnet test --filter "FullyQualifiedName~TestName"
52+
Command: dotnet test -- --filter-method "*TestName*"
5353
Expected: <expected behavior>
5454
Actual: <actual behavior>
5555
```
@@ -170,7 +170,7 @@ Brief description of the failure/bug being investigated.
170170
2. **Run affected tests**:
171171
```bash
172172
# For targeted testing
173-
dotnet test --filter "FullyQualifiedName~AffectedTestSuite"
173+
dotnet test -- --filter-class "*AffectedTestSuite*"
174174

175175
# Record: Passed, Failed, Skipped, Time
176176
```
@@ -190,7 +190,7 @@ Brief description of the failure/bug being investigated.
190190
- Errors: 0
191191

192192
Tests:
193-
- Command: dotnet test --filter "FullyQualifiedName~XmlDocTests"
193+
- Command: dotnet test -- --filter-class "*XmlDocTests*"
194194
- Total: 61
195195
- Passed: 56
196196
- Failed: 0
@@ -205,7 +205,7 @@ Brief description of the failure/bug being investigated.
205205

206206
```bash
207207
# 1. Observe failure
208-
dotnet test --filter "FullyQualifiedName~XmlDocTests"
208+
dotnet test -- --filter-class "*XmlDocTests*"
209209
# Result: 15 tests failing
210210

211211
# 2. Create minimal repro
@@ -234,7 +234,7 @@ dotnet fsc test-case.fs
234234
./build.sh -c Release
235235
# 4m 44.9s, 0 errors
236236

237-
dotnet test --filter "FullyQualifiedName~XmlDocTests"
237+
dotnet test -- --filter-class "*XmlDocTests*"
238238
# 61 total, 56 passed, 0 failed, 5 skipped, 2s
239239

240240
# 7. Verify minimal repro

0 commit comments

Comments
 (0)