问:
How to add wait and click dynamic dropdowns in NewRelic sysnthetic tests
I am trying to click on a dynamic auto-complete dropdown option to validate output on NewRelic synthetics. My code is not waiting and clicking the auto-complete option in the dropdown as expected.

This is my code:

```<code>$browser.get(url).then(function(){
  $browser.findElement($driver.By.xpath('//header[@id="header"]//a[2][@href="https://nowcouriers.co.nz/addresschecker/"]')).click().then(function(){
   return $browser.findElement($driver.By.className("auto-complete-container")).isDisplayed().then(function(){
     $browser.findElement($driver.By.xpath('//input[@id="txt-address-auto-complete"]')).sendKeys("32 Botha Road, Penrose, AUCKLAND").then(function(){
       return $browser.waitForAndFindElement($driver.By.xpath('li[class="ui-menu-item"]'), 5000).click().then(function(){
         return $browser.findElement($driver.By.xpath('//div[@id="rowServicesOfferedMonToFriZone"]')).getText().then(function(text){
           console.log(text)
           assert.equal("MON - FRI STANDARD DELIVERY ",text, 'Mon-Fri standard delivery text error');
         });
         return $browser.findElement($driver.By.xpath('//div[@id="rowServicesOfferedSaturdayZone"]')).getText().then(function(text){
           console.log(text)
           assert.equal("SATURDAY DELIVERY".toUpperCase(),text.toUpperCase(), 'Saturday delivery text error');
         });
         return $browser.findElement($driver.By.xpath('(//div[@class="delivery-details"])[2]')).getText().then(function(text){
           console.log(text)
           assert.equal("BUSINESS DELIVERY ZONE".toUpperCase(),text.toUpperCase(), 'Business delivery text error');
         });
       });
     });
    });
  });
});
</code>```

Can anyone help me with the element wait and click here will be highly appreciated.

This is the snapshot when failing the test

Body:
I am trying to click on a dynamic auto-complete dropdown option to validate output on NewRelic synthetics. My code is not waiting and clicking the auto-complete option in the dropdown as expected.

This is my code:

$browser.get(url).then(function(){
  $browser.findElement($driver.By.xpath('//header[@id="header"]//a[2][@href="https://nowcouriers.co.nz/addresschecker/"]')).click().then(function(){
   return $browser.findElement($driver.By.className("auto-complete-container")).isDisplayed().then(function(){
     $browser.findElement($driver.By.xpath('//input[@id="txt-address-auto-complete"]')).sendKeys("32 Botha Road, Penrose, AUCKLAND").then(function(){
       return $browser.waitForAndFindElement($driver.By.xpath('li[class="ui-menu-item"]'), 5000).click().then(function(){
         return $browser.findElement($driver.By.xpath('//div[@id="rowServicesOfferedMonToFriZone"]')).getText().then(function(text){
           console.log(text)
           assert.equal("MON - FRI STANDARD DELIVERY ",text, 'Mon-Fri standard delivery text error');
         });
         return $browser.findElement($driver.By.xpath('//div[@id="rowServicesOfferedSaturdayZone"]')).getText().then(function(text){
           console.log(text)
           assert.equal("SATURDAY DELIVERY".toUpperCase(),text.toUpperCase(), 'Saturday delivery text error');
         });
         return $browser.findElement($driver.By.xpath('(//div[@class="delivery-details"])[2]')).getText().then(function(text){
           console.log(text)
           assert.equal("BUSINESS DELIVERY ZONE".toUpperCase(),text.toUpperCase(), 'Business delivery text error');
         });
       });
     });
    });
  });
});

Can anyone help me with the element wait and click here will be highly appreciated.

This is the snapshot when failing the test


来源: stackexchange

问:
Spark - Map udf to windows in spark dataframe
Problem Statement:

Have to group InputDf based on multiple columns (accountGuid, appID, deviceGuid, deviceMake) and order each group by time

Need to check if the test Df exists in the exact sequence in each window

If it exists, create a new dataframe with these columns below:

"project", "accountGuid", "appID", "deviceGuid", "deviceMake", "testCase", "result"
```
<p>eg:</p>
<div class="s-table-container">
<table class="s-table">
<thead>
<tr>
<th>project</th>
<th>accountGuid</th>
<th>appID</th>
<th>deviceGuid</th>
<th>deviceMake</th>
<th>testCase</th>
<th>result</th>
</tr>
</thead>
<tbody>
<tr>
<td>Profiles</td>
<td>guid1</td>
<td>9.0.77</td>
<td>dGuid1</td>
<td>AndroidTV</td>
<td>Select Admin Profile</td>
<td>pass</td>
</tr>
</tbody>
</table>
</div>
<p>Input Df:</p>
<div class="s-table-container">
<table class="s-table">
<thead>
<tr>
<th>accountGuid</th>
<th>appID</th>
<th>deviceGuid</th>
<th>deviceMake</th>
<th>tabName</th>
<th>screenName</th>
<th>actionName</th>
<th>time</th>
</tr>
</thead>
<tbody>
<tr>
<td>guid1</td>
<td>9.0.77</td>
<td>dGuid1</td>
<td>AndroidTV</td>
<td>Profiles</td>
<td>Profiles</td>
<td>Click - Profile Admin</td>
<td>9:01</td>
</tr>
<tr>
<td>guid2</td>
<td>9.0.77</td>
<td>dGuid2</td>
<td>AndroidPhone</td>
<td>Profiles</td>
<td>Profiles</td>
<td>Click - Profile Admin</td>
<td>8:00</td>
</tr>
<tr>
<td>guid1</td>
<td>9.0.77</td>
<td>dGuid1</td>
<td>AndroidTV</td>
<td>Profiles</td>
<td>Profiles</td>
<td>Page Load</td>
<td>9:03</td>
</tr>
<tr>
<td>guid1</td>
<td>9.0.77</td>
<td>dGuid1</td>
<td>AndroidTV</td>
<td>Profiles</td>
<td>Profiles</td>
<td>Click - Add Profile</td>
<td>9:05</td>
</tr>
<tr>
<td>guid3</td>
<td>9.0.77</td>
<td>dGuid3</td>
<td>FireTV</td>
<td>Profiles</td>
<td>Add Profile</td>
<td>Click - Name</td>
<td>9:02</td>
</tr>
<tr>
<td>guid2</td>
<td>9.0.77</td>
<td>dGuid2</td>
<td>AndroidPhone</td>
<td>Profiles</td>
<td>Profiles</td>
<td>Page Load</td>
<td>8:03</td>
</tr>
</tbody>
</table>
</div>
<p>Test Df:</p>
<p>testCase - Select Admin Profile</p>
<div class="s-table-container">
<table class="s-table">
<thead>
<tr>
<th>tabName</th>
<th>screenName</th>
<th>actionName</th>
</tr>
</thead>
<tbody>
<tr>
<td>Profiles</td>
<td>Profiles</td>
<td>Click - Profile Admin</td>
</tr>
<tr>
<td>Profiles</td>
<td>Profiles</td>
<td>Page Load</td>
</tr>
</tbody>
</table>
</div>
<p><strong>Approach taken:</strong></p>
<ol>
<li>I have created a window and assigned a unique guid to each window along with row_number</li>
</ol>
<pre class="lang-scala prettyprint-override"><code>val windowSpec = Window.partitionBy("accountGuid", "appID", "deviceGuid", "deviceMake")
  .orderBy("time")

val partitionedDf = inputDf.withColumn("groupguid", first(expr("uuid()")).over(windowSpec))
  .withColumn("row_number", row_number.over(windowSpec))
</code>```

partitionedDf Output:

accountGuid
appID
deviceGuid
deviceMake
tabName
screenName
actionName
time
groupguid
row_number

guid1
9.0.77
dGuid1
AndroidTV
Profiles
Profiles
Click - Profile Admin
9:01
1234
1

guid1
9.0.77
dGuid1
AndroidTV
Profiles
Profiles
Page Load
9:03
1234
2

guid1
9.0.77
dGuid1
AndroidTV
Profiles
Profiles
Click - Add Profile
9:05
1234
3

guid2
9.0.77
dGuid2
AndroidPhone
Profiles
Profiles
Click - Profile Admin
8:00
1456
1

guid2
9.0.77
dGuid2
AndroidPhone
Profiles
Profiles
Page Load
8:03
1456
2

guid3
9.0.77
dGuid3
FireTV
Profiles
Add Profile
Click -Name
9:02
8907
1

Getting all the uniqueIDs in a list

val uniqueIds = partitionedDf
  .select("groupguid")
  .distinct()
  .map(row=>{(row.getString(0))})
  .collect
  .toList
```
<ol start="3">
<li>Looping over all windows and checking if the testDf exists and present in the exact sequence</li>
</ol>
<pre class="lang-scala prettyprint-override"><code>for (id <- uniqueIds) //loop to get each state
{
  val windowDf = partitionedDf
    .filter($"groupguid" === id)

  val groupingDf = windowDf.select($"tabName", $"screenName", $"actionName", $"row_number")

isAvailable = areRowsAvailable(groupingDf, testDf)

if (isAvailable) {
   -- check if the test dataframe is present in the correct sequence
}

}

def areRowsAvailable(groupingDf: DataFrame, testDf: DataFrame): Boolean = {
  val df = testDf.join(groupingDf,
    testDf("tabName") === groupingDf("tabName") &&
    testDf("screenName") === groupingDf("screenName") &&
    testDf("actionName") === groupingDf("actionName"), "left_anti")
  df.rdd.isEmpty()
}
</code>```

