Pull to refresh
89.97

C# *

Multi-paradigm programming language encompassing strong typing, imperative, declarative, functional, generic, object-oriented (class-based), and component-oriented programming disciplines

Show first
Rating limit
Level of difficulty

State Management for processes flow

Reading time 12 min
Views 486
Programming *System Analysis and Design *C# *
Sandbox

Most of the processes that people use in their work lives can be represented as some object that goes through some flow. Each flow contains many stages, in each one of them the object can be manipulated by certain group of users.

In this article I want to suggest an approaches to effectively handle such flow based systems. 

Read more
Rating 0
Comments 0

NFun — expression evaluator for .Net

Reading time 6 min
Views 759
Open source *.NET *Compilers *C# *GitHub *
Translation

Nfun is an embedded language and expression executor that supports primitive types, arrays, structures and lambda expressions.

Most likely, you have already met tasks that require such a tool, and in this article I want to show examples of its application, its capabilities and why it may be useful to you.

Let's learn some nFun!
Rating 0
Comments 1

How to handle Stale Element Reference Exception in E2E testing of modern SPA applications

Reading time 5 min
Views 776
Bimeister corporate blog IT systems testing *.NET *C# *Web services testing *
Tutorial

Hello everyone, my name is Denis, I am Software Developer Engineer in Test (SDET) at Bimeister. I am in charge of test software development - frameworks, automated tests, CI Pipelines configuration, and much more.

In this article, I will tell you how we defeated the Stale Element Reference Exception while developing our framework using Selenium WebDriver and C#.

Read more
Total votes 2: ↑2 and ↓0 +2
Comments 0

Unity: What is a Coroutine and why is there an IEnumerator

Reading time 5 min
Views 4.7K
.NET *Game development *C# *Unity3D *
Translation

The title of the article is a question I was asked in an interview for a Middle position. In this article, we will look at Unity coroutines, what they are, and at the same time we will capture the topic of Enumerator \ Enumerable in C # and a little secret of foreach. The article should be very useful for beginners.

Read more
Total votes 1: ↑1 and ↓0 +1
Comments 0

Why does my app send network requests when I open an SVG file?

Reading time 8 min
Views 1.8K
PVS-Studio corporate blog Information Security *Programming *.NET *C# *

0923_SVG_XXE_ru/image1.png


You decided to make an app that works with SVG. Encouraged by the enthusiasm, you collected libraries and successfully made the application. But suddenly you find that the app is sending strange network requests. And data is leaking from the host-machine. How so?

Read more →
Total votes 3: ↑3 and ↓0 +3
Comments 0

ECS: under the hood

Reading time 6 min
Views 3.3K
Game development *C# *Unity3D *
Translation

This is the translation of my article about ECS. Original (in Russian).

ECS (Entity Component System) is an architectural pattern used in game development.

In this article, I am going to describe some of the general principles of ECS frameworks' inner workings and some of the problems I have faced during the development of my own.

When I first started learning about ECS everything seemed wonderful, but only in theory. I needed some real practice to make sure that all that they were saying about ECS was true.

I’ve tried different frameworks with different engines and programming languages. Mostly it was the gorgeous EnTT framework that I used with the Godot engine and LeoECS with Unity. I haven’t tried Unity’s native ECS from DOTS because it was rather unpolished at the time I was starting.

After a while, I got enough practical experience with ECS but it was still unclear to me how all this magic works under the hood. There are a few good blogs about ECS development (https://skypjack.github.io/ from the author of EnTT and https://ajmmertens.medium.com/ from the author of Flecs) but none of them gave me enough understanding about how they are implemented. So eventually, following Bender’s example, I decided that I’m gonna make my own ECS =)

Read more
Total votes 2: ↑2 and ↓0 +2
Comments 0

Vulnerabilities due to XML files processing: XXE in C# applications in theory and in practice

Reading time 16 min
Views 1K
PVS-Studio corporate blog Information Security *Programming *.NET *C# *

How can simple XML files processing turn into a security weakness? How can a blog deployed on your machine cause a data leak? Today we'll find answers to these questions, learn what XXE is and how it looks like.


0918_XXE_BlogEngine/image1.png

Read more →
Total votes 1: ↑1 and ↓0 +1
Comments 0

Re-checking PascalABC.NET

Reading time 8 min
Views 439
PVS-Studio corporate blog .NET *Visual Studio *C# *Development for Windows *

Welcome all fans of clean code! Today we analyze the PascalABC.NET project. In 2017, we already found errors in this project. We used two static analysis tools (more precisely, plugins for SonarQube): SonarC# and PVS-Studio. Today, we analyze this project with the latest version of the PVS-Studio analyzer for C#. Let's see what errors we can find today, especially when our analyzer has become more advanced and got new features: it can find more exquisite errors and potential vulnerabilities.


0912_PascalABCNET_2/image1.png

Read more →
Total votes 3: ↑2 and ↓1 +1
Comments 0

Errors and suspicious code fragments in .NET 6 sources

Reading time 19 min
Views 708
PVS-Studio corporate blog Open source *.NET *C# *

0903_NET6/image1.png


The .NET 6 turned out to be much-awaited and major release. If you write for .NET, you could hardly miss such an event. We also couldn't pass by the new version of this platform. We decided to check what interesting things we can find in the sources of .NET libraries.

Read more →
Total votes 1: ↑1 and ↓0 +1
Comments 0

Structured Logging and Interpolated Strings in C# 10

Reading time 10 min
Views 23K
Programming *.NET *Compilers *C# *

Structured logging is gaining more and more popularity in the developers' community. In this article I'd like to demonstrate how we can use structured logging with the Microsoft.Extensions.Logging package and show the idea how we can extend it using the new features of C# 10.

Read more
Total votes 6: ↑6 and ↓0 +6
Comments 0

PVS-Studio checks the code quality in the .NET Foundation projects: LINQ to DB

Reading time 11 min
Views 439
PVS-Studio corporate blog .NET *C# *

The .NET Foundation is an independent organization, created by Microsoft, to support open-source projects around the DotNet platform. Currently, the organization gathered many libraries under its wing. We have already tested some of these libraries with the help of PVS-Studio. The next project to check with the analyzer - LINQ to DB.

Read more
Rating 0
Comments 0

All hail bug reports: how we reduced the analysis time of the user's project from 80 to 4 hours

Reading time 8 min
Views 516
PVS-Studio corporate blog Programming *.NET *C# *

0885_SupportAndAnalyzerOptimizations/image1.png


People often see work in support as something negative. Today we'll look at it from a different perspective. This article is about a real communication of 100+ messages, exceptions, the analysis that didn't complete in three days...

Read more →
Total votes 4: ↑3 and ↓1 +2
Comments 0

Authors' contribution