Agent Skill to Csharp Async
Agent Skill to Csharp Async is a verified SKILL blueprint on Promptally in Fullstack & Backend Engineering optimized for leading AI models. Get best practices for C# async programming. Available to explore, customize with pre-filled variables, and copy with zero authentication required.
Technical Specifications
| Specification | Value |
|---|---|
| Artifact type | SKILL (Fullstack & Backend Engineering) |
| Compatible engines | Universal / Model Agnostic |
| Input variables | None (pre-filled) |
| Approximate tokens | 466 |
| Source file | SKILL.md |
| Access tier | Free public (MIT) |
Pre-Filled Template
--- name: csharp-async description: 'Get best practices for C# async programming' --- # C# Async Programming Best Practices Your goal is to help me follow best practices for asynchronous programming in C#. ## Naming Conventions - Use the 'Async' suffix for all async methods - Match method names with their synchronous counterparts when applicable (e.g., `GetDataAsync()` for `GetData()`) ## Return Types - Return `Task<T>` when the method returns a value - Return `Task` when the method doesn't return a value - Consider `ValueTask<T>` for high-performance scenarios to reduce allocations - Avoid returning `void` for async methods except for event handlers ## Exception Handling - Use try/catch blocks around await expressions - Avoid swallowing exceptions in async methods - Use `ConfigureAwait(false)` when appropriate to prevent deadlocks in library code - Propagate exceptions with `Task.FromException()` instead of throwing in async Task returning methods ## Performance - Use `Task.WhenAll()` for parallel execution of multiple tasks - Use `Task.WhenAny()` for implementing timeouts or taking the first completed task - Avoid unnecessary async/await when simply passing through task results - Consider cancellation tokens for long-running operations ## Common Pitfalls - Never use `.Wait()`, `.Result`, or `.GetAwaiter().GetResult()` in async code - Avoid mixing blocking and async code - Don't create async void methods (except for event handlers) - Always await Task-returning methods ## Implementation Patterns - Implement the async command pattern for long-running operations - Use async streams (IAsyncEnumerable<T>) for processing sequences asynchronously - Consider the task-based asynchronous pattern (TAP) for public APIs When reviewing my C# code, identify these issues and suggest improvements that follow these best practices.
How to use this skill
- Review the pre-filled example and source files above.
- Copy the template or download
SKILL.md, then use it in your model, IDE, or workflow tool. - Compare your result with the sample output when one is provided.
Frequently Asked Questions
How do I use Agent Skill to Csharp Async?
Open the skill on Promptally, review the pre-filled example, then copy the template or download SKILL.md and paste it into your model, IDE or workflow tool. Agent Skill to Csharp Async is a static blueprint with no dynamic variables. Copy it and use it as-is.
Is Agent Skill to Csharp Async free?
Yes. Agent Skill to Csharp Async is free to view, copy and download on Promptally without creating an account. It is published under the MIT license.
What variables does Agent Skill to Csharp Async need?
Agent Skill to Csharp Async is a static blueprint with no dynamic variables. Copy it and use it as-is.