But in this approach, I could see that as it is looping over all the windows thus the processing is happening sequentially and all executors are not getting used and the job takes close to a day to finish with inputDf size of 20GB data.

Expectation: Want to know how to distribute the load across all windows in the dataframe rather than looping over each and processing sequentially.

As I am new to spark, not sure if there is a better way of doing this, should I create a UDF for this ?

ContentLicense: CC BY-SA 4.0

Body:
Problem Statement:

Have to group InputDf based on multiple columns (accountGuid, appID, deviceGuid, deviceMake) and order each group by time

Need to check if the test Df exists in the exact sequence in each window

If it exists, create a new dataframe with these columns below:

"project", "accountGuid", "appID", "deviceGuid", "deviceMake", "testCase", "result"

eg:

project
accountGuid
appID
deviceGuid
deviceMake
testCase
result

Profiles
guid1
9.0.77
dGuid1
AndroidTV
Select Admin Profile
pass

Input Df:

accountGuid
appID
deviceGuid
deviceMake
tabName
screenName
actionName
time

guid1
9.0.77
dGuid1
AndroidTV
Profiles
Profiles
Click - Profile Admin
9:01

guid2
9.0.77
dGuid2
AndroidPhone
Profiles
Profiles
Click - Profile Admin
8:00

guid1
9.0.77
dGuid1
AndroidTV
Profiles
Profiles
Page Load
9:03

guid1
9.0.77
dGuid1
AndroidTV
Profiles
Profiles
Click - Add Profile
9:05

guid3
9.0.77
dGuid3
FireTV
Profiles
Add Profile
Click - Name
9:02

guid2
9.0.77
dGuid2
AndroidPhone
Profiles
Profiles
Page Load
8:03

Test Df:

testCase - Select Admin Profile

tabName
screenName
actionName

Profiles
Profiles
Click - Profile Admin

Profiles
Profiles
Page Load

Approach taken:

I have created a window and assigned a unique guid to each window along with row_number

val windowSpec = Window.partitionBy("accountGuid", "appID", "deviceGuid", "deviceMake")
  .orderBy("time")

val partitionedDf = inputDf.withColumn("groupguid", first(expr("uuid()")).over(windowSpec))
  .withColumn("row_number", row_number.over(windowSpec))

partitionedDf Output:

accountGuid
appID
deviceGuid
deviceMake
tabName
screenName
actionName
time
groupguid
row_number

guid1
9.0.77
dGuid1
AndroidTV
Profiles
Profiles
Click - Profile Admin
9:01
1234
1

guid1
9.0.77
dGuid1
AndroidTV
Profiles
Profiles
Page Load
9:03
1234
2

guid1
9.0.77
dGuid1
AndroidTV
Profiles
Profiles
Click - Add Profile
9:05
1234
3

guid2
9.0.77
dGuid2
AndroidPhone
Profiles
Profiles
Click - Profile Admin
8:00
1456
1

guid2
9.0.77
dGuid2
AndroidPhone
Profiles
Profiles
Page Load
8:03
1456
2

guid3
9.0.77
dGuid3
FireTV
Profiles
Add Profile
Click -Name
9:02
8907
1

Getting all the uniqueIDs in a list

val uniqueIds = partitionedDf
  .select("groupguid")
  .distinct()
  .map(row=>{(row.getString(0))})
  .collect
  .toList

Looping over all windows and checking if the testDf exists and present in the exact sequence

for (id <- uniqueIds) //loop to get each state
{
  val windowDf = partitionedDf
    .filter($"groupguid" === id)

  val groupingDf = windowDf.select($"tabName", $"screenName", $"actionName", $"row_number")

isAvailable = areRowsAvailable(groupingDf, testDf)

if (isAvailable) {
   -- check if the test dataframe is present in the correct sequence
}

}

def areRowsAvailable(groupingDf: DataFrame, testDf: DataFrame): Boolean = {
  val df = testDf.join(groupingDf,
    testDf("tabName") === groupingDf("tabName") &&
    testDf("screenName") === groupingDf("screenName") &&
    testDf("actionName") === groupingDf("actionName"), "left_anti")
  df.rdd.isEmpty()
}

But in this approach, I could see that as it is looping over all the windows thus the processing is happening sequentially and all executors are not getting used and the job takes close to a day to finish with inputDf size of 20GB data.

Expectation: Want to know how to distribute the load across all windows in the dataframe rather than looping over each and processing sequentially.

As I am new to spark, not sure if there is a better way of doing this, should I create a UDF for this ?


问:
Creating multiple temporary SQL databases. Loop to create multiple CSV outputs
I currently have an R script that creates an output and I want to have the code output 6 different subsets in one go. Here is code that determines which subset of the data is outputted. In this example I only show 2 of the subsets but I have 6 total.

### only keep ids with internet expenses
#expend <- expend[expend$NEWID %in% int_id,]
#fmly <- fmly[fmly$NEWID %in% int_id,]

### only keep ids with phone expenses
expend <- expend[expend$NEWID %in% tel_id,]
fmly <- fmly[fmly$NEWID %in% tel_id,]
```
<p>I then use this expend and fmly data frame to create a table in a temporary database in sql server.</p>
<pre class="lang-r prettyprint-override"><code>db <- dbConnect( SQLite() , temp.db )
# store the family data frame in that database
dbWriteTable( db , 'fmly' , fmly , row.names = FALSE )
# create an index on the fmly table to drastically speed up future queries
dbSendQuery( db , "CREATE INDEX nsf ON fmly ( NEWID , src )" )
# store the expenditure data frame in that database as well
dbWriteTable( db , 'expend' , expend , row.names = FALSE )
</code>```

Then I do a bunch of other stuff and write out the tables into a csv.

#write.csv( tab.out , paste0(path, "/", "Integrated Mean and SE internet only.csv") , row.names = FALSE )
## records with phone expenses only
write.csv( tab.out , paste0(path, "/", "Integrated Mean and SE phone only.csv") , row.names = FALSE )
```

Currently I am just commenting out the expend and fmly variables that I don't want to use and rerunning the whole script to get different outputs. Is there a way that I can loop these so that I can run the script once to get all 6 subsets into separate csvs? For example I would create a loop that has expend1 expend2 fmly1 fmly2 etc.. and then create 6 db- db1, db2 etc.

Sorry if this is confusing, it is difficult to explain. Thank you for your help.

I so far tried to create a list with expend1 - 6 and it did not work. I also tried to create a function that has all of the database and table creation, and then running with the different expends, but it did not work.

Body:
I currently have an R script that creates an output and I want to have the code output 6 different subsets in one go. Here is code that determines which subset of the data is outputted. In this example I only show 2 of the subsets but I have 6 total.

### only keep ids with internet expenses
#expend <- expend[expend$NEWID %in% int_id,]
#fmly <- fmly[fmly$NEWID %in% int_id,]

### only keep ids with phone expenses
expend <- expend[expend$NEWID %in% tel_id,]
fmly <- fmly[fmly$NEWID %in% tel_id,]

I then use this expend and fmly data frame to create a table in a temporary database in sql server.

db <- dbConnect( SQLite() , temp.db )
# store the family data frame in that database
dbWriteTable( db , 'fmly' , fmly , row.names = FALSE )
# create an index on the fmly table to drastically speed up future queries
dbSendQuery( db , "CREATE INDEX nsf ON fmly ( NEWID , src )" )
# store the expenditure data frame in that database as well
dbWriteTable( db , 'expend' , expend , row.names = FALSE )

Then I do a bunch of other stuff and write out the tables into a csv.

#write.csv( tab.out , paste0(path, "/", "Integrated Mean and SE internet only.csv") , row.names = FALSE )
## records with phone expenses only
write.csv( tab.out , paste0(path, "/", "Integrated Mean and SE phone only.csv") , row.names = FALSE )

Currently I am just commenting out the expend and fmly variables that I don't want to use and rerunning the whole script to get different outputs. Is there a way that I can loop these so that I can run the script once to get all 6 subsets into separate csvs? For example I would create a loop that has expend1 expend2 fmly1 fmly2 etc.. and then create 6 db- db1, db2 etc.

Sorry if this is confusing, it is difficult to explain. Thank you for your help.

I so far tried to create a list with expend1 - 6 and it did not work. I also tried to create a function that has all of the database and table creation, and then running with the different expends, but it did not work.


问:
Looping nested class in scrollview in kivy
I am trying to make a scrollview which has button and label oraganised at different places and for that i need to use nested classes. Now the problem is i want to loop the same class multiple times.

.py file

```<code>class MenuScreen(Screen):
    pass
class Infoline(FloatLayout):
    pass
</code>```

.kv string

```<code><Infoline>:
    size_hint_y:None

<MenuScreen>:
    pnm:pnm_input
    qpnm:qpnm_input
    npnm:npnm_input
    name:"menu"
    FloatLayout:
        ScrollView:
            size_hint_y:None
            size_hint_x:.4
            size:40,280
            pos_hint:{'x':.5,'y':.407}
            do_scroll_x: False
            do_scroll_y: True
            scroll_type:['bars', 'content']
            bar_width: 5
            BoxLayout:
                orientation: 'vertical'
                id: sv_box
                size_hint_y: None
                height: self.minimum_height
                Infoline:
                    Button:
                        text:'Product Name'
                        size_hint:.99,.99
                        pos_hint: {"x":0.001, "y":0.2}

                    MLabel:
                        text:'jdyu'
                        size_hint:.01,.01
                        pos_hint: {"x":0.3, "y":0.7}
