Is there any framework for .NET to populate test data?

I am use c# and for unit testing and integration testing usually I need to populate fields automatically based on attributes. Lets say we will test if we can write and get back user data to...

How to pass parameters to the DbContext.Database.ExecuteSqlCommand method?

Let's just suppose I have a valid need for directly executing a sql command in Entity Framework. I am having trouble figuring out how to use parameters in my sql statement. The following example...

How can I remove a specific item from an array?

I have an array of numbers and I'm using the .push() method to add elements to it. Is there a simple way to remove a specific element from an array? I'm looking for the equivalent of something...

Rails: Error installing pg gem

Possible Duplicate: Postgres - the last version 0.14.0 of the “pg” gem gives error I'm new to rails. I want to use PostgreSQL since Heroku uses it too, but I'm having a bad time installing...

Widget-based web framework in Python (similar to vaadin, GWT or zkoss)

I am basically from Java, but I need to use Python for a new project. I prefer widget based web framework like zkoss, vaadin, GWT etc. Does python has widget based framework?

Using scrollIntoView with a fixed position header

I have a site with a header set to position: fixed. On one of my pages, I use scrollIntoView(true) on an element. My problem is that when scrollIntoView is called, the element gets positioned...

What is wrong with placing models in a folder other than Models?

I'm a new learner of ASP.NET MVC. I looked through few books and code samples. While I learn I came up with the below question and cannot clearly understand the point below. Most books explain...

Controlling spring scheduled tasks at run time

I have a set of services written in Java using spring framework. Some of the services have scheduled tasks(using spring's @Scheduled annotation) to do some house keeping stuff (generating...

Server Architecture for hosting Java PLAY application in the cloud

This is rather a set of questions than one very specific question. In the last couple weeks/days I puzzled together information regarding how to properly host a JAVA PLAY application "in the...

How to dynamically pass db names with boxfuse deploying play framework

I have been trying to deploy a play application which has a mysql back end , have the db config in application.conf , trying to build a test conf running below since i had a db created...

python - locale in dateutil / parser

I set locale.setlocale(locale.LC_TIME, ('de', 'UTF-8')) the string to parse is: Montag, 11. April 2016 19:35:57 I use: note_date = parser.parse(result.group(2)) but get the following...

"host not allowed" error when deploying a play framework application to Amazon AWS with Boxfuse

I am trying to deploy a simple web application written using Play Framework in Scala to Amazon web service. The web application is running OK in development mode and production mode in my local...

Failed to activate virtualenv with pyenv

I run: pyenv activate new_app And I get: Failed to activate virtualenv. Perhaps pyenv-virtualenv has not been loaded into your shell properly. Please restart current shell and try again. I am...

Entity Framework Core : “Invalid attempt to call ReadAsync when reader is closed”

I am new in Entity framework core, I am making a simple short project. In my project I use trigger. But when I am deleting multiple items then the trigger shows an error : "Invalid attempt to call...

Using JSON Web Tokens (JWT) with Azure Functions (WITHOUT using Active Directory)

I am sure someone out there has already done this, but I have yet to find any documentation with regard to the Microsoft implementation of JWT. The official documentation from Microsoft for their...

Incorrect syntax near 'OFFSET'. Invalid usage of the option NEXT in the FETCH statement "in Entity Framework core"

Here's my EF Core code: int page = 1, rowPerPage = 5; int count = ctx.Specialty.Count(); int start = page * rowPerPage; var Select = ctx.Specialty.OrderByDescending(u => u.IdS) ...

"Uncaught EvalError: Refused to evaluate a string as JavaScript because 'unsafe-eval' is not an allowed source of script" when trying to run CKEditor

I am running the Invenio digital repository framework locally, which comes with a node module for running CKEditor, whose rich-text capabilities are an essential requirement for this project. I've...

Firebase invalid api key error in console

I use Firebase-auth for my web application I'm developing with electron framework. I created an API key using project settings, and copied it into my html's body as it is suggested in Firebase...

Can Entity Framework 6 be used in a .NET Standard project?

And if not, will it be? If so, when? I haven't been able to find any clear official information on this, and the limited information I was able to find on Stack Overflow is a year or two old. I...

Illuminate\Database\QueryException could not find driver

Illuminate\Database\Connection::runQueryCallback C:\wamp\www\LaravelProject\vendor\laravel\framework\src\Illuminate\Database\Connection.php:671 ERROR: Illuminate\Database\QueryException SQLSTATE[42...

Cannot find type SwiftUI 'Color' in scope

I added an extension to UIColor with a quick conversion function to SwiftUI's Color. It's very simple: import Foundation import SwiftUI import UIKit @available(iOS 13, macOS 10.15, *) public...

Upload many images django rest framework

I try to upload many images to one post. I try to achive this: When I post data i get this: What is wrong with my code ?

What are the files boot_app0.bin and bootloader_dio_80m.bin for? (ESP32 - Arduino IDE)

The ESP32 flash command, as executed by the Arduino IDE, seems to flash two bootloader files: boot_app0.bin at offset 0xe000 and bootloader_dio_80m.bin at offset 0x1000. I wonder what these two...

in VS Code ImportError: cannot import name 'Mapping' from 'collections'

I am trying to connect to Postgress and create a folder test.db via Flask. When I run "python3" in the terminal and from there when I run "from app import db" I get an import error: ImportError:...

Problem trying to display custom error pages with Spring Boot

I'm maintaining a Spring Boot Application that uses Swagger to define Rest web services and uses Maven for dependency management. It uses an application.yml file for properties. By default, when...

Gradle dependency (org.apache.commons ) is also effected by current log4j vulnerability or not?

Currently a vulnerability in the Log4j logging framework has happened. But in our project we are not using log4j dependency directly. We are using log4j via org.apache.common. So the question is...

Python3 and 'code' CLI not working after updating to MacOS Monterey

I updated to MacOS Monterey and now python is not working: ➜ ~ python3 --version dyld[6578]: dyld cache '/System/Library/dyld/dyld_shared_cache_x86_64h' not loaded: syscall to map cache...

The Type or namespace ALMSTWKND could not be found... - but it exists

I am receiving between 20 to 60 errors stating: Severity Code Description Project File Line Suppression State Error CS0246 The type or namespace name 'ALMSTWKND' could not be found (are you...

Dj rest auth using JWT Token stored in HttpOnly cookies

I'm making a Django Rest Framework application with a JWT authentication with tokens stored in HttpOnly cookies. Authentication is performed via reading the access cookie. I'm using a dj-rest-auth...

.NET Core 6 with Angular template in VS 2022 is showing only Launching the SPA proxy... Page

I'm trying to create ASP.NET Core 6 with Angular template I'm using VS 2022 and.net 6 and the npm is the latest release and Node js as well. I've followed the normal project steps: 1- create a...