Categories
Mastering Development

Error while loading data from bigquery table to dataproc cluster

I’m new to Dataproc and PySpark and facing certain issues while integrating bigquery table to dataproc cluster via Jupyter Lab api. Below is the code that i used for loading bigquery table to the dataproc cluster through jupyter notebook api but i am getting an error while loading the table from pyspark.sql import SparkSession SparkSession.builder.appName(‘Jupyter […]

Categories
Mastering Development

simulate upload of file with test jest, apollo server in nodejs [closed]

I am trying simulate of a file upload with graphql using jest in nodejs, i tried create a formData for simulate the upload, i get erro TypeError: createReadStream is not a function, no know if is correct form. //IngredientClient.js const gql = require(‘graphql-tag’); const Ingredient_create = gql` mutation ( $name: String! $file: Upload! ){ ingredientCreate […]

Categories
Artificial Intelligence (AI) Mastering Development

No registered env with id: BanditTenArmedGaussian-v0 for the package gym_bandits of OpenAI [migrated]

I’ve made the following instruction : git clone https://github.com/JKCooper2/gym-bandits.git cd gym-bandits pip install -e . After installing : import gym_bandits import gym Now we finally : env = gym.make(“BanditTenArmedGaussian-v0”) Even tough the first three steps was successfull, the last one doesn’t work. Here is my error : ————————————————————————— KeyError Traceback (most recent call last) c:\windows\system32\gym\gym\envs\registration.py […]

Categories
User Help

“Windows cannot access the specified device, path, or file” crashes all Windows 10 apps immediately

I’ve been having this problem for a day or two now. Every time I try to open any Windows 10 App or App Service (Groovy, Realtek Audio Manager, Photo Viewer, wsreset.exe), I’m greeted with “Windows cannot access the specified device, path, or file. You may not have the appropriate permissions to open this file.”, and […]

Categories
Mastering Development

python3 backdoor Error “Type command Nothing Happens”

i am going to build a python3 backdoor. the connection between victim(using windows10) and my attacker machine(vbox kali linux 2020) is established by running the blew scrpits on victim and attacker machine respectively. On my attacker machine when i enter the commands like dir in console nothing happens it goe to next blank line. software […]

Categories
Mastering Development

Multiple views in one url address in Django

The problem is this: I have two classes Posts and Pubs in models.py, I need them to be displayed simultaneously on the main page, I have in views.py file: def pubs_list(request): publications = Pubs.objects.filter(published_date__lte=timezone.now()).order_by(‘published_date’) return render(request, ‘app/pubs_list.html’, {‘publications’: publications}) def posts_list(request): posts = Posts.objects.filter(published_date__lte=timezone.now()).order_by(‘published_date’) return render(request, ‘app/posts_list.html’, {‘posts’: posts}) in urls.py: path(”, views.posts_list, name=’posts_list’), # […]

Categories
Mastering Development

Why my angular service variable is undefined?

i’ve been trying to get a varaible from one component to another in my code and yet it returns undefined my service import { Injectable } from ‘@angular/core’; @Injectable({ providedIn: ‘root’ }) export class ColorService { public color : string; constructor() { } } My app module import { BrowserModule } from ‘@angular/platform-browser’; import { […]

Categories
Mastering Development

How to create additional category from omitted data?

I am currently working on a project where we need to collect data on a group of people and create categories based on age, gender, etc. My problem is that the code I was given omits all data for any person with any empty cells in the .csv (ex: didn’t give me their date of […]

Categories
Mastering Development

canLoad in children routes using NgRx

I’m working in an Angular 9 app and I’m trying to load (or not) an specific module only when my app state (ngrx) have a property != null First, I have an AuthGuard in my routes but with canActivate. So I want the ‘dashboard’ module only loads when mt AppState have a token Here is […]

Categories
Linux Mastering Development

Error with Keyring when connection from ssh

Due to COVID-19 we are working from home. Now I have a linux (Ubuntu) pc at my workplace which has TortoiseHG Workbench installed. I connect via MobaXTerm to my computer over ssh. Normally when I try to update the repo it works due to the password and user is saved in the keyring. Now when […]