</code>```

Body:
I am trying to make a scrollview which has button and label oraganised at different places and for that i need to use nested classes. Now the problem is i want to loop the same class multiple times.

.py file

class MenuScreen(Screen):
    pass
class Infoline(FloatLayout):
    pass

.kv string

<Infoline>:
    size_hint_y:None

<MenuScreen>:
    pnm:pnm_input
    qpnm:qpnm_input
    npnm:npnm_input
    name:"menu"
    FloatLayout:
        ScrollView:
            size_hint_y:None
            size_hint_x:.4
            size:40,280
            pos_hint:{'x':.5,'y':.407}
            do_scroll_x: False
            do_scroll_y: True
            scroll_type:['bars', 'content']
            bar_width: 5
            BoxLayout:
                orientation: 'vertical'
                id: sv_box
                size_hint_y: None
                height: self.minimum_height
                Infoline:
                    Button:
                        text:'Product Name'
                        size_hint:.99,.99
                        pos_hint: {"x":0.001, "y":0.2}

                    MLabel:
                        text:'jdyu'
                        size_hint:.01,.01
                        pos_hint: {"x":0.3, "y":0.7}


问:
Using semantic-release to publish to both github and npmjs
We are in the process of migrating from npmjs to GitHub Packages for our private npm packages. To try and smooth this process, I am trying to have our CI process publish packages to both registries while projects make the switch. We've been using pretty vanilla semantic-release to do our versioning/publishing and I'm trying to preserve that but keep getting stuck trying to publish to more than one place.

My first attempt had a workflow that went:

build/test/etc.

npx semantic-release with NPM_CONFIG_REGISTRY={github} and appropriate creds

npx semantic-release with NPM_CONFIG_REGISTRY={npmjs} and appropriate creds

This results in an error in step 3 because semantic-release tries to re-tag/release to github and fails because it already did that in step 2.

My second attempt was:

build/tests/etc.

npx semantic-release (same github settings as previously)

npm publish with npmjs settings

This works if step two did a release - step 3 pushes the just-created release to npmjs and all is well. However, if step 2 did not do a release (typically because there were no commits that should cause one based on semantic-releases rules), step 3 ends up trying to re-publish whatever the previously released version was, resulting in an error.

Googling for topics related to "publishing to multiple registries with semantic-release" doesn't seem to yield much, so I'm also wondering if I'm just going about this migration the wrong way. Alternative suggestions welcome.


问:
Able to fetch user details but still getting google authentication error during redirection
I am trying to use passport to google auth and log in a user.

Based on logs, I am able to fetch the user profile fine and also store it in mongodb for reuse.

Yet when after clicking the google login in UI, logs looking fine, but it doesn't redirect to the private page /private. Instead it throws following error.

Error is not consistent. Sometimes shows this. Other times just keeps staying on the google login page and keeps redirecting back to it.

```<code>InternalOAuthError: failed to fetch user profile
    at /Users/name/projects/project-name/node_modules/passport-google-oauth2/lib/oauth2.js:92:28
    at ClientRequest.<anonymous> (/Users/name/projects/project-name/node_modules/oauth/lib/oauth2.js:162:5)
    at ClientRequest.emit (node:events:513:28)
    at TLSSocket.socketErrorListener (node:_http_client:494:9)
    at TLSSocket.emit (node:events:513:28)
    at emitErrorNT (node:internal/streams/destroy:151:8)
    at emitErrorCloseNT (node:internal/streams/destroy:116:3)
    at process.processTicksAndRejections (node:internal/process/task_queues:82:21)
</code>```

What am I missing?

This is the entire logic.

authentication.js (doubt issue is here. This is more on db connection which is fine)

```<code>import mongoose from 'mongoose';
import findOrCreate from 'mongoose-findorcreate'
import {DB_CLUSTER, DB_NAME, DB_OPTIONS, DB_PASSWORD, DB_USERNAME} from "./secrets.js";

export const createDbConnections = async () => {

  const connectionString = `mongodb+srv://${DB_USERNAME}:${DB_PASSWORD}@${DB_CLUSTER}/${DB_NAME}?${DB_OPTIONS}`;

  mongoose.connect(connectionString, { useNewUrlParser: true });

  const db = await mongoose.connection;
  db.on('error', console.error.bind(console, 'connection error:'));

  db.once('open', () => {
    console.log('Connected to MongoDB');
  });
}

const userSchema = new mongoose.Schema({
  name: {
    type: String,
  },
  email: String,
  googleId: String
});

userSchema.plugin(findOrCreate);

export const User = mongoose.model('User', userSchema);
</code>```

This is the main index.js file with the auth and routes.

```<code>import passport from 'passport';
import {Strategy} from 'passport-google-oauth2';
import express from 'express';
import session from 'express-session';
import {config} from "dotenv";
import {createDbConnections, User} from "./authentication.js";
import {COOKIE_SESSION_SECRET, GOOGLE_CLIENT_ID, GOOGLE_CLIENT_SECRET, PORT} from "./secrets.js";

const app = express();
app.use(session({
  secret: COOKIE_SESSION_SECRET,
  resave: false,
  saveUninitialized: true
}));
config();

await createDbConnections(); // connecting to mongo db no issues here.

passport.use('google', new Strategy({
    clientID: GOOGLE_CLIENT_ID,
    clientSecret: GOOGLE_CLIENT_SECRET,
    callbackURL: `/auth/google/callback`,
    scope: ['profile', 'email']
  },
  (accessToken, refreshToken, profile, done) => {
    User.findOrCreate({ googleId: profile.id }, (err, user) => {
      console.log(user)
      return done(err, user);
    });
  }
));

app.get('/auth/google', passport.authenticate('google', { scope: ['profile', 'email'] }));

app.get('/auth/google/callback',
  passport.authenticate('google', { failureRedirect: '/' }),
  (req, res) => {
    req.login(req.user, err => {
      if (err) { return res.send('Error during callback req.login portion'); }

      console.log(`I reach here fine ${req.user}`)
      return res.redirect('/private');
    });
  });

app.get('/private', passport.authenticate('google', { failureRedirect: '/' }), (req, res) => {
  console.log('Issue is here. I never reach here.')
  res.send('private spot');
});

app.get('/', (req, res) => {
  if (req.user) {
    // User is already logged in, render the homepage
    res.redirect('/private');
  } else {
    // User is not logged in, render the login page
    res.send(`Go and login @ http://localhost:${PORT}/auth/google`);
  }
});

passport.serializeUser((user, done) => {
  done(null, user.id);
});

passport.deserializeUser((id, done) => {
  User.findById(id, (err, user) => {
    done(err, user);
  });
});

app.listen(PORT, () => {
  console.log(`Go and authenticate @ http://localhost:${PORT}/auth/google`);
});
</code>```

Body:
I am trying to use passport to google auth and log in a user.

Based on logs, I am able to fetch the user profile fine and also store it in mongodb for reuse.

Yet when after clicking the google login in UI, logs looking fine, but it doesn't redirect to the private page /private. Instead it throws following error.

Error is not consistent. Sometimes shows this. Other times just keeps staying on the google login page and keeps redirecting back to it.

InternalOAuthError: failed to fetch user profile
    at /Users/name/projects/project-name/node_modules/passport-google-oauth2/lib/oauth2.js:92:28
    at ClientRequest.<anonymous> (/Users/name/projects/project-name/node_modules/oauth/lib/oauth2.js:162:5)
    at ClientRequest.emit (node:events:513:28)
    at TLSSocket.socketErrorListener (node:_http_client:494:9)
    at TLSSocket.emit (node:events:513:28)
    at emitErrorNT (node:internal/streams/destroy:151:8)
    at emitErrorCloseNT (node:internal/streams/destroy:116:3)
    at process.processTicksAndRejections (node:internal/process/task_queues:82:21)

What am I missing?

This is the entire logic.

authentication.js (doubt issue is here. This is more on db connection which is fine)

import mongoose from 'mongoose';
import findOrCreate from 'mongoose-findorcreate'
import {DB_CLUSTER, DB_NAME, DB_OPTIONS, DB_PASSWORD, DB_USERNAME} from "./secrets.js";

export const createDbConnections = async () => {

  const connectionString = `mongodb+srv://${DB_USERNAME}:${DB_PASSWORD}@${DB_CLUSTER}/${DB_NAME}?${DB_OPTIONS}`;

  mongoose.connect(connectionString, { useNewUrlParser: true });

  const db = await mongoose.connection;
  db.on('error', console.error.bind(console, 'connection error:'));

  db.once('open', () => {
    console.log('Connected to MongoDB');
  });
}

const userSchema = new mongoose.Schema({
  name: {
    type: String,
  },
  email: String,
  googleId: String
});

userSchema.plugin(findOrCreate);

export const User = mongoose.model('User', userSchema);

This is the main index.js file with the auth and routes.

import passport from 'passport';
import {Strategy} from 'passport-google-oauth2';
import express from 'express';
import session from 'express-session';
import {config} from "dotenv";
import {createDbConnections, User} from "./authentication.js";
import {COOKIE_SESSION_SECRET, GOOGLE_CLIENT_ID, GOOGLE_CLIENT_SECRET, PORT} from "./secrets.js";

const app = express();
app.use(session({
  secret: COOKIE_SESSION_SECRET,
  resave: false,
  saveUninitialized: true
}));
config();

await createDbConnections(); // connecting to mongo db no issues here.

