0:00:20
all right welcome back everyone welcome
0:00:24
another episode of will break and fix
0:00:27
um yes to all those people who are new
0:00:29
here we are recorders
0:00:33
we are a team of two developers from
0:00:35
melbourne australia
0:00:36
and we are working on a project which
0:00:38
adds persistent storage to
0:00:42
the current open source project called
0:00:49
so if you're interested in stacks
0:00:53
express.js or fetch apis
0:00:56
or even a bit of front-end with react
0:00:59
and you're looking to get
0:01:01
a hands-on tutorial on things like
0:01:06
on how they work on an actual project
0:01:08
then you're in the right place
0:01:10
um yesterday we worked on
0:01:18
which meant that we tried to test
0:01:21
component of our back-ends um
0:01:24
the tests mainly revolved around a lot
0:01:32
most of them didn't work but
0:01:35
that's okay um let's see part of the
0:01:39
so we're gonna try and go ahead and
0:01:43
one second let me just
0:01:46
yep um i'm gonna try and go ahead and do
0:01:51
to make sure um everything in the
0:01:54
backend is coded properly
0:01:57
yes so i think this starting delivered
0:02:00
hey then i didn't know you were calling
0:02:03
uh no no i i was having a bit of a
0:02:06
technical glitches again so a
0:02:10
few seconds there to just sort
0:02:13
everything out but um
0:02:15
yeah i'm here and good introduction
0:02:17
thank you for that
0:02:21
let's get straight into that um
0:02:26
uh not that are you not getting your
0:02:29
green screen today
0:02:30
and no because it's not working properly
0:02:35
green screen as in the
0:02:38
camera um isn't um
0:02:43
like up to scratch
0:02:45
i just have to saw everything
0:02:50
i know i keep on saying it but um
0:02:54
it is as in a bit like
0:02:57
complicated so yeah i'm just not
0:03:00
getting enough time to set everything up
0:03:03
properly but anyway um
0:03:05
i'll just share my screen and we can
0:03:08
take a look at jira where we were
0:03:14
is that too bright
0:03:17
uh a little bit yeah
0:03:19
yeah that's the lowest it can get oh
0:03:24
that's fine not a problem at all
0:03:29
so we can start off with um validation
0:03:36
and then just um fix the ones that are
0:03:39
not working and just um
0:03:43
so i'm saying that plans should be
0:03:48
we just make sure that the posting of
0:03:51
posting of the notes is working properly
0:03:56
okay yeah that should be
0:04:00
if we are satisfied by posting all the
0:04:04
notes from entire validations as in as
0:04:07
best as we can couples all the scenarios
0:04:15
other methods but my main focus is um
0:04:19
posting all the notes all right
0:04:23
what do you reckon you did yeah no cool
0:04:28
yeah that shouldn't be hard for sure
0:04:30
we'll be able to do it
0:04:32
um i'll recommend you close your emails
0:04:35
yes i'm just gonna do all the
0:04:39
thank you things that i need to close up
0:04:47
word i don't need and
0:04:50
that doesn't matter
0:04:55
i'll open up vs code
0:04:58
all right today is my turn
0:05:00
oh yeah yeah all right come on
0:05:06
i was trying to sneak in there
0:05:31
sorry is your mic whatever
0:05:34
is my mic far enough
0:05:36
i think you can hear it properly
0:05:39
yeah i can but i sometimes feel that
0:05:41
your mic is a bit too loud i don't know
0:05:46
too loud let me check you you can go
0:05:49
ahead and do that from here see my
0:05:50
screen can you see my screen
0:05:54
so if you go here and go on audio
0:05:58
you can decrease that
0:06:03
for some reason i don't get um where did
0:06:07
i'm seeing your screen go to cam slash
0:06:14
um click on it adjust automatic
0:06:17
automatically juice here click on that
0:06:26
yep try speaking oh no
0:06:31
like around 50 should be fine
0:06:34
yeah that should be fine
0:06:40
right um so do you want to open up this
0:06:43
code and then we can
0:06:49
make notes of all the scenarios that we
0:06:55
this url partially working okay cool
0:07:05
for future it might help if we both can
0:07:08
be a bit a bit precise in in terms of
0:07:11
this um issues descriptions or this task
0:07:22
i'll open up the visual studio code as
0:07:26
um by the way i did um push all the
0:07:31
even though they were
0:07:35
we should be in a habit to
0:07:41
after every stream session yeah no for
0:07:48
even if it doesn't work
0:07:56
there are all the other branches
0:08:03
did you guys delete other branches no i
0:08:05
didn't delay any branch
0:08:08
which one i i can't see anything um i'm
0:08:11
talking about this
0:08:13
there are only three branches well you
0:08:18
are you in the right
0:08:24
very interesting let's see oh no no no
0:08:30
um because the repo is public
0:08:35
i'm just a bit scared now
0:08:39
no it doesn't matter if it's public um
0:08:42
that should be fine
0:08:47
yeah um right okay
0:08:51
why is not on my local
0:09:03
you probably have to go on the dead
0:09:05
branch and then do it
0:09:18
let's hope they're there
0:09:27
i mean that's fine do you lock any of
0:09:36
locked um devin master that's all
0:09:48
um instable backhand
0:09:53
that makes more sense
0:09:55
so until now we um
0:09:59
we are making all our changes in the
0:10:01
stable backhand branches
0:10:09
oh forgot to turn my light on
0:10:15
oh my light doesn't work
0:10:19
why is he refusing to work now
0:10:39
okay very good that's fine
0:10:44
trying not to merge it
0:10:51
i'm not even uh pulling all these
0:10:53
branches because i don't actually need
0:10:56
i just need a stable bracket but i don't
0:10:58
want to miss any other branches
0:11:04
so before i start i probably need to
0:11:17
let's hope we can finish this before
0:11:29
cheryl is partially working which meant
0:11:40
what was the command minus d
0:11:52
hang on what are you trying to do at the
0:11:56
i'm doing sound deployed it's screen
0:12:00
um no so screen minus dm
0:12:05
the command itself
0:12:08
yeah i did yeah i did that
0:12:11
that's fine um i'm just gonna do this
0:12:17
i'll just hide it for now don't worry
0:13:16
uh your eyes partially working
0:13:20
i'm careful when you say you're is
0:13:23
partially working did you mean that um
0:13:26
it's working with the empty strings but
0:13:30
other way around where did i say that
0:13:49
all right okay i was like
0:13:53
don't worry about it
0:14:20
first there we get is topic is invalid
0:14:25
but it's actually a single
0:14:27
note right i can't see url again
0:14:39
so topic for now it is invalid
0:14:49
just checking your
0:15:07
now we're trying to switch
0:15:10
this if it's false
0:15:28
so it is single note only
0:16:09
she's coming in there
0:16:14
say setting that to false
0:16:41
however if you do request or
0:16:44
body dot single note
0:16:49
i'm just trying to see
0:16:51
can we not do a type of a constant
0:16:59
hey tory raw coders yeah buddy
0:17:07
right okay that makes sense
0:17:09
so it's a js thing
0:17:12
consists our blogs board um
0:17:16
i don't think we can type off a constant
0:17:35
type off on a constant
0:17:38
i'm just trying to see that only one
0:17:50
probably using cons in the first place
0:17:55
are we using const in the first yes
0:18:47
undefined yep can't do that
0:18:50
new thing learned today
0:18:59
that's a new thing um
0:19:01
and i think it goes back to i'll tell
0:19:03
you why uh thing which we studied
0:19:07
const njsr immutable
0:19:13
let's see if they are
0:19:15
um the cons declaration creates a
0:19:17
read-only reference to a value it does
0:19:19
not mean the value holds is immutable
0:19:22
just that the variable identifier cannot
0:19:25
be reassigned for instance in the case
0:19:28
where constant is an object
0:19:31
the object constants
0:19:34
objects contents can be altered right
0:19:40
okay let's try this um okay
0:20:18
he was having trouble connecting to us
0:20:22
twitch because of the um
0:20:31
like it's been resolved so yeah that's
0:20:42
glad you could make it
0:20:48
sorry tory i couldn't also see your
0:20:50
discord question till now i'm so sorry
0:20:54
um yeah i'll come back to that for sure
0:20:57
but i'm not sure if i'm
0:20:59
i just started learning typescript i
0:21:19
a lot in those companies have service
0:21:36
that's pretty small future well done
0:21:58
uh he's asking you to post a question on
0:22:02
oh you want me to do it yeah sure
0:22:10
looking at this sub cable map
0:22:13
gave me that idea yeah that that's
0:22:18
creative obviously man
0:22:24
should take the heat
0:22:29
he's telling you that
0:22:39
what's gonna cost people calling me noob
0:22:48
in the worst case scenario that
0:22:51
they don't even bother replying
0:23:00
you know what's even more worse of that
0:23:04
first of all they don't bother replying
0:23:07
and then they give you a minus
0:23:12
and you're like guys come on i'm so new
0:23:25
somewhere one second
0:23:28
this is really interesting
0:23:39
i think i know what's happening um i'll
0:23:45
let's see i think in pay programming is
0:23:51
things as well because
0:23:53
you just yeah i i just don't want to
0:23:59
right is empty means that
0:24:08
that's coming as false okay
0:24:29
let's see if this bad boy works
0:24:45
tori's saying you guys should try give
0:24:48
co-pilot it will finish these projects
0:24:54
i actually applied for a guitar pilot oh
0:24:58
got the access yet
0:25:01
what is that though
0:25:07
you should probably have a look yourself
0:25:09
but it's really interesting
0:25:12
it's like a dry code for you like
0:25:15
they have taken all the repositories
0:25:17
they have like github
0:25:21
like they have made like kind of a
0:25:23
really sophisticated software
0:25:26
um no it's called co-pilot my bad
0:25:34
so i did sign up for it
0:25:37
yeah it works on open yeah
0:25:39
so it writes a lot of things itself
0:25:42
okay interesting i might try that
0:25:54
okay let me see if this board is
0:26:05
i think the board is in there wow oh
0:26:08
boy resource not fun
0:26:27
this is my little boy
0:27:22
we'll be out of work
0:27:59
how is it returning
0:28:06
even anything here like the board oh
0:28:09
that's fair that now
0:28:16
topic for notice invalid why
0:28:24
just pointless okay let's see
0:28:31
um the type of text of note
0:28:35
so let's say if we get
0:28:39
this should be true
0:28:45
is empty is doing something dodgy to it
0:28:50
let's see how this works out
0:29:14
oh i just realized that i put my uh i
0:29:17
put my headset on mute
0:29:20
i was talking and like
0:29:26
why am i not getting anything back
0:29:33
uh probably at least two minutes
0:29:40
jack dev's asking can we play um can you
0:29:43
use this please hydrate have your water
0:29:47
no i need to go to the kitchen that's
0:29:53
story goes though actually
0:29:56
the jokes on you i don't have a job
0:30:07
sorry hilarious guy
0:30:22
he's saying that i'm looking pretty dry
0:30:25
what do you mean dry
0:30:53
that's it tori i am so i'm just gonna go
0:30:57
ahead and get a bit of water for myself
0:31:01
i'm to be right back
0:31:06
this is error from cloud front very
0:31:19
all right there we go i'm back in action
0:31:27
did you say that is throwing the air
0:31:29
from cloud front um not really that's
0:31:50
i'll just go get water as well while it
0:31:55
i don't think it will be too long at all
0:32:02
i'm sorry is the coast still coming in
0:32:15
i literally can't comprehend why
0:32:22
hang on i need to check something
0:32:28
as in how we're checking if it's a
0:32:31
string is is even checked in that way
0:32:40
and it's working on other places right
0:32:48
i can't guarantee that
0:32:56
okay why is get all nodes not working
0:33:01
because we don't have a function for
0:33:05
gang on or no well
0:33:20
we can type more fairly oh
0:33:24
uh do you wanna do maybe as in
0:33:37
yeah let's see if that works
0:33:40
i'm just trying to see
0:33:47
looks like you've got a classic type
0:33:54
yes sorry probably
0:33:57
need to figure out as in
0:34:03
is that doing what it's doing
0:34:15
oh wait okay can you just
0:34:24
okay yeah that's more like it
0:34:38
i like that variable name ew
0:34:54
just make sure that because i haven't
0:35:04
lowercase apparently
0:35:23
that should be fine
0:35:46
let's try running this
0:35:54
okay then you'll be running it
0:36:02
i run it um i just need to do one more
0:36:05
thing that's literally the last thing
0:36:11
choice soon to check your params
0:36:14
yeah i don't think there's any problem
0:36:17
with the pram story
0:36:20
uh because it's not just picking up um
0:36:43
lowercase when you're using type of hmm
0:37:14
that's really interesting
0:37:17
because it's getting assigned properly
0:37:23
we're only having a problem when we're
0:37:30
as andre likes to call it a surreal head
0:37:38
and i'm just saying to myself wait
0:37:52
this is ah so it's coming up as one
0:37:58
no so you'll probably have to do
0:38:04
i love you so look
0:38:13
there you go he comes back for it that's
0:38:22
i love that jack dab
0:38:35
okay i should explain
0:38:38
okay let's try this now
0:38:44
work then probably do um
0:38:55
insert a number and then it shouldn't
0:38:59
yeah it's coming as this
0:39:03
jason's stringified it that's why
0:39:08
it's already a string and then choosing
0:39:10
strings and that's why okay
0:39:17
okay i don't wanna just singify it
0:39:27
let me just see what's coming now
0:39:45
but for a really busy evening
0:39:53
how do you know that line 279 works
0:40:08
how do you know that line two 279 works
0:40:14
hmm we can test it
0:40:17
we're not trying to test that line at
0:40:20
the moment and get there we are um
0:40:24
testing the other scenario in which the
0:40:28
as in the topic of the note has to be
0:40:53
there you go that works
0:41:05
what are you doing there
0:41:08
can you make sure return semicolon works
0:41:14
satisfy you get this
0:41:22
he's saying can you please add
0:41:27
works to all lines that work
0:41:31
capture on the left
0:41:34
okay yeah now it totally totally totally
0:41:37
works pretty sure um
0:41:40
yeah i'll just make sure that everything
0:41:49
topic for note is invalid
0:41:54
okay one last test and um this will work
0:42:03
you make it interesting in zero
0:42:06
so are we not checking for if the note
0:42:13
anymore no no no right now um
0:42:17
one step at a time because
0:42:20
i have a feeling that's throwing an
0:42:21
error i mean that was all making it
0:42:28
you know that being said i do want to
0:42:30
test my empty function
0:43:22
i don't think so that's right um
0:43:25
i still want to use um
0:43:28
the keys of your keys
0:43:44
yeah um the thing which i was
0:43:46
using before remember um
0:43:54
i'm just gonna replace it for one second
0:44:03
see now this works
0:44:11
if the object is there or not
0:44:14
all right and if it is dead then return
0:44:17
through this nokia
0:44:22
i don't think so our current is empty
0:44:24
works um i'm not sure what remove
0:44:28
uh so it seems to rub but can you remove
0:44:35
this one yeah sure yeah yeah
0:44:41
uh trying again same i should go yeah
0:44:45
yeah because i was just
0:44:48
i'm not sure why we changed this to this
0:44:52
i remember get there
0:44:54
um told us do you see any error in this
0:44:58
like for us we are not able to get it
0:45:01
work at least at least here
0:45:04
i i see what it's doing
0:45:08
but not sure why it's not working on our
0:45:11
end or it could be just us
0:45:15
the thing which is saying that you
0:45:20
literally equal to and
0:45:25
quote and then open and close curly
0:45:34
and that's what he said is this what he
0:45:41
is this what he said
0:45:43
no so if you remove the json stringify
0:45:53
remove the json string if i
0:46:06
remove this one and then put these curly
0:46:08
brackets only by themselves in quotes
0:46:13
and put another equals
0:46:17
with the other equals yeah
0:46:21
is that what you're saying tori uh give
0:46:26
yes you could go to you straight
0:46:36
they should give us um let's see hi
0:46:40
first that's pretty good okay
0:46:45
nah that doesn't work either no
0:46:47
um it also doesn't work because this is
0:46:51
literally oh hang on a minute
0:46:58
no no no no that's fine that's fine
0:47:07
oh yeah it's going to falls right here
0:47:30
so it's json string is fine
0:47:33
um yeah i don't think so this is ever
0:47:36
i mean this could work if and only if
0:47:39
i just stringified this but
0:47:42
the problem with this is um i'll tell
0:47:44
you what the problem is once again
0:47:49
see this will work now
0:47:53
yeah see this works now
0:47:56
but the problem is that if i don't pass
0:47:58
it anything and if i just pass null
0:48:01
this is gonna go all right
0:48:03
so if i do object keys which is gonna
0:48:09
i'll tell you why i'm more lean towards
0:48:23
actually this could work as well huh
0:48:29
um this only works for um let's see
0:48:38
let's say it's a json object then what
0:48:40
happens we can't check if it's empty or
0:48:52
you know what i mean
0:48:56
this is empty function for should not
0:48:59
only for strings but for like
0:49:01
every object in general
0:49:09
oh i'm actually string okay
0:49:12
yeah see this won't work now
0:49:17
even if i give it like a empty string
0:49:22
um let me just try this as well
0:49:40
oh you've got to put the comma
0:49:47
json objects you created
0:49:53
line 13 here we go
0:49:58
yeah um see now it's actually getting
0:50:02
if i go ahead and try
0:50:06
um don't think it should work but
0:50:14
and try it for like an
0:50:18
it's gonna say undefined and
0:50:22
it's still getting false even though if
0:50:27
anyway um that's been deployed
0:50:30
um i'll come back to that
0:50:32
um so everything should work now here
0:50:35
um i'm giving it a faulty note
0:50:38
let's see what happens
0:50:42
okay this um faulty node it gives an
0:50:50
i'm giving a a and
0:51:04
it will give invalid now
0:51:15
let's see what happens in empty
0:51:19
and this shouldn't work yeah yeah so
0:51:22
um so the problem was that
0:51:25
this is empty method isn't
0:51:28
working for us i'm not saying it's wrong
0:51:32
but for our scenario this is not
0:51:34
functional i don't know why shouldn't
0:51:38
literally equals on 37
0:51:42
um we tried that that doesn't work
0:51:44
um i'll make it literally equal to let's
0:51:48
yeah still doesn't work
0:51:51
all right um in that case we can
0:52:04
um because there must be something we
0:52:11
making it not work
0:52:15
yeah but i really can't as in
0:52:23
need a lot more time and then to
0:52:27
why is that not working
0:52:29
yeah oh i'm not sure if gekko has
0:52:32
something to add if it's probably
0:52:38
let us know what you reckon
0:52:48
toy saying if this is where typescript
0:52:53
jagdev um we're asking about you know
0:53:00
we should compare the
0:53:04
empty objects as in a check for empty
0:53:15
that's apparently not working for us i'm
0:53:18
pretty sure we're doing
0:53:20
something incorrectly so
0:53:31
what you reckon about that
0:53:56
he said are wrecking you two a champs
0:53:59
that deserve to get some war in your
0:54:06
um wait one sec i'm just trying to think
0:55:05
so now are we trying to make
0:55:18
i did something stupid
0:55:23
i just like to reset my mistake
0:55:33
can't you uh undo it as in
0:55:38
see and everything
0:55:40
no it's not working
0:55:45
i've been there after done that many
0:55:51
yeah that's fine i'll just try it real
0:56:02
no jewelry is asking where are you
0:56:05
calling the smt functions
0:56:14
uh is basically for out the code uh for
0:56:19
out the code if we want to check um if
0:56:36
was it on the object
0:56:41
i got i think i got it
0:56:43
um there we go that should
0:56:53
have you had yes uh objectives asking
0:56:56
have you heard about falsey yes i have
0:57:03
is there the better way to do it
0:57:09
i'm i'm just asking housing
0:57:21
yeah that should work
0:58:01
it is equivalent to zero
0:58:04
but it's not okay yeah that's fine
0:58:07
i'm doing something dumb
0:58:48
that the existing demo is for
0:58:51
expressions type of and
0:58:55
started to use it to to
0:58:59
code and test our functions
0:59:02
yeah that's interesting
0:59:13
tori said just will wait till the rest
0:59:15
of the call breaks after this change
0:59:28
why is this only going here
0:59:41
it's not gonna listen the
0:59:46
i'll make it listen the hard way
0:59:53
down okay that should work
0:59:56
okay are you ready then
0:59:59
are you ready to be amazed
1:00:02
if it's true then return false
1:00:11
um i don't think so yeah okay i'm ready
1:00:16
yeah are you ready for amaze now okay
1:00:18
so this is empty it's giving true
1:00:24
you don't pass anything say no
1:00:31
okay finally we have the um
1:00:36
and i dare someone's gonna touch it no
1:00:38
one's gonna touch my
1:00:40
precious little is empty function
1:00:44
um brackets brackets
1:00:50
sam no not sam yet
1:00:54
too early for scam
1:01:02
so we have just done is empty and
1:01:09
yeah let me just verify if that works
1:01:22
come on boys i'll harass you all night
1:01:41
come on tory put some good words mate
1:01:45
good words in the chat
1:01:50
what is break break break
1:02:01
let's see who wins story
1:02:04
if it's you or us i think it's it's the
1:02:07
code which is gonna win
1:02:14
they should give an error
1:02:16
please give an error
1:02:40
and you probably can't send the object
1:02:41
here that we're anywhere so we don't
1:02:46
yeah we don't need something it's fine
1:02:52
i should not even send the object of it
1:02:56
yeah so we don't mean we don't we don't
1:02:58
need that we just have to do a check
1:03:00
that if it's a string
1:03:03
oh wait actually we need it
1:03:05
i'll tell you why because we can pass
1:03:08
the object as this
1:03:16
not space but like
1:03:24
are you empty and it says yes i am empty
1:03:28
so does it true here
1:03:31
oh yeah answer it should do a false
1:03:41
i am empty the naught of that i'm false
1:03:44
yeah i should be fine
1:03:47
so that's basically saying i'm not empty
1:03:53
but you're filled with water and a lot
1:03:57
you're not anything
1:03:59
if i pass zen in that function beyonce
1:04:03
it would definitely be
1:04:07
yes in this scenario it'll be true
1:04:12
did i only in that sound
1:04:16
i know and i'm trying to be nice here
1:04:31
the streams or the stream always
1:04:36
what's happening to my english
1:04:39
my brain is dead literally
1:04:59
work and it does work perfect
1:05:02
so that means that
1:05:07
we're checking for
1:05:29
yeah oh sorry yeah there you go
1:05:34
there you go um yeah you're using the
1:05:43
jira at the moment
1:05:49
so if the talk if the text one note is
1:05:54
that's done isn't it it's working
1:06:03
we are checking if
1:06:05
it's passing an integer
1:06:20
like if the text form
1:06:29
okay cool and work if it's a string only
1:06:38
i'm gonna just check one more thing
1:07:04
right cool okay so i've updated the
1:07:08
validation of the post
1:07:10
uh but i reckon that before
1:07:17
this also works then um no boards found
1:07:21
i deleted all the boards and it worked
1:07:24
so hang on a minute um
1:07:27
no board found in the database
1:07:34
also proves that the asmt method is
1:07:45
and next to the validation messages
1:07:50
next to the validation messages
1:07:58
he is there you go
1:08:02
this works as well what's next
1:08:06
can you go down how can he okay
1:08:09
yeah i'm just gonna test um
1:08:12
but not found just give me one second
1:08:14
post the board then the body forward
1:08:34
let's see what it does
1:08:44
yep posting a board giving it the wrong
1:08:56
okay can we please stick to the plan
1:08:59
yeah yeah i'm just testing the post note
1:09:04
i'm just testing the parts which you
1:09:06
weren't able to test yesterday
1:09:11
that the part of the
1:09:13
posting of the notes right yeah
1:09:22
understanding that you thought you were
1:09:24
going as in back to the boards now right
1:09:27
that's all good that's all good
1:09:35
found in the database was working did
1:09:46
just trying to see one thing
1:09:52
what that's impossible
1:10:02
second let me just see my lambda
1:10:07
not lambda where would i find this
1:10:18
that's interesting
1:10:31
new login cloud watch
1:10:40
yep this is probably the latest one
1:10:43
can you see the errors then i don't know
1:10:45
how to find it here
1:10:56
the error basically isn't even there
1:11:06
no that's not there
1:11:22
to the message that
1:11:23
we were testing in the code
1:11:30
so what are we testing here again what
1:11:33
string or note when board is not found
1:11:36
posting on notes when the board is not
1:11:39
found okay go back in the code
1:11:47
posting a note when the board isn't
1:11:51
which means that you should come to
1:11:53
board not found isn't it
1:11:58
yeah it's working till here
1:12:14
dot board id that should be fine
1:12:19
as i don't know why we have a for loop
1:12:21
why don't we have a scan operation
1:12:23
um that's a story for a different day
1:12:30
so that means that it's coming down to
1:12:32
switch is more present
1:12:38
go in this for present and then
1:12:41
if it's false then
1:12:48
so up there we're checking for that one
1:12:54
your cursor on the opening bracket of
1:13:02
i mean it probably won't even compile if
1:13:04
the brackets were ah
1:13:11
right i think there's the problem
1:13:15
oh you have it inside the for loop
1:13:24
only go in the if statement if the board
1:13:29
right okay so this switch has to come
1:13:36
um it has to come out of the four as
1:13:38
well or else it'll
1:13:40
just yeah it'll just not run at all
1:13:49
i think you should still come in
1:13:55
yeah i'll tell you why
1:13:57
let's say we are in the first iteration
1:13:59
of the loop and this is false
1:14:02
if our function was
1:14:08
let's say here you know what i mean
1:14:11
then in the first alteration it's gonna
1:14:13
go into switch is both present and see
1:14:15
it's gonna go false in the first
1:14:18
um yeah it's just gonna end
1:14:24
true i got you now
1:14:26
you're right there
1:14:27
um that being said
1:14:31
yeah that should be fine i don't
1:14:35
if statement there
1:14:38
yeah that should be fine
1:14:46
can you go up for a sec while is it
1:14:49
yeah sure thanks story thanks for
1:14:57
because we have seven viewers
1:15:00
uh one second now let's gonna do this
1:15:07
same friend i welcome
1:15:09
your friend thanks for joining um he's
1:15:12
asking what on earth
1:15:14
i'll explain you're watching
1:15:16
yeah sure that's a that's a pretty good
1:15:18
question um so yeah
1:15:21
uh you're watching a daily
1:15:24
series of live streams
1:15:26
um we stream every day from 9 30 to 10
1:15:29
30 melbourne time as we both live in
1:15:33
but yeah we're working on
1:15:35
yes there's a melbourne in florida as
1:15:37
well but yeah exactly um we're working
1:15:39
on a project which adds
1:15:41
persistent storage to a current open
1:15:45
right now we are working on a backend
1:15:49
yeah you can join us every day except
1:15:51
saturdays which i believe it's not
1:15:55
if you want to join us you can on twitch
1:15:57
and youtube tomorrow and we're going to
1:15:59
be working on a lot of
1:16:00
express.js fetch apis
1:16:04
get jira you name it
1:16:07
uh and postman yeah thank you
1:16:11
so this should not work
1:16:23
yeah so that was the problem isn't it
1:16:27
yeah would you mind pasting the
1:16:30
link to our open source github 247
1:16:38
just keep with me zap run i will get our
1:16:47
z1 and jupiter wrath welcome guys
1:16:57
oh wait oh yeah probably don't need to
1:17:04
best scoring stream on twitch thank you
1:17:07
thank you objective
1:17:12
as requested by sam
1:17:23
re-perform back-end
1:17:28
i was i was gonna say backhand api
1:17:34
welcome chris costa how are you going
1:17:42
i like his comments
1:17:46
keen to check out the repo yeah there
1:17:48
you go there's paste it there
1:17:50
do you accept pr's yeah sure um yeah
1:17:53
just do it yeah um our
1:17:55
code should be fairly easy to understand
1:17:57
as we are yes we have really
1:18:02
make it as easy to understand as
1:18:05
but yes um following the best practices
1:18:08
as well as as much as possible
1:18:10
all the new people again are repeated
1:18:13
um we stream from 9 30 pm aest
1:18:17
which is melbourne australia time
1:18:20
and if you're interested in a lot of js
1:18:24
aws you should join us and yeah every
1:18:29
i've only learned python can you make
1:18:32
this in python you can try making this
1:18:34
in python yeah sure
1:18:36
i'm just sure you can
1:18:39
that's actually a good challenge
1:18:42
yeah what's the project i'll show you
1:18:47
i think what i have
1:18:49
to do is maybe in the repo i need to
1:18:53
update the screen as well
1:18:57
that's really really helpful
1:19:00
current open source app called
1:19:04
so we are recreating this app um hi i am
1:19:11
um and we are adding persistent storage
1:19:13
to it that means you can go ahead and
1:19:17
all that sort of stuff it's more like a
1:19:19
virtual board like you know how you have
1:19:21
boards for meetings
1:19:23
um so it's more of a virtual board
1:19:25
but there is no way right now to
1:19:28
have a persistent login so if i open it
1:19:30
now my board is gone
1:19:32
this is in storage you mean sorry yeah
1:19:39
yeah so we are trying to recreate it we
1:19:41
are not essentially looking at their
1:19:42
code even though if it's open source
1:19:46
all of the work has which has been done
1:19:48
till now it's been all ours
1:19:51
um yeah of course you can go ahead and
1:19:53
check the back end we are working on the
1:19:55
we have a front-end team as well of
1:19:57
three other people who work with us on
1:20:02
yeah it should be interesting we are
1:20:04
almost near the end of the back end so
1:20:08
this is an interesting time which is
1:20:12
and thanks again for joining guys i hope
1:20:16
you find it really useful and hopefully
1:20:19
we can learn something
1:20:21
from you guys as well
1:20:23
but we can keep streaming though for a
1:20:25
bit more i think there's a lot of people
1:20:34
it's a public holiday tomorrow so
1:20:37
yes while the people's living in
1:20:40
australia they would know there's a
1:20:42
public holiday tomorrow
1:20:48
oh yeah sorry yeah android
1:20:51
not in australia in victoria
1:20:55
can you pause please
1:20:59
i'm having a bit of a hard
1:21:05
would have to see it properly as well
1:21:07
cool perfect thank you very much
1:21:11
all those people who are new here we are
1:21:14
scrum slash agile methodology that's for
1:21:18
for the project i'm sure you know
1:21:23
can you possibly go in the validation of
1:21:27
notes and just make sure
1:21:35
yeah that looks fine i don't know
1:21:38
can you add the done ones can you add
1:21:40
one more i don't know what to do
1:21:45
board not if board isn't found it works
1:21:51
you know what i mean
1:21:55
do you use a cherry blue or red keyboard
1:21:58
fortunately i use a mac so i just use my
1:22:04
if a board is in front it works yep yeah
1:22:08
okay cool i've done that um update
1:22:12
okay let's go to validation of delete
1:22:15
notes it's in testing
1:22:17
oh let's see what happens
1:22:30
there is a nice board but let's see
1:22:33
let's add some notes to it
1:22:41
can you keep an eye on the comments
1:22:44
i'm reading them uh aries is saying
1:22:49
i'm new to coding why would you say i
1:22:52
should learn javascript
1:22:56
that's a good question um that's a
1:22:58
really great one i would say not start
1:23:04
but like yeah i'm really happy that i
1:23:07
started with java because
1:23:09
it's it's always good to start with the
1:23:11
object-oriented language um it really
1:23:14
gives you a good understanding of how
1:23:18
how to make your mindset on how the code
1:23:21
works but that being said
1:23:23
javascript isn't the worst place to
1:23:25
start javascript is really good because
1:23:28
you can do js for backend and front and
1:23:37
if you really want to start from scratch
1:23:39
yeah just go for assembly just go
1:23:43
either you're gonna create another os or
1:23:54
what we're building
1:23:57
today is part of as in the back end of
1:24:01
an existing project course
1:24:06
called scrambler and we're just adding a
1:24:10
persistence storage to that and
1:24:15
to be precise or what doing
1:24:17
what we're building today is just
1:24:30
in specific to the board and the notes
1:24:34
you might be asking
1:24:37
what do i mean by board and border notes
1:24:42
what this the overall concept
1:24:47
the scrambler as in the existing project
1:24:51
if i may say kanban board is it
1:24:56
yeah so in that what happens there you
1:24:59
have one board and you have many notes
1:25:04
um the relationship is there and what
1:25:09
we're doing at the moment is basically
1:25:12
that all the validations in the notes
1:25:17
enough so we can't add a note if it's
1:25:30
um script it's javascript
1:25:37
well we started to build an os that's
1:25:39
pretty nice is javascript a good
1:25:41
language for machine oh this is a newbie
1:25:51
yeah you know the answer guys
1:25:56
you're much more as in knowledgeable
1:26:02
yes it is in javascript but that means
1:26:04
that it's not in pure javascript um if
1:26:06
you're familiar with express
1:26:08
um express is a stack
1:26:11
um built on top of
1:26:13
square js but a lot of companies use
1:26:16
so it might be worth putting your time
1:26:18
into actually i'm curious
1:26:20
how many companies actually use express
1:26:24
i think 80 something along 80
1:26:27
oh okay it's that popular
1:26:40
chris costello one is saying oh nice is
1:26:43
very helpful for manufacturing
1:26:48
okay that's a lot more one second
1:26:55
expertise is actually a lot more popular
1:26:58
than i thought it was
1:27:00
no it's actually pretty popular um yeah
1:27:06
yeah it's gonna lose a lot
1:27:09
but no problem for
1:27:14
good to have you again
1:27:18
um yeah okay let's get back to what we
1:27:23
cool router delete um
1:27:26
so what we need to check is that is id
1:27:30
is id alpha numeric that's probably all
1:27:33
the checks we need
1:27:34
and no boards found okay yeah let's try
1:27:39
on delete a note and not make it
1:27:44
i'll give it a dollar sign that should
1:27:53
give a dollar sign to the board id as
1:27:58
id is invalid he did
1:28:04
still i didn't know that's all good um
1:28:10
i'll post a note again
1:28:16
you see a particular scenario is working
1:28:20
just go back in the code and
1:28:24
works or whatever so we actually aren't
1:28:30
track of everything as well
1:28:32
can your business and jira as well
1:28:35
yes yes i would absolutely so
1:28:49
deleting of the notes right
1:28:53
um our id is ps code probably you can
1:28:59
so i'm kind of curious
1:29:00
is there a dark mode for postman
1:29:07
go ahead and google that for me anyone
1:29:10
let me know if there's a dark mullet in
1:29:13
that'll be interesting to do
1:29:15
i don't like those so
1:29:20
um can you just explain me what was this
1:29:25
again the previous one as in the board
1:29:28
id and the note id has to be valid
1:29:32
yeah so if it's not alphanumeric that
1:29:34
means if there's a dollar sign or
1:29:35
underscore this shouldn't work
1:29:40
in both okay yeah in both of them
1:29:43
oh really oh zeveran says there
1:29:45
definitely is actually let's see okay
1:30:22
that looks way better now
1:30:24
have you done yours
1:30:26
sorry no i just made it dark more
1:30:28
on none no no i meant as in have you
1:30:32
done the dark mode of yours because i'm
1:30:34
going to do the same as well yeah i'll
1:30:36
let you know how to do it if you want me
1:30:40
i am a nice not let's see
1:30:44
uh get all boards yep note has been
1:30:48
i'll get the note id
1:30:52
um let's see delete okay
1:30:57
look at the note board id first
1:31:01
paste it in a delete
1:31:07
and then i'll get the note id as well
1:31:11
wait no don't do that
1:31:18
and i'm going to delete
1:31:24
so this is the ideal condition now
1:31:28
we want to see if the board isn't
1:31:30
actually present so i'll just say
1:31:34
okay internal server
1:31:36
let's come back to that
1:31:38
so and what was the previous um
1:31:42
snowy you just did
1:31:46
um right now i'm trying to do a scenario
1:31:52
isn't present which we actually didn't
1:31:55
yeah we didn't since
1:32:00
um yes yes you're right
1:32:04
uh yeah you can say from personal
1:32:06
experience i have like
1:32:10
eyesight so ah okay
1:32:14
okay this should give an error saying
1:32:20
which is if you give a a
1:32:25
yeah note which is not present in our
1:32:27
database if you try to delete that
1:32:29
um it's going to say not not found okay
1:32:33
um see if it works
1:32:42
uh i just need to do one more thing
1:32:50
if we actually find the board or not
1:33:10
then are we actually
1:33:14
oh we are we are yeah we are yes
1:33:19
so if we don't find a board what is
1:33:23
a query operation gonna return
1:33:36
hang on so you're saying if
1:33:43
we don't find that particular board
1:33:49
then an empty object probably or undef
1:33:52
no it can't really be undefined can it
1:33:58
i mean it's not defined logically
1:34:17
interesting let's see
1:34:42
it's gonna be under four
1:34:54
uh check if a table item doesn't exist
1:34:56
okay yeah this looks promising
1:35:00
oh we're not doing a get item but that's
1:35:05
we just have to check the
1:35:07
arrow handling of it
1:35:13
i mean i can just try that right like um
1:35:18
i don't have to put a lot of brain in it
1:35:21
i can just try this
1:35:26
try and catch it yeah
1:35:36
not giving a function
1:35:40
oh no sorry letter return
1:35:43
um yeah to all those people who don't
1:35:45
know error return is it's a
1:35:48
um function which we made this is the
1:35:52
404 this is the message
1:35:59
yeah and there's a response object uh
1:36:03
and there should be a return semicolon
1:36:20
sam will yep and yeah again to all those
1:36:23
people who are new here
1:36:25
we are working on a serverless
1:36:29
what's the full form of sam
1:36:32
serverless application model
1:36:36
true yes then it's probably right
1:36:58
solutions architect the right way
1:37:04
actually probably forgot i love it
1:37:09
it's been a long time
1:37:12
to refresh everything
1:37:25
did you do postman in dark mode
1:37:33
said that it looks really nice
1:37:36
i think a lot easier
1:37:38
on the eyes like i have said
1:37:45
i just wish that the streaming software
1:37:49
what i'm i'm gonna do up in my research
1:37:52
and see if if it is
1:37:55
there's actually a thing you can do
1:37:58
just do body and color
1:38:04
and go and inspect element and just do
1:38:06
body color uh hashtag zero zero zero
1:38:14
kidding i'm gonna give you a shot and
1:38:20
that'd be hilarious
1:38:34
internal server let's see what
1:38:47
yeah that probably is the one
1:38:52
that helps cloud watch unknown
1:38:58
that explains a lot
1:39:00
do you want to expand that
1:39:05
no click on that and then no the top one
1:39:18
board is not defined
1:39:22
which line is it 393
1:39:30
oh right that board because it's in the
1:39:36
so the scope is being
1:39:46
that should probably do it
1:39:57
oh i'm just giving him sick
1:40:17
okay this that was my friend
1:40:21
we gonna play table tennis
1:40:26
do you play table tennis in
1:40:35
i yes played since
1:40:37
yeah what was the last sport you played
1:40:40
like when was the last time you went out
1:40:42
not for running just for like oh yeah
1:40:44
there's a football i'm gonna kick it
1:40:48
football that was back in the uk
1:40:52
that might that many years ago
1:41:08
that shouldn't be it
1:41:16
again i want to give it a wrong
1:41:33
okay i'm gonna do f1 and should i have
1:41:57
wait is empty with
1:42:12
that literally doesn't make sense
1:42:17
i i think these um
1:42:20
errors should be in the false one
1:42:23
not in the true one
1:42:26
no no no no no that's fine
1:42:33
i'm just curious why is it not throwing
1:42:37
the error is just wrong the curry is
1:42:40
correctly searching by a single id
1:42:54
cursor way and you probably have to
1:43:02
a parameter in the catch expression
1:43:21
now today you've asked the question i'm
1:43:24
not even sure if it's if it is you know
1:43:26
what we're gonna use our
1:43:31
chef friend is saying that the error
1:43:33
message is just wrong the query is
1:43:37
correctly searching by a single id
1:43:44
okay i'll just give it a go maybe you're
1:43:46
right then you probably are right here
1:43:50
by default yes that happened
1:43:53
um i'm just gonna give it a go let's see
1:44:09
um yeah i'm just gonna
1:44:13
add the board as well let's see what
1:44:20
i'm just gonna be a bit spicy here
1:44:39
seven so what do you do though um
1:44:43
where do you where do you put up
1:44:54
how many votes okay um four boats
1:45:00
i don't know why i said i would say five
1:45:16
also australia isn't real so you can't
1:45:20
this is actually like an alien
1:45:36
we probably have to do that
1:45:40
you probably didn't get it but
1:45:43
that is not a nice thing to say
1:45:48
yeah i didn't i didn't get it i'll let
1:45:51
you off the stream all right
1:45:58
that's all good anyway um
1:46:00
the point is why is it not working
1:46:16
one of the things which had
1:46:18
i'm just going to do an error return
1:46:19
just just for the sake of it at this
1:46:24
i want to see what's inside the board
1:46:26
even though if it's not found
1:46:29
and it's going to return semicolon
1:46:41
sound deploy minus g that means guided
1:47:02
what'd you have before dinner son i
1:47:06
i haven't decided yet
1:47:44
i think i can do one thing we can do one
1:48:00
so you know we do a query operation here
1:48:06
so what this basically is doing is that
1:48:08
it's going inside our table and it's
1:48:12
why is it returning
1:48:14
more than one boards it's returning a
1:48:18
i'll show you what's happening
1:48:20
if i give it an actual good
1:48:24
thing it should return the board here
1:48:26
let's see what happens
1:48:30
it returns the whole board but the board
1:48:36
if you know what i mean
1:48:42
are you following me
1:48:46
so the query operation is working in
1:48:50
if you give it a faulty board
1:48:53
it's just going to return empty but it's
1:48:55
still going to return a whole um
1:48:58
object of like items in it
1:49:01
all right right right i see
1:49:05
yeah yep so we probably have to change
1:49:09
now so i think that's actually kind of
1:49:12
and i'll tell you why because we already
1:49:16
have a place which checks
1:49:23
that's a win for us actually
1:49:25
i'm just gonna change the message and
1:49:31
board not present in the database
1:49:36
so we don't really have to throw
1:49:38
as in worry about that particular
1:49:42
scenario anymore yeah because it's
1:49:45
uh it's pretty satisfied yeah
1:49:50
um also this is kind of irrelevant
1:50:01
any good vs code extension you guys know
1:50:04
in the chat please drop some
1:50:13
yeah that'd be really helpful though
1:50:21
so i need a haircut so bad when are the
1:50:24
hairdressers gonna open
1:50:40
in the next 10 seconds open up come on
1:50:46
do all night become a millionaire
1:50:48
probably overnight
1:50:53
at this point i don't even know if i
1:50:55
should tell my partner to cut my hair
1:50:58
the first thing we did
1:51:05
five is the same we could install a
1:51:07
pretty extension or something to get
1:51:10
some gg code or formatting
1:51:23
do prettier probably
1:51:26
is it called prettier
1:51:31
i think so as far as i can remember
1:51:36
there you go the first
1:51:52
just gonna install it and see what
1:51:56
i have a handful name on it how about
1:51:59
i'll just go play some daisy i don't
1:52:06
all right let's just focus on
1:52:15
okay that should work okay
1:52:17
well he does um yeah that works um i
1:52:19
don't know if i showed it yeah
1:52:22
and if i give it the right one it should
1:52:30
that means okay that worked
1:52:33
um is there any other scenario i'll just
1:52:41
oh sorry not this one that's funny
1:52:46
um yeah i think yeah you can oh yeah no
1:52:50
it's not fun let me just do one more
1:52:54
um if i do instead of b i do c should
1:52:57
say not not found which it is
1:53:01
so that's all good
1:53:04
yep um then you can go back to jira and
1:53:06
say that um delete board now delete
1:53:13
which scenario was this
1:53:15
oh all of them so i'll tell you which
1:53:21
i'll go to jira as well on there now
1:53:32
board id and note id validation works
1:53:40
so when you say board id and notes id
1:53:43
validation what exactly are we checking
1:53:48
um there's only one thing that we can
1:53:51
if they're alphanumeric or not is there
1:53:53
any other thing you can check yes that
1:53:57
no none no uh i was just off to some
1:54:02
all right yeah yeah yeah so i don't
1:54:04
think there's any other thing which we
1:54:09
two scenarios until now which is more
1:54:12
when board id and no id isn't
1:54:14
alphanumeric then it shouldn't work
1:54:18
can you do board not found as well that
1:54:28
what isn't present
1:54:35
yep and when board
1:54:38
um there's no boards in the database
1:54:51
ports are not in the database
1:55:00
that's done as well
1:55:02
and not not found is done as well so
1:55:13
okay yeah that's it
1:55:18
that should be fine
1:55:20
that's brilliant so validation of the
1:55:22
deleting of the notes are done pretty
1:55:27
yep um also can you
1:55:32
checking how to do that um
1:55:38
who know how to do that yeah
1:56:20
there we go that has been done
1:56:23
okay days um yeah i think
1:56:26
it's better to call it a night
1:56:30
um but yeah that was a good session guys
1:56:34
thank you all for joining i guess
1:56:37
okay i was really productive um
1:56:42
yeah do that and make okay cool
1:56:51
is there the stable back end perfect
1:57:19
yep of course it wants my password
1:57:23
she's always hungry for it
1:57:30
thank you everyone for joining today i
1:57:34
today was a really fun session as well
1:57:36
because um we've got a lot more new
1:57:40
and then again to all those new people
1:57:42
you're welcome tomorrow to join us
1:57:52
yes melbourne australia
1:57:55
not florida yeah no florida adam yeah it
1:58:01
great to have as in
1:58:04
new people and that actually has
1:58:07
more invaded us to
1:58:10
time a bit as well which was fun
1:58:15
yes and i'll encourage everyone to join
1:58:16
us tomorrow yes thank you very much
1:58:21
and i do apologize for this guy who was
1:58:24
or i don't know if for the person who
1:58:26
was chinese underscore a boo um you will
1:58:29
not be able to come back because
1:58:34
being appropriate so
1:58:37
don't worry about him anymore
1:58:39
or her i don't know
1:58:45
right guys thanks login and um we'll see
1:58:49
you guys back here