passport.use('google', new Strategy({
    clientID: GOOGLE_CLIENT_ID,
    clientSecret: GOOGLE_CLIENT_SECRET,
    callbackURL: `/auth/google/callback`,
    scope: ['profile', 'email']
  },
  (accessToken, refreshToken, profile, done) => {
    User.findOrCreate({ googleId: profile.id }, (err, user) => {
      console.log(user)
      return done(err, user);
    });
  }
));

app.get('/auth/google', passport.authenticate('google', { scope: ['profile', 'email'] }));

app.get('/auth/google/callback',
  passport.authenticate('google', { failureRedirect: '/' }),
  (req, res) => {
    req.login(req.user, err => {
      if (err) { return res.send('Error during callback req.login portion'); }

      console.log(`I reach here fine ${req.user}`)
      return res.redirect('/private');
    });
  });

app.get('/private', passport.authenticate('google', { failureRedirect: '/' }), (req, res) => {
  console.log('Issue is here. I never reach here.')
  res.send('private spot');
});

app.get('/', (req, res) => {
  if (req.user) {
    // User is already logged in, render the homepage
    res.redirect('/private');
  } else {
    // User is not logged in, render the login page
    res.send(`Go and login @ http://localhost:${PORT}/auth/google`);
  }
});

passport.serializeUser((user, done) => {
  done(null, user.id);
});

passport.deserializeUser((id, done) => {
  User.findById(id, (err, user) => {
    done(err, user);
  });
});

app.listen(PORT, () => {
  console.log(`Go and authenticate @ http://localhost:${PORT}/auth/google`);
});


问:
Error: Cannot find module './ui/Button.svelte' or its corresponding type declarations - typescript
I am trying to build a monorepo using npm with apps and package folders. The package folder has a shared_library with a components folder that contains a UI folder with a Button.svelte file and a Button.d.ts file. The components folder also has an index.ts file for exporting the Button component and a package.json file for the namespace. Where as the apps folder has sveltekit app. Following is the directory structure

The shared_library folder also has a node_modules folder for TypeScript, a package.json file with a devDependency on TypeScript, and a tsconfig.json file with an "include" array that includes "**/*.ts". In the index.ts file, I am exporting the Button component as follows:

export { default as Button } from "./ui/Button.svelte";

But I get an error saying that - Cannot find module './ui/Button.svelte' or its corresponding type declarations.

The Button component is correctly rendered in the web_app when imported and used as a component, and the type checking also works in the web_app when I import the Button.svelte file in the page.svelte file.

What could be causing this error and how can I fix it?


问:
fix music discord bot FFMPEG: TypeError: discord.player.FFmpegPCMAudio() argument after ** must be a mapping, not set
This is my Error:

```<code>Ready ----------------------------------
[youtube] cwTGdXvpmjs: Downloading webpage
[youtube] Downloading just video cwTGdXvpmjs because of --no-playlist
[youtube] cwTGdXvpmjs: Downloading m3u8 information
[youtube] cwTGdXvpmjs: Downloading MPD manifest
Ignoring exception in command play:
Traceback (most recent call last):
  File "E:\lib\site-packages\discord\ext\commands\core.py", line 85, in wrapped
    ret = await coro(*args, **kwargs)
  File "g:\code\hudba\music_cog.py", line 173, in play
    await self.play_music(ctx)
  File "g:\code\hudba\music_cog.py", line 133, in play_music
    self.vc[id].play(discord.FFmpegPCMAudio(
TypeError: discord.player.FFmpegPCMAudio() argument after ** must be a mapping, not set

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "E:\lib\site-packages\discord\ext\commands\bot.py", line 939, in invoke
    await ctx.command.invoke(ctx)
  File "E:\lib\site-packages\discord\ext\commands\core.py", line 863, in invoke
    await injected(*ctx.args, **ctx.kwargs)
  File "E:\lib\site-packages\discord\ext\commands\core.py", line 94, in wrapped
    raise CommandInvokeError(exc) from exc
discord.ext.commands.errors.CommandInvokeError: Command raised an exception: TypeError: discord.player.FFmpegPCMAudio() argument after ** must be a mapping, not set
</code>```

it I don't know how to fix this. It downloads, on discord it sends thumnail of the song, but it doesn't play.

If I have problem with code, or with FFMPEG

main.py

```<code>import discord
from discord.ext import commands
from discord_components import ComponentsBot

from music_cog import music_cog
from help_cog import help_cog

intents = discord.Intents.default()
intents.messages = True

bot = commands.Bot(command_prefix='!', intents=intents)

bot.remove_command('help')
bot.add_cog(help_cog(bot))
bot.add_cog(music_cog(bot))

bot.run('TOKEN)
</code>```

music_cog.py

!join, !leave works, !play doesn'T bcs it doesn't play music

```<code>import discord
from discord_components import Select, SelectOption, Button
from discord.ext import commands

import asyncio
from asyncio import run_coroutine_threadsafe
from urllib import parse, request
import re
import json
from youtube_dl import YoutubeDL

class music_cog(commands.Cog):
    def __init__(self, bot):
        self.bot = bot

        self.is_playing = {}
        self.is_paused = {}
        self.music_queue = {}
        self.queueIndex = {}
        self.YDL_OPTIONS = {format: 'bestaudio', 'noplaylist': 'True'}
        self.FFMPEG_OPTIONS = {'before_options:' '-reconnect 1 -reconnect_streamed 1 -reconnect_delay_max 5', 'options' '-vn'}

        self.embedBlue = 0x2c76dd
        self.embedRed = 0xdf1147
        self.embedGreen = 0x0eaa51

        self.vc = {}
    @commands.Cog.listener()
    async def on_ready(self):
        print(f"Ready ----------------------------------")
        for guild in self.bot.guilds:
            id = int(guild.id)
            self.music_queue[id] = []
            self.queueIndex[id] = 0
            self.vc[id] = None
            self.is_paused[id] = self.is_playing[id] = False

    @commands.Cog.listener()
    async def on_voice_state_update(self, member, before, after):
        id = int(member.guild.id)
        if member.id != self.bot.user.id and before.channel != None and after.channel != before.channel:
            remainingChannelMembers = before.channel.members
            if len(remainingChannelMembers) == 1 and remainingChannelMembers[0].id == self.bot.user.id and self.vc[id].is_connected():
                self.is_playing[id] = self.is_paused[id] = False
                self.music_queue[id] = []
                self.queueIndex[id] = 0
                await self.vc[id].disconnect()

    def now_playing_embed(self, ctx, song):
        title = song['title']
        link = song['link']
        thumbnail = song['thumbnail']
        author= ctx.author
        avatar = author.avatar_url

        embed = discord.Embed(
            title="Now Playing",
            description=f'[{title}],({link})',
            colour=self.embedBlue,
        )
        embed.set_thumbnail(url=thumbnail)
        embed.set_footer(text=f'Song pustil: {str(author)}', icon_url=avatar)
        return embed

    async def join_vc(self, ctx, channel):
        id = int(ctx.guild.id)
        if self.vc[id] == None or not self.vc[id].is_connected():
            self.vc[id] = await channel.connect()

            if self.vc[id] == None:
                await ctx.send("Nepodařilo se připojit do VOICU")
                return
        else:
            await self.vc[id].move_to(channel)

    def search_YT(self, search):
        queryString = parse.urlencode({'search_query': search})
        htmContent = request.urlopen(
            'http://www.youtube.com/results?' + queryString)
        searchResults = re.findall(
            '/watch\?v=(.{11})', htmContent.read().decode())
        return searchResults[0:10]

    def extract_YT(self, url):
        with YoutubeDL(self.YDL_OPTIONS) as ydl:
            try:
                info = ydl.extract_info(url, download=False)
            except:
                return False

        return {
                    'link': 'https://www.youtube.com/watch?v=' + url,
                    'thumbnail': 'https://i.ytimg.com/vi/' + url + '/hqdefault.jpg?sqp=-oaymwEcCOADEI4CSFXyq4qpAw4IARUAAIhCGAFwAcABBg==&rs=AOn4CLD5uL4xKN-IUfez6KIW_j5y70mlig',
                    'source': info['formats'][0]['url'],
                    'title': info['title']
        }
    def play_next(self, ctx):
        id = int(ctx.guild.id)
        if not self.is_playing[id]:
            return
        if self.queueIndex[id] +1   < len(self.music_queue[id]):
            self.is_playing[id] = True
            self.queueIndex[id] += 1

            song = self.music_queue[id][self.queueIndex[id]][0]
            message = self.now_playing_embed(ctx, song)
            coro = ctx.send(embed=message)
            fut = run_coroutine_threadsafe(coro, self.bot.loop)
            try:
                fut.result()
            except:
                pass
            self.vc[id].play(discord.FFmpegPCMAudio(
                song['source'], **self.FFMPEG_OPTIONS), after=lambda e: self.play_next(ctx))
        else:
            self.queueIndex[id] += 1
            self.is_playing[id] = False

    async def play_music(self,ctx):
        id = int(ctx.guild.id)
        if self.queueIndex[id] < len(self.music_queue[id]):
            self.is_playing[id] = True
            self.is_paused[id] = False

            await self.join_vc(ctx ,self.music_queue[id][self.queueIndex[id]][1])

            song = self.music_queue[id][self.queueIndex[id]][0]
            message = self.now_playing_embed(ctx, song)
            await ctx.send(embed=message)

            self.vc[id].play(discord.FFmpegPCMAudio(
                song['source'], **self.FFMPEG_OPTIONS), after=lambda e: self.play_next(ctx))
        else:
            await ctx.send("Ve Frontě už není co dál pustit. Pusť tam další songu!")
            self.queueIndex[id] += 1
            self.is_playing[id] = False

    @ commands.command(
        name="play",
        aliases=["pl"],
        help = "Připojí bota do VOICE ROOMKY"
    )
    async def play(self, ctx, *args):
        search = " ".join(args)
        id = int(ctx.guild.id)
        try:
            userChannel = ctx.author.voice.channel
        except:
            await ctx.send("Musíš být ve VOICE")
            return
        if not args:
            if len(self.music_queue[id]) == 0:
                await ctx.send("Ve Frontě už není co dál pustit. Pusť tam další songu!")
            elif not self.is_playing[id]:
                if self.music_queue[id] == None or self.vc[id] == None:
                    await self.play_music(ctx)
                else:
                    self.is_paused[id] = False
                    self.is_playing[id] = True
                    self.vc[id].resume()
            else:
                return
        else:
            song = self.extract_YT(self.search_YT(search)[0])
            if type(song) == type(True):
                await ctx.send("Nepodařilo se pustit songu. Zkus zadat jiný název.")
            else:
                self.music_queue[id].append([song, userChannel])

                if not self.is_playing[id]:
                    await self.play_music(ctx)
                else:
                    message = "Mes"
                    await ctx.send(embed=message)

    @ commands.command(
        name="join",
        aliases=["j"],
        help = "Připojí bota do VOICE ROOMKY"
    )
    async def join(self, ctx):
        if ctx.author.voice:
            userChannel = ctx.author.voice.channel
            await self.join_vc(ctx, userChannel)
            await ctx.send(f"Hudbot se připojil {userChannel}")
        else:
            await ctx.send("Musíš být připojen ve VOICU")

    @ commands.command(
        name="leave",
        aliases=["l"],
        help = "Odpojí bota do VOICE ROOMKY"
    )
    async def leave(self, ctx):
        id = int(ctx.guild.id)
        self.is_playing[id] = False
        self.is_paused[id] = False
        self.music_queue[id] = []
        self.queueIndex[id] = 0
        if self.vc[id] != None:
            await ctx.send("Hudbot se odpojil.")
            await self.vc[id].disconnect()

</code>```

help_cog.py

```<code>import discord
from discord.ext import commands

class help_cog(commands.Cog):
    def __init__(self, bot):
        self.bot = bot
        self.embedOrange = 0xeab148

    @commands.Cog.listener()
    async def on_ready(self):
        sendToChannels = []
        for guild in self.bot.guilds:
            channel = guild.text_channels[0]
            sendToChannels.append(channel)
        helloEmbed = discord.Embed(
            title="Hello There!",
            description="""
            Hello, I'm GeraldTheBot! You can type any command after typing my prefix **`'!'`** to activate them. Use **`!help`** to see some command options.""",
            # Here is a link to my [source code](https://github.com/TheRealDulanOoga/Bobbert.git) if you wanted to check it out!
            colour=self.embedOrange
        )
        for channel in sendToChannels:
            await channel.send(embed=helloEmbed)

    @commands.command(
        name="help",
        aliases=["h"],
        help="Provides a description of all specified commands"
    )
    async def help(self, ctx):
        helpCog = self.bot.get_cog('help_cog')
        musicCog = self.bot.get_cog('music_cog')
        commands = helpCog.get_commands() + musicCog.get_commands()
        commandDescription = ""

        for c in commands:
            commandDescription += f"**`!{c.name}`** {c.help}\n"
        commandsEmbed = discord.Embed(
            title="Commands List",
            description=commandDescription,
            colour=self.embedOrange
        )

        await ctx.send(embed=commandsEmbed)
</code>```

ignore this text:

asebakj EALEGKAH EAKH EKAGE AGE AGEG AHJEGAEGAO EGHA

Body:
This is my Error:

Ready ----------------------------------
[youtube] cwTGdXvpmjs: Downloading webpage
[youtube] Downloading just video cwTGdXvpmjs because of --no-playlist
[youtube] cwTGdXvpmjs: Downloading m3u8 information
[youtube] cwTGdXvpmjs: Downloading MPD manifest
Ignoring exception in command play:
Traceback (most recent call last):
  File "E:\lib\site-packages\discord\ext\commands\core.py", line 85, in wrapped
    ret = await coro(*args, **kwargs)
  File "g:\code\hudba\music_cog.py", line 173, in play
    await self.play_music(ctx)
  File "g:\code\hudba\music_cog.py", line 133, in play_music
    self.vc[id].play(discord.FFmpegPCMAudio(
TypeError: discord.player.FFmpegPCMAudio() argument after ** must be a mapping, not set

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "E:\lib\site-packages\discord\ext\commands\bot.py", line 939, in invoke
    await ctx.command.invoke(ctx)
  File "E:\lib\site-packages\discord\ext\commands\core.py", line 863, in invoke
    await injected(*ctx.args, **ctx.kwargs)
  File "E:\lib\site-packages\discord\ext\commands\core.py", line 94, in wrapped
    raise CommandInvokeError(exc) from exc
discord.ext.commands.errors.CommandInvokeError: Command raised an exception: TypeError: discord.player.FFmpegPCMAudio() argument after ** must be a mapping, not set

it I don't know how to fix this. It downloads, on discord it sends thumnail of the song, but it doesn't play.

If I have problem with code, or with FFMPEG

main.py

import discord
from discord.ext import commands
from discord_components import ComponentsBot

from music_cog import music_cog
from help_cog import help_cog

intents = discord.Intents.default()
intents.messages = True

bot = commands.Bot(command_prefix='!', intents=intents)

bot.remove_command('help')
bot.add_cog(help_cog(bot))
bot.add_cog(music_cog(bot))

bot.run('TOKEN)

music_cog.py

!join, !leave works, !play doesn'T bcs it doesn't play music

import discord
from discord_components import Select, SelectOption, Button
from discord.ext import commands

import asyncio
from asyncio import run_coroutine_threadsafe
from urllib import parse, request
import re
import json
from youtube_dl import YoutubeDL

class music_cog(commands.Cog):
    def __init__(self, bot):
        self.bot = bot

        self.is_playing = {}
        self.is_paused = {}
        self.music_queue = {}
        self.queueIndex = {}
        self.YDL_OPTIONS = {format: 'bestaudio', 'noplaylist': 'True'}
        self.FFMPEG_OPTIONS = {'before_options:' '-reconnect 1 -reconnect_streamed 1 -reconnect_delay_max 5', 'options' '-vn'}

        self.embedBlue = 0x2c76dd
        self.embedRed = 0xdf1147
        self.embedGreen = 0x0eaa51

        self.vc = {}
    @commands.Cog.listener()
    async def on_ready(self):
        print(f"Ready ----------------------------------")
        for guild in self.bot.guilds:
            id = int(guild.id)
            self.music_queue[id] = []
            self.queueIndex[id] = 0
            self.vc[id] = None
            self.is_paused[id] = self.is_playing[id] = False

    @commands.Cog.listener()
    async def on_voice_state_update(self, member, before, after):
        id = int(member.guild.id)
        if member.id != self.bot.user.id and before.channel != None and after.channel != before.channel:
            remainingChannelMembers = before.channel.members
            if len(remainingChannelMembers) == 1 and remainingChannelMembers[0].id == self.bot.user.id and self.vc[id].is_connected():
                self.is_playing[id] = self.is_paused[id] = False
                self.music_queue[id] = []
                self.queueIndex[id] = 0
                await self.vc[id].disconnect()

    def now_playing_embed(self, ctx, song):
        title = song['title']
        link = song['link']
        thumbnail = song['thumbnail']
        author= ctx.author
        avatar = author.avatar_url

        embed = discord.Embed(
            title="Now Playing",
            description=f'[{title}],({link})',
            colour=self.embedBlue,
        )
        embed.set_thumbnail(url=thumbnail)
        embed.set_footer(text=f'Song pustil: {str(author)}', icon_url=avatar)
        return embed

    async def join_vc(self, ctx, channel):
        id = int(ctx.guild.id)
        if self.vc[id] == None or not self.vc[id].is_connected():
            self.vc[id] = await channel.connect()

            if self.vc[id] == None:
                await ctx.send("Nepodařilo se připojit do VOICU")
                return
        else:
            await self.vc[id].move_to(channel)

    def search_YT(self, search):
        queryString = parse.urlencode({'search_query': search})
        htmContent = request.urlopen(
            'http://www.youtube.com/results?' + queryString)
        searchResults = re.findall(
            '/watch\?v=(.{11})', htmContent.read().decode())
        return searchResults[0:10]

    def extract_YT(self, url):
        with YoutubeDL(self.YDL_OPTIONS) as ydl:
            try:
                info = ydl.extract_info(url, download=False)
            except:
                return False

        return {
                    'link': 'https://www.youtube.com/watch?v=' + url,
                    'thumbnail': 'https://i.ytimg.com/vi/' + url + '/hqdefault.jpg?sqp=-oaymwEcCOADEI4CSFXyq4qpAw4IARUAAIhCGAFwAcABBg==&rs=AOn4CLD5uL4xKN-IUfez6KIW_j5y70mlig',
                    'source': info['formats'][0]['url'],
                    'title': info['title']
        }
    def play_next(self, ctx):
        id = int(ctx.guild.id)
        if not self.is_playing[id]:
            return
        if self.queueIndex[id] +1   < len(self.music_queue[id]):
            self.is_playing[id] = True
            self.queueIndex[id] += 1

            song = self.music_queue[id][self.queueIndex[id]][0]
            message = self.now_playing_embed(ctx, song)
            coro = ctx.send(embed=message)
            fut = run_coroutine_threadsafe(coro, self.bot.loop)
            try:
                fut.result()
            except:
                pass
            self.vc[id].play(discord.FFmpegPCMAudio(
                song['source'], **self.FFMPEG_OPTIONS), after=lambda e: self.play_next(ctx))
        else:
            self.queueIndex[id] += 1
            self.is_playing[id] = False

    async def play_music(self,ctx):
        id = int(ctx.guild.id)
        if self.queueIndex[id] < len(self.music_queue[id]):
            self.is_playing[id] = True
            self.is_paused[id] = False

            await self.join_vc(ctx ,self.music_queue[id][self.queueIndex[id]][1])

            song = self.music_queue[id][self.queueIndex[id]][0]
            message = self.now_playing_embed(ctx, song)
            await ctx.send(embed=message)

            self.vc[id].play(discord.FFmpegPCMAudio(
                song['source'], **self.FFMPEG_OPTIONS), after=lambda e: self.play_next(ctx))
        else:
            await ctx.send("Ve Frontě už není co dál pustit. Pusť tam další songu!")
            self.queueIndex[id] += 1
            self.is_playing[id] = False

    @ commands.command(
        name="play",
        aliases=["pl"],
        help = "Připojí bota do VOICE ROOMKY"
    )
    async def play(self, ctx, *args):
        search = " ".join(args)
        id = int(ctx.guild.id)
        try:
            userChannel = ctx.author.voice.channel
        except:
            await ctx.send("Musíš být ve VOICE")
            return
        if not args:
            if len(self.music_queue[id]) == 0:
                await ctx.send("Ve Frontě už není co dál pustit. Pusť tam další songu!")
            elif not self.is_playing[id]:
                if self.music_queue[id] == None or self.vc[id] == None:
                    await self.play_music(ctx)
                else:
                    self.is_paused[id] = False
                    self.is_playing[id] = True
                    self.vc[id].resume()
            else:
                return
        else:
            song = self.extract_YT(self.search_YT(search)[0])
            if type(song) == type(True):
                await ctx.send("Nepodařilo se pustit songu. Zkus zadat jiný název.")
            else:
                self.music_queue[id].append([song, userChannel])

                if not self.is_playing[id]:
                    await self.play_music(ctx)
                else:
                    message = "Mes"
                    await ctx.send(embed=message)

    @ commands.command(
        name="join",
        aliases=["j"],
        help = "Připojí bota do VOICE ROOMKY"
    )
    async def join(self, ctx):
        if ctx.author.voice:
            userChannel = ctx.author.voice.channel
            await self.join_vc(ctx, userChannel)
            await ctx.send(f"Hudbot se připojil {userChannel}")
        else:
            await ctx.send("Musíš být připojen ve VOICU")

    @ commands.command(
        name="leave",
        aliases=["l"],
        help = "Odpojí bota do VOICE ROOMKY"
    )
    async def leave(self, ctx):
        id = int(ctx.guild.id)
        self.is_playing[id] = False
        self.is_paused[id] = False
        self.music_queue[id] = []
        self.queueIndex[id] = 0
        if self.vc[id] != None:
            await ctx.send("Hudbot se odpojil.")
            await self.vc[id].disconnect()

help_cog.py

import discord
from discord.ext import commands

class help_cog(commands.Cog):
    def __init__(self, bot):
        self.bot = bot
        self.embedOrange = 0xeab148

    @commands.Cog.listener()
    async def on_ready(self):
        sendToChannels = []
        for guild in self.bot.guilds:
            channel = guild.text_channels[0]
            sendToChannels.append(channel)
        helloEmbed = discord.Embed(
            title="Hello There!",
            description="""
            Hello, I'm GeraldTheBot! You can type any command after typing my prefix **`'!'`** to activate them. Use **`!help`** to see some command options.""",
            # Here is a link to my [source code](https://github.com/TheRealDulanOoga/Bobbert.git) if you wanted to check it out!
            colour=self.embedOrange
        )
        for channel in sendToChannels:
            await channel.send(embed=helloEmbed)

    @commands.command(
        name="help",
        aliases=["h"],
        help="Provides a description of all specified commands"
    )
    async def help(self, ctx):
        helpCog = self.bot.get_cog('help_cog')
        musicCog = self.bot.get_cog('music_cog')
        commands = helpCog.get_commands() + musicCog.get_commands()
        commandDescription = ""

        for c in commands:
            commandDescription += f"**`!{c.name}`** {c.help}\n"
        commandsEmbed = discord.Embed(
            title="Commands List",
            description=commandDescription,
            colour=self.embedOrange
        )

        await ctx.send(embed=commandsEmbed)

ignore this text:

asebakj EALEGKAH EAKH EKAGE AGE AGEG AHJEGAEGAO EGHA


问:
Why does my Selenium VBA code no longer work?
I have a very simple VGA macro in Excel that worked fine for awhile and now has stopped.  I now get one of the two error message below:

The code is somewhat longer, but I've taken out the irrelevant lines; even what I have below doesn't work:

```<code>Public edgebot As WebDriver
Sub EUPatentClass()
edgebot.Start "edge"
End Sub
</code>```

The references are as follows:

Current version of Edge is Version 108.0.1462.54 (Official build) (64-bit)
Current version of edgedriver.exe (renamed from msedgedriver.ext) is also Version 108.0.1462.54

I've tried uninstalling and then reinstalling Selenium 2.0.9, and also repairing .NET Core Runtime 3.1.32(x64) and .NET SDK 6.0.307(x64).  I'm running Windows 10, ver 22H2 (Build 19045.2364), fully patched and up to date.

Can anyone give me a suggestion as to what to try next?  THANKS!!!

Body:
I have a very simple VGA macro in Excel that worked fine for awhile and now has stopped.  I now get one of the two error message below:

The code is somewhat longer, but I've taken out the irrelevant lines; even what I have below doesn't work:

Public edgebot As WebDriver
Sub EUPatentClass()
edgebot.Start "edge"
End Sub

The references are as follows:

Current version of Edge is Version 108.0.1462.54 (Official build) (64-bit)
Current version of edgedriver.exe (renamed from msedgedriver.ext) is also Version 108.0.1462.54

I've tried uninstalling and then reinstalling Selenium 2.0.9, and also repairing .NET Core Runtime 3.1.32(x64) and .NET SDK 6.0.307(x64).  I'm running Windows 10, ver 22H2 (Build 19045.2364), fully patched and up to date.

Can anyone give me a suggestion as to what to try next?  THANKS!!!


问:
Adding an Extra character in a .mrc script
I'm using a .mrc script to add a data output to irc currently I'm outputting like this -----> [iNFO] - 12 / 125M/S. What I would like to do is output like this [iNFO] - 12F / 125M/S, so what I need is to add the "F" after the 12.

Here's the code snippet I use

```<code>`scon 19 msg #test [iNFO] - $remove($strip($4),$chr(44)) F / $remove($strip($6),$chr(44))`
</code>```

As you can see that outputs like this [iNFO] - 12 F / 125M/S so I need to remove the space between the "12" and the "F".

Any help would be greatly appreciated.

Body:
I'm using a .mrc script to add a data output to irc currently I'm outputting like this -----> [iNFO] - 12 / 125M/S. What I would like to do is output like this [iNFO] - 12F / 125M/S, so what I need is to add the "F" after the 12.

Here's the code snippet I use

`scon 19 msg #test [iNFO] - $remove($strip($4),$chr(44)) F / $remove($strip($6),$chr(44))`

As you can see that outputs like this [iNFO] - 12 F / 125M/S so I need to remove the space between the "12" and the "F".

Any help would be greatly appreciated.


问:
Jupyter Notebook not running
I've tried installing Jupyter Notebook and it says for everything "Requirement already Satisfied"

```<code>Requirement already satisfied: nbconvert in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter) (7.2.7)
Requirement already satisfied: jupyter-console in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter) (6.4.4)
Requirement already satisfied: notebook in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter) (6.5.2)
Requirement already satisfied: ipywidgets in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter) (8.0.4)
Requirement already satisfied: ipykernel in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter) (6.19.4)
Requirement already satisfied: qtconsole in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter) (5.4.0)
Requirement already satisfied: debugpy>=1.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipykernel->jupyter) (1.6.4)
Requirement already satisfied: ipython>=7.23.1 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipykernel->jupyter) (8.7.0)
Requirement already satisfied: comm>=0.1.1 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipykernel->jupyter) (0.1.2)
Requirement already satisfied: packaging in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipykernel->jupyter) (22.0)
Requirement already satisfied: pyzmq>=17 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipykernel->jupyter) (24.0.1)
Requirement already satisfied: matplotlib-inline>=0.1 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipykernel->jupyter) (0.1.6)
Requirement already satisfied: tornado>=6.1 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipykernel->jupyter) (6.2)
Requirement already satisfied: psutil in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipykernel->jupyter) (5.9.4)
Requirement already satisfied: nest-asyncio in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipykernel->jupyter) (1.5.6)
Requirement already satisfied: traitlets>=5.4.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipykernel->jupyter) (5.8.0)
Requirement already satisfied: jupyter-client>=6.1.12 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipykernel->jupyter) (7.4.8)
Requirement already satisfied: widgetsnbextension~=4.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipywidgets->jupyter) (4.0.5)
Requirement already satisfied: jupyterlab-widgets~=3.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipywidgets->jupyter) (3.0.5)
Requirement already satisfied: prompt-toolkit!=3.0.0,!=3.0.1,<3.1.0,>=2.0.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter-console->jupyter) (3.0.36)
Requirement already satisfied: pygments in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter-console->jupyter) (2.13.0)
Requirement already satisfied: beautifulsoup4 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from nbconvert->jupyter) (4.11.1)
Requirement already satisfied: mistune<3,>=2.0.3 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from nbconvert->jupyter) (2.0.4)
Requirement already satisfied: nbformat>=5.1 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from nbconvert->jupyter) (5.7.1)
Requirement already satisfied: bleach in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from nbconvert->jupyter) (5.0.1)
Requirement already satisfied: jinja2>=3.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from nbconvert->jupyter) (3.1.2)
Requirement already satisfied: jupyter-core>=4.7 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from nbconvert->jupyter) (5.1.1)
Requirement already satisfied: markupsafe>=2.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from nbconvert->jupyter) (2.1.1)
Requirement already satisfied: nbclient>=0.5.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from nbconvert->jupyter) (0.7.2)
Requirement already satisfied: pandocfilters>=1.4.1 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from nbconvert->jupyter) (1.5.0)
Requirement already satisfied: jupyterlab-pygments in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from nbconvert->jupyter) (0.2.2)
Requirement already satisfied: tinycss2 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from nbconvert->jupyter) (1.2.1)
Requirement already satisfied: defusedxml in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from nbconvert->jupyter) (0.7.1)
Requirement already satisfied: argon2-cffi in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from notebook->jupyter) (21.3.0)
Requirement already satisfied: Send2Trash>=1.8.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from notebook->jupyter) (1.8.0)
Requirement already satisfied: nbclassic>=0.4.7 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from notebook->jupyter) (0.4.8)
Requirement already satisfied: terminado>=0.8.3 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from notebook->jupyter) (0.17.1)
Requirement already satisfied: prometheus-client in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from notebook->jupyter) (0.15.0)
Requirement already satisfied: ipython-genutils in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from notebook->jupyter) (0.2.0)
Requirement already satisfied: qtpy>=2.0.1 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from qtconsole->jupyter) (2.3.0)
Requirement already satisfied: decorator in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipython>=7.23.1->ipykernel->jupyter) (5.1.1)
Requirement already satisfied: backcall in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipython>=7.23.1->ipykernel->jupyter) (0.2.0)
Requirement already satisfied: colorama in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipython>=7.23.1->ipykernel->jupyter) (0.4.6)
Requirement already satisfied: pickleshare in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipython>=7.23.1->ipykernel->jupyter) (0.7.5)
Requirement already satisfied: jedi>=0.16 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipython>=7.23.1->ipykernel->jupyter) (0.18.2)
Requirement already satisfied: stack-data in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipython>=7.23.1->ipykernel->jupyter) (0.6.2)
Requirement already satisfied: entrypoints in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter-client>=6.1.12->ipykernel->jupyter) (0.4)
Requirement already satisfied: python-dateutil>=2.8.2 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter-client>=6.1.12->ipykernel->jupyter) (2.8.2)
Requirement already satisfied: pywin32>=1.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter-core>=4.7->nbconvert->jupyter) (305)
Requirement already satisfied: platformdirs>=2.5 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter-core>=4.7->nbconvert->jupyter) (2.6.0)
Requirement already satisfied: notebook-shim>=0.1.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from nbclassic>=0.4.7->notebook->jupyter) (0.2.2)
Requirement already satisfied: jupyter-server>=1.8 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from nbclassic>=0.4.7->notebook->jupyter) (2.0.4)
Requirement already satisfied: jsonschema>=2.6 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from nbformat>=5.1->nbconvert->jupyter) (4.17.3)
Requirement already satisfied: fastjsonschema in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from nbformat>=5.1->nbconvert->jupyter) (2.16.2)
Requirement already satisfied: wcwidth in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from prompt-toolkit!=3.0.0,!=3.0.1,<3.1.0,>=2.0.0->jupyter-console->jupyter) (0.2.5)
Requirement already satisfied: pywinpty>=1.1.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from terminado>=0.8.3->notebook->jupyter) (2.0.9)
Requirement already satisfied: argon2-cffi-bindings in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from argon2-cffi->notebook->jupyter) (21.2.0)
Requirement already satisfied: soupsieve>1.2 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from beautifulsoup4->nbconvert->jupyter) (2.3.2.post1)
Requirement already satisfied: six>=1.9.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from bleach->nbconvert->jupyter) (1.16.0)
Requirement already satisfied: webencodings in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from bleach->nbconvert->jupyter) (0.5.1)
Requirement already satisfied: parso<0.9.0,>=0.8.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jedi>=0.16->ipython>=7.23.1->ipykernel->jupyter) (0.8.3)
Requirement already satisfied: attrs>=17.4.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jsonschema>=2.6->nbformat>=5.1->nbconvert->jupyter) (22.2.0)
Requirement already satisfied: pyrsistent!=0.17.0,!=0.17.1,!=0.17.2,>=0.14.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jsonschema>=2.6->nbformat>=5.1->nbconvert->jupyter) (0.19.2)
Requirement already satisfied: jupyter-server-terminals in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter-server>=1.8->nbclassic>=0.4.7->notebook->jupyter) (0.4.3)
Requirement already satisfied: anyio<4,>=3.1.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter-server>=1.8->nbclassic>=0.4.7->notebook->jupyter) (3.6.2)
Requirement already satisfied: websocket-client in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter-server>=1.8->nbclassic>=0.4.7->notebook->jupyter) (1.4.2)
Requirement already satisfied: jupyter-events>=0.4.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter-server>=1.8->nbclassic>=0.4.7->notebook->jupyter) (0.5.0)
Requirement already satisfied: cffi>=1.0.1 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from argon2-cffi-bindings->argon2-cffi->notebook->jupyter) (1.15.1)
Requirement already satisfied: asttokens>=2.1.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from stack-data->ipython>=7.23.1->ipykernel->jupyter) (2.2.1)
Requirement already satisfied: pure-eval in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from stack-data->ipython>=7.23.1->ipykernel->jupyter) (0.2.2)
Requirement already satisfied: executing>=1.2.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from stack-data->ipython>=7.23.1->ipykernel->jupyter) (1.2.0)
Requirement already satisfied: idna>=2.8 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from anyio<4,>=3.1.0->jupyter-server>=1.8->nbclassic>=0.4.7->notebook->jupyter) (3.4)
Requirement already satisfied: sniffio>=1.1 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from anyio<4,>=3.1.0->jupyter-server>=1.8->nbclassic>=0.4.7->notebook->jupyter) (1.3.0)
Requirement already satisfied: pycparser in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from cffi>=1.0.1->argon2-cffi-bindings->argon2-cffi->notebook->jupyter) (2.21)
Requirement already satisfied: pyyaml in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter-events>=0.4.0->jupyter-server>=1.8->nbclassic>=0.4.7->notebook->jupyter) (6.0)
Requirement already satisfied: python-json-logger in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter-events>=0.4.0->jupyter-server>=1.8->nbclassic>=0.4.7->notebook->jupyter) (2.0.4)
Requirement already satisfied: isoduration in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jsonschema>=2.6->nbformat>=5.1->nbconvert->jupyter) (20.11.0)
Requirement already satisfied: rfc3339-validator in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jsonschema>=2.6->nbformat>=5.1->nbconvert->jupyter) (0.1.4)
Requirement already satisfied: rfc3986-validator>0.1.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jsonschema>=2.6->nbformat>=5.1->nbconvert->jupyter) (0.1.1)
Requirement already satisfied: fqdn in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jsonschema>=2.6->nbformat>=5.1->nbconvert->jupyter) (1.5.1)
Requirement already satisfied: webcolors>=1.11 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jsonschema>=2.6->nbformat>=5.1->nbconvert->jupyter) (1.12)
Requirement already satisfied: uri-template in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jsonschema>=2.6->nbformat>=5.1->nbconvert->jupyter) (1.2.0)
Requirement already satisfied: jsonpointer>1.13 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jsonschema>=2.6->nbformat>=5.1->nbconvert->jupyter) (2.3)
Requirement already satisfied: arrow>=0.15.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from isoduration->jsonschema>=2.6->nbformat>=5.1->nbconvert->jupyter) (1.2.3)
</code>```

But when I run Jupyter Notebook I get:
'jupyter' is not recognized as an internal or external command,
operable program or batch file.

I have tried adding

```<code>c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages
</code>```

to both PATH environment variables but no luck

Title: Jupyter Notebook not running

Body:
I've tried installing Jupyter Notebook and it says for everything "Requirement already Satisfied"

Requirement already satisfied: nbconvert in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter) (7.2.7)
Requirement already satisfied: jupyter-console in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter) (6.4.4)
Requirement already satisfied: notebook in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter) (6.5.2)
Requirement already satisfied: ipywidgets in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter) (8.0.4)
Requirement already satisfied: ipykernel in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter) (6.19.4)
Requirement already satisfied: qtconsole in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter) (5.4.0)
Requirement already satisfied: debugpy>=1.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipykernel->jupyter) (1.6.4)
Requirement already satisfied: ipython>=7.23.1 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipykernel->jupyter) (8.7.0)
Requirement already satisfied: comm>=0.1.1 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipykernel->jupyter) (0.1.2)
Requirement already satisfied: packaging in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipykernel->jupyter) (22.0)
Requirement already satisfied: pyzmq>=17 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipykernel->jupyter) (24.0.1)
Requirement already satisfied: matplotlib-inline>=0.1 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipykernel->jupyter) (0.1.6)
Requirement already satisfied: tornado>=6.1 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipykernel->jupyter) (6.2)
Requirement already satisfied: psutil in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipykernel->jupyter) (5.9.4)
Requirement already satisfied: nest-asyncio in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipykernel->jupyter) (1.5.6)
Requirement already satisfied: traitlets>=5.4.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipykernel->jupyter) (5.8.0)
Requirement already satisfied: jupyter-client>=6.1.12 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipykernel->jupyter) (7.4.8)
Requirement already satisfied: widgetsnbextension~=4.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipywidgets->jupyter) (4.0.5)
Requirement already satisfied: jupyterlab-widgets~=3.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipywidgets->jupyter) (3.0.5)
Requirement already satisfied: prompt-toolkit!=3.0.0,!=3.0.1,<3.1.0,>=2.0.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter-console->jupyter) (3.0.36)
Requirement already satisfied: pygments in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter-console->jupyter) (2.13.0)
Requirement already satisfied: beautifulsoup4 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from nbconvert->jupyter) (4.11.1)
Requirement already satisfied: mistune<3,>=2.0.3 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from nbconvert->jupyter) (2.0.4)
Requirement already satisfied: nbformat>=5.1 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from nbconvert->jupyter) (5.7.1)
Requirement already satisfied: bleach in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from nbconvert->jupyter) (5.0.1)
Requirement already satisfied: jinja2>=3.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from nbconvert->jupyter) (3.1.2)
Requirement already satisfied: jupyter-core>=4.7 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from nbconvert->jupyter) (5.1.1)
Requirement already satisfied: markupsafe>=2.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from nbconvert->jupyter) (2.1.1)
Requirement already satisfied: nbclient>=0.5.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from nbconvert->jupyter) (0.7.2)
Requirement already satisfied: pandocfilters>=1.4.1 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from nbconvert->jupyter) (1.5.0)
Requirement already satisfied: jupyterlab-pygments in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from nbconvert->jupyter) (0.2.2)
Requirement already satisfied: tinycss2 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from nbconvert->jupyter) (1.2.1)
Requirement already satisfied: defusedxml in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from nbconvert->jupyter) (0.7.1)
Requirement already satisfied: argon2-cffi in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from notebook->jupyter) (21.3.0)
Requirement already satisfied: Send2Trash>=1.8.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from notebook->jupyter) (1.8.0)
Requirement already satisfied: nbclassic>=0.4.7 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from notebook->jupyter) (0.4.8)
Requirement already satisfied: terminado>=0.8.3 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from notebook->jupyter) (0.17.1)
Requirement already satisfied: prometheus-client in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from notebook->jupyter) (0.15.0)
Requirement already satisfied: ipython-genutils in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from notebook->jupyter) (0.2.0)
Requirement already satisfied: qtpy>=2.0.1 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from qtconsole->jupyter) (2.3.0)
Requirement already satisfied: decorator in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipython>=7.23.1->ipykernel->jupyter) (5.1.1)
Requirement already satisfied: backcall in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipython>=7.23.1->ipykernel->jupyter) (0.2.0)
Requirement already satisfied: colorama in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipython>=7.23.1->ipykernel->jupyter) (0.4.6)
Requirement already satisfied: pickleshare in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipython>=7.23.1->ipykernel->jupyter) (0.7.5)
Requirement already satisfied: jedi>=0.16 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipython>=7.23.1->ipykernel->jupyter) (0.18.2)
Requirement already satisfied: stack-data in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from ipython>=7.23.1->ipykernel->jupyter) (0.6.2)
Requirement already satisfied: entrypoints in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter-client>=6.1.12->ipykernel->jupyter) (0.4)
Requirement already satisfied: python-dateutil>=2.8.2 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter-client>=6.1.12->ipykernel->jupyter) (2.8.2)
Requirement already satisfied: pywin32>=1.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter-core>=4.7->nbconvert->jupyter) (305)
Requirement already satisfied: platformdirs>=2.5 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter-core>=4.7->nbconvert->jupyter) (2.6.0)
Requirement already satisfied: notebook-shim>=0.1.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from nbclassic>=0.4.7->notebook->jupyter) (0.2.2)
Requirement already satisfied: jupyter-server>=1.8 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from nbclassic>=0.4.7->notebook->jupyter) (2.0.4)
Requirement already satisfied: jsonschema>=2.6 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from nbformat>=5.1->nbconvert->jupyter) (4.17.3)
Requirement already satisfied: fastjsonschema in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from nbformat>=5.1->nbconvert->jupyter) (2.16.2)
Requirement already satisfied: wcwidth in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from prompt-toolkit!=3.0.0,!=3.0.1,<3.1.0,>=2.0.0->jupyter-console->jupyter) (0.2.5)
Requirement already satisfied: pywinpty>=1.1.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from terminado>=0.8.3->notebook->jupyter) (2.0.9)
Requirement already satisfied: argon2-cffi-bindings in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from argon2-cffi->notebook->jupyter) (21.2.0)
Requirement already satisfied: soupsieve>1.2 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from beautifulsoup4->nbconvert->jupyter) (2.3.2.post1)
Requirement already satisfied: six>=1.9.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from bleach->nbconvert->jupyter) (1.16.0)
Requirement already satisfied: webencodings in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from bleach->nbconvert->jupyter) (0.5.1)
Requirement already satisfied: parso<0.9.0,>=0.8.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jedi>=0.16->ipython>=7.23.1->ipykernel->jupyter) (0.8.3)
Requirement already satisfied: attrs>=17.4.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jsonschema>=2.6->nbformat>=5.1->nbconvert->jupyter) (22.2.0)
Requirement already satisfied: pyrsistent!=0.17.0,!=0.17.1,!=0.17.2,>=0.14.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jsonschema>=2.6->nbformat>=5.1->nbconvert->jupyter) (0.19.2)
Requirement already satisfied: jupyter-server-terminals in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter-server>=1.8->nbclassic>=0.4.7->notebook->jupyter) (0.4.3)
Requirement already satisfied: anyio<4,>=3.1.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter-server>=1.8->nbclassic>=0.4.7->notebook->jupyter) (3.6.2)
Requirement already satisfied: websocket-client in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter-server>=1.8->nbclassic>=0.4.7->notebook->jupyter) (1.4.2)
Requirement already satisfied: jupyter-events>=0.4.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter-server>=1.8->nbclassic>=0.4.7->notebook->jupyter) (0.5.0)
Requirement already satisfied: cffi>=1.0.1 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from argon2-cffi-bindings->argon2-cffi->notebook->jupyter) (1.15.1)
Requirement already satisfied: asttokens>=2.1.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from stack-data->ipython>=7.23.1->ipykernel->jupyter) (2.2.1)
Requirement already satisfied: pure-eval in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from stack-data->ipython>=7.23.1->ipykernel->jupyter) (0.2.2)
Requirement already satisfied: executing>=1.2.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from stack-data->ipython>=7.23.1->ipykernel->jupyter) (1.2.0)
Requirement already satisfied: idna>=2.8 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from anyio<4,>=3.1.0->jupyter-server>=1.8->nbclassic>=0.4.7->notebook->jupyter) (3.4)
Requirement already satisfied: sniffio>=1.1 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from anyio<4,>=3.1.0->jupyter-server>=1.8->nbclassic>=0.4.7->notebook->jupyter) (1.3.0)
Requirement already satisfied: pycparser in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from cffi>=1.0.1->argon2-cffi-bindings->argon2-cffi->notebook->jupyter) (2.21)
Requirement already satisfied: pyyaml in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter-events>=0.4.0->jupyter-server>=1.8->nbclassic>=0.4.7->notebook->jupyter) (6.0)
Requirement already satisfied: python-json-logger in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jupyter-events>=0.4.0->jupyter-server>=1.8->nbclassic>=0.4.7->notebook->jupyter) (2.0.4)
Requirement already satisfied: isoduration in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jsonschema>=2.6->nbformat>=5.1->nbconvert->jupyter) (20.11.0)
Requirement already satisfied: rfc3339-validator in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jsonschema>=2.6->nbformat>=5.1->nbconvert->jupyter) (0.1.4)
Requirement already satisfied: rfc3986-validator>0.1.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jsonschema>=2.6->nbformat>=5.1->nbconvert->jupyter) (0.1.1)
Requirement already satisfied: fqdn in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jsonschema>=2.6->nbformat>=5.1->nbconvert->jupyter) (1.5.1)
Requirement already satisfied: webcolors>=1.11 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jsonschema>=2.6->nbformat>=5.1->nbconvert->jupyter) (1.12)
Requirement already satisfied: uri-template in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jsonschema>=2.6->nbformat>=5.1->nbconvert->jupyter) (1.2.0)
Requirement already satisfied: jsonpointer>1.13 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from jsonschema>=2.6->nbformat>=5.1->nbconvert->jupyter) (2.3)
Requirement already satisfied: arrow>=0.15.0 in c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from isoduration->jsonschema>=2.6->nbformat>=5.1->nbconvert->jupyter) (1.2.3)

But when I run Jupyter Notebook I get:
'jupyter' is not recognized as an internal or external command,
operable program or batch file.

I have tried adding

c:\users\david\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages

to both PATH environment variables but no luck