Question: Faulty method of the class can expose itself only during function tests. Case when number of balls to draw is higher than number of balls in hat is not tested explicitly, but it can fail function test, as it includes such experiment. - - Depending on the number of balls to draw and number of balls in Hat: Remove the required number of balls randomly selected, from the Hat. If number of balls to draw is higher than the number of balls, return all the balls. Test for the method checks only the first case: The second behavior is not checked explicitly, but it's a part of the second sub-case in the function test. This creates situation where passing method test and failing function test, can suggest to camper that issue lies in the function. Example with faulty method: Error: Adding test to check second behavior of the method would make debugging easier for campers, as it would show more clearly where is the issue. No response n/a No response

reload(probability_calculator) probability_calculator.random.seed(95) <del> def test_hat_draw(self): </del> <ins> class UnitTests(unittest.TestCase): maxDiff = None def test_hat_draw(self): </ins> hat = probability_calculator.Hat(red=5,blue=2) actual = hat.draw(2) expected = ['blue', 'red']

}); ``` <ins> The `draw` method should behave correctly when the number of balls to extract is bigger than the number of balls in the hat. ```js ({ test: () => { pyodide.FS.writeFile("/home/pyodide/probability_calculator.py", code); pyodide.FS.writeFile( "/home/pyodide/test_module.py", ` import unittest import probability_calculator from importlib import reload reload(probability_calculator) probability_calculator.random.seed(95) class UnitTests(unittest.TestCase): maxDiff = None def test_hat_draw_2(self): hat = probability_calculator.Hat(yellow=5,red=1,green=3,blue=9,test=1) actual = hat.draw(20) expected = ['yellow', 'yellow', 'yellow', 'yellow', 'yellow', 'red', 'green', 'green', 'green', 'blue', 'blue', 'blue', 'blue', 'blue', 'blue', 'blue', 'blue', 'blue', 'test'] self.assertEqual(actual, expected, 'Expected hat draw to return all items from hat contents.') actual = len(hat.contents) expected = 0 self.assertEqual(actual, expected, 'Expected hat draw to leave no items in contents.') ` ); const testCode = ` from unittest import main import test_module from importlib import reload reload(test_module) t = main(module='test_module', exit=False) t.result.wasSuccessful() `; const out = __pyodide.runPython(testCode); assert(out); }, }); ``` </ins> The `experiment` method should return a different probability.

def draw(self, number): drawn = [] if number >= len(self.contents): <del> return self.contents </del> <ins> drawn.extend(self.contents) self.contents = [] </ins> else: for i in range(number): drawn.append(

) return drawn <del> def experiment(hat, expected_balls, num_balls_drawn, num_experiments): </del> <ins> def experiment(hat, expected_balls, num_balls_drawn, num_experiments): </ins> expected_balls_list = [] drawn_list = [] success = 0

except: continue if len(exp_ball_list_copy) == 0: <del> success += 1 probability = success/num_experiments </del> <ins> success += 1 probability = success/num_experiments </ins> return probability ```


Question:
We have had a few campers create the wrong variable name for step 22 of pyramid project. Here is an example A few campers are wanting to call it instead of . I think a change in directions will fix this. Here is the updated description here are the updates to the first two hints js (code, /popped/); js (code, /lets+popped/); see explanation above see explanation above No response Device: [e.g. iPhone 6, Laptop] OS: [e.g. iOS 14, Windows 10, Ubuntu 20.04] Browser: [e.g. Chrome, Safari] Version: [e.g. 22] No response
This has been opened for contribution. The first comprehensive PR created will be reviewed and merged. We typically do not assign issues to anyone other than long-time contributors. If you would like to contribute and have not read the contributors docs, please do so here: If you have any issues with contributing, be sure to join us on the , or on the Happy coding

When a method returns a value, you can think of it as giving the value back to you, making it available for use in other parts of your code. <del> Declare a `popped` variable, and assign it the result of `rows.pop()`. Then, log your `popped` variable. </del> <ins> Create a new variable called `popped` and assign it the result of `rows.pop()`. Then, log `popped` to the console. </ins> # --hints-- <del> You should declare a `popped` variable. </del> <ins> You should declare a variable called `popped`. </ins> ```js assert.match(code, /popped/); ``` <del> You should use `let` to declare your `popped` variable. </del> <ins> You should use `let` to declare your variable called `popped`. </ins> ```js assert.match(code, /lets+popped/);


Question:
Implicitly returning the callback passed into won't pass the test. This should pass at least for this step, and the following step as well. I found out later that curly brackets are missed here. The hint/error message is also not helpful here because the code provided above does exactly what the hint asks campers to do. I suggest adding "Please use curly brackets for the callback for this step" or modifying the corresponding test. ! Device: Laptop OS: Windows 11 Browser: FireFox Version: 125.0.2 (64-bit) No response
Yes, these two steps should be updated to allow for implicit returns.

You should have a `forEach` loop that iterates through the `platforms` array. ```js <del> assert.match(code, /ifs*(.*)s*{s+platforms.forEach(s*((.*)|[^s()]+)s*=>s*{s*(.*?)s*}s*)s*;?/); </del> <ins> assert.match(code, /ifs*(.*)s*{s+platforms.forEach(s*((.*)|[^s()]+)s*=>s*{?s*(.*?)s*}?s*)s*;?/); </ins> ``` You should use the subtraction assignment operator to subtract 5 from the platform's `x` position. ```js <del> assert.match(code, /platforms.forEach(s*((s*platforms*)|platform)s*=>s*{s*platform.position.xs*-=s*5s*;?s*}s*)s*;?/); </del> <ins> assert.match(code, /platforms.forEach(s*((s*platforms*)|platform)s*=>s*{?s*platform.position.xs*-=s*5s*;?s*}?s*)s*;?/); </ins> ``` # --seed--

You should add a `forEach` loop that iterates through the `platforms` array. ```js <del> assert.match(code, /elses+ifs*(.*)s*{s*platforms.forEach(s*((s*platforms*)|platform)s*=>s*{s*(.*?)s*}s*)s*;?/); </del> <ins> assert.match(code, /elses+ifs*(.*)s*{s*platforms.forEach(s*((s*platforms*)|platform)s*=>s*{?s*(.*?)s*}?s*)s*;?/); </ins> ``` You should use the addition assignment operator to add 5 to the platform's `x` position. ```js <del> assert.match(code, /platforms.forEach(s*((s*platforms*)|platform)s*=>s*{s*platform.position.xs*+=s*5s*;?s*}s*)s*;?/); </del> <ins> assert.match(code, /platforms.forEach(s*((s*platforms*)|platform)s*=>s*{?s*platform.position.xs*+=s*5s*;?s*}?s*)s*;?/); </ins> ``` # --seed--


Question: There is a typo in the Hint Message of Step 15 of Building a Dice Game, as shown in the Screenshots area. I will raise a PR for it since it is just a typo. The hint message should display: "You should reassign an empty array to your diceValuesArr variable." ! Device: Laptop OS: Windows 11 Browser: FireFox Version: 125.0.2 (64-bit) No response

# --hints-- <del> You should reassign and empty array to your `diceValuesArr` variable. </del> <ins> You should reassign an empty array to your `diceValuesArr` variable. </ins> ```js assert.match(code, /consts+rollDices*=s*(s*)s*=>s*{s*diceValuesArrs*=s*[s*]s*;?/);


Question:
When working through the , mentions the following: And when passing the following solution: This hint shows up: This doesn't pass because is expecting the following: I think adding the hint "Remember to use the keyword." is a valid hint, just like in when the keyword is not in the solution. It may be repetitive, but I think the user should be informed for this possible mistake. It's already in other steps anyway. When passing the incorrect code from the above, add the "Remember to use the keyword." hint and validation. No response Device: Laptop OS: macOS 13.6.6 Browser: Chrome Version: 124 No response
We can open this up to since this is a small change This has been opened for contribution. The first comprehensive PR created will be reviewed and merged. We typically do not assign issues to anyone other than long-time contributors. If you would like to contribute and have not read the contributors docs, please do so here: If you have any issues with contributing, be sure to join us on the , or on the Change the last hint to be the following Happy coding
I can do it!

assert.match(afterCalculateTotal, /consts+taxs*=/); ``` <del> Assign the value of calling your new `.calculateTaxes()` method, passing `subTotal` as the argument, to the `tax` variable. </del> <ins> Assign the value of calling your new `.calculateTaxes()` method, passing `subTotal` as the argument, to the `tax` variable. Remember to use the `this` keyword. </ins> ```js const afterCalculateTotal = code.split('calculateTotal')[1];


Question: Describe the bug The first sentence of description contains rogue letter 'y', which needs to be removed: This is something that can be fixed by "first time" code contributors to this repository. Here are the files that you should be looking at to work on a fix: Additional context Please make sure you read , we prioritize contributors following the instructions in our guides. Join us in or if you need help contributing, our moderators will guide you through this. Sometimes we may get more than one pull requests. We typically accept the most quality contribution followed by the one that is made first. Happy contributing.

# --description-- <del> In the Present Perfect Tense, y`for` and `since` are used to discuss time duration and starting points. </del> <ins> In the Present Perfect Tense, `for` and `since` are used to discuss time duration and starting points. </ins> `For` tells how long something has been happening. `Since` tells when something started. # --fillInTheBlank--


Question:
Problem: Simple content description error. It says in the challenge description that when the user has a calorie deficit, the remainingCalories will be a negative (less than 0). It is actually the opposite. For example, if I were to input this in the form: The description of the step must say that it will be a negative value if the input is a surplus (above budget). ! Device: [e.g. iPhone 6, Laptop] OS: [e.g. iOS 14, Windows 10, Ubuntu 20.04] Browser: [e.g. Chrome, Safari] Version: [e.g. 22] No response
This has been opened for contribution. The first comprehensive PR created will be reviewed and merged. We typically do not assign issues to anyone other than long-time contributors. If you would like to contribute and have not read the contributors docs, please do so here: If you have any issues with contributing, be sure to join us on the , or on the Happy coding

# --description-- <del> When the user has a calorie deficit, the `remainingCalories` value will be negative. You don't want to display a negative number in the result string. </del> <ins> When the user has a calorie surplus, the `remainingCalories` value will be negative. You don't want to display a negative number in the result string. </ins> `Math.abs()` is a built-in JavaScript method that will return the absolute value of a number.


Question:
It looks like a lot of people on the forums and discords are confused on the syntax for this step. we could add an updated description with code example to guide campers. js " " + "string" ` see explanation above see explanation above No response Device: [e.g. iPhone 6, Laptop] OS: [e.g. iOS 14, Windows 10, Ubuntu 20.04] Browser: [e.g. Chrome, Safari] Version: [e.g. 22] No response
This has been opened for contribution. The first comprehensive PR created will be reviewed and merged. We typically do not assign issues to anyone other than long-time contributors. If you would like to contribute and have not read the contributors docs, please do so here: If you have any issues with contributing, be sure to join us on the , or on the Happy coding
Step 63 You should now see the same bunch of characters in your console. Your padRow function is doing the exact same thing you were doing earlier, but now it's in a reusable section of its own. Use the addition operator to concatenate a blank space " " to the beginning and end of your repeated character string. Remember that you can use the + operator to concatenate strings like this: " " + "string" This is what i got and it was accepted function padRow(rowNumber, rowCount) { return " " + (rowNumber) + " " }

Use the addition operator to concatenate a blank space `" "` to the beginning and end of your repeated `character` string. <ins> Remember that you can use the `+` operator to concatenate strings like this: ```js " " + "string" ``` </ins> # --hints-- You should concatenate an empty space to the beginning of your returned value.


Question:
Hey any more context on this issue? Seems pretty empty to be already opened with the label.
the challenge needs more tests, it's not a high priority thing, that comment has been there for a few years already

assert.deepEqual(tokenize(testStr2, '&', '@'), res2); ``` <ins> `tokenize('hello^|world|how^are^you^|', '|', '^')` should return `['hello|world', 'howareyou|']` ```js assert.deepEqual(tokenize(testStr3, '|', '^'), res3); ``` </ins> # --seed-- ## --after-user-code--

const testStr1 = 'one^|uno||three^^^^|four^^^|^cuatro|'; const res1 = ['one|uno', '', 'three^^', 'four^|cuatro', '']; <del> // TODO add more tests </del> const testStr2 = 'a@&bcd&ef&&@@hi'; const res2 = ['a&bcd', 'ef', '', '@hi']; <ins> const testStr3 = 'hello^|world|how^are^you^|'; const res3 = ['hello|world', 'howareyou|']; </ins> ``` ## --seed-contents--


Question: We need to replace all images and audio samples for the legacy content with the ones that were just to our freeCodeCamp cdn. Here are all of the files that will need to be updated Here are all of the new asset links

Here are some audio samples you can use for your drum machine:  - [Heater 1](https://s3.amazonaws.com/freecodecamp/drums/Heater-1.mp3) - [Heater 2](https://s3.amazonaws.com/freecodecamp/drums/Heater-2.mp3) - [Heater 3](https://s3.amazonaws.com/freecodecamp/drums/Heater-3.mp3) - [Heater 4](https://s3.amazonaws.com/freecodecamp/drums/Heater-4_1.mp3) - [Clap](https://s3.amazonaws.com/freecodecamp/drums/Heater-6.mp3) - [Open-HH](https://s3.amazonaws.com/freecodecamp/drums/Dsc_Oh.mp3) - [Kick-n'-Hat](https://s3.amazonaws.com/freecodecamp/drums/Kick_n_Hat.mp3) - [Kick](https://s3.amazonaws.com/freecodecamp/drums/RP4_KICK_1.mp3) - [Closed-HH](https://s3.amazonaws.com/freecodecamp/drums/Cev_H2.mp3)   - [Heater 1](https://cdn.freecodecamp.org/testable-projects-fcc/audio/Heater-1.mp3) - [Heater 2](https://cdn.freecodecamp.org/testable-projects-fcc/audio/Heater-2.mp3) - [Heater 3](https://cdn.freecodecamp.org/testable-projects-fcc/audio/Heater-3.mp3) - [Heater 4](https://cdn.freecodecamp.org/testable-projects-fcc/audio/Heater-4_1.mp3) - [Clap](https://cdn.freecodecamp.org/testable-projects-fcc/audio/Heater-6.mp3) - [Open-HH](https://cdn.freecodecamp.org/testable-projects-fcc/audio/Dsc_Oh.mp3) - [Kick-n'-Hat](https://cdn.freecodecamp.org/testable-projects-fcc/audio/Kick_n_Hat.mp3) - [Kick](https://cdn.freecodecamp.org/testable-projects-fcc/audio/RP4_KICK_1.mp3) - [Closed-HH](https://cdn.freecodecamp.org/testable-projects-fcc/audio/Cev_H2.mp3)  You can build your project by using this CodePen template and clicking `Save` to create your own pen. Or you can use this CDN link to run the tests in any environment you like: `https://cdn.freecodecamp.org/testable-projects-fcc/v1/bundle.js`

[ { "id":0, <del> "imageLink":"https://s3.amazonaws.com/freecodecamp/funny-cat.jpg", </del> <ins> "imageLink":"https://cdn.freecodecamp.org/curriculum/legacy-json-apis-ajax/funny-cat.jpg", </ins> "altText":"A white cat wearing a green helmet shaped melon on its head. ", "codeNames":[ "Juggernaut", "Mrs. Wallace", "Buttercup" ]

**User Story:** I can win the game by getting a series of 20 steps correct. I am notified of my victory, then the game starts over. <del> **Hint:** Here are mp3s you can use for each button: `https://s3.amazonaws.com/freecodecamp/simonSound1.mp3`, `https://s3.amazonaws.com/freecodecamp/simonSound2.mp3`, `https://s3.amazonaws.com/freecodecamp/simonSound3.mp3`, `https://s3.amazonaws.com/freecodecamp/simonSound4.mp3`. </del> <ins> **Hint:** Here are mp3s you can use for each button: `https://cdn.freecodecamp.org/curriculum/take-home-projects/simonSound1.mp3`, `https://cdn.freecodecamp.org/curriculum/take-home-projects/simonSound2.mp3`, `https://cdn.freecodecamp.org/curriculum/take-home-projects/simonSound3.mp3`, `https://cdn.freecodecamp.org/curriculum/take-home-projects/simonSound4.mp3`. </ins> When you are finished, include a link to your project on CodePen and click the "I've completed this challenge" button.


Question:
! Frequently asked question segment is not aligned with the previous elements on the homepage to down to frequently asked questions the misalignment of frequently asked questions segment with the previous elements The frequently asked question segment should be aligned with the previous elements of the homepage for a better UI ! Device: Laptop OS: Windows 11 Browser: Brave Version: 1.64.122 No response
This issue is because the Certifications section has extra side padding: We can add a class to the FAQ section, and give it , too. I'm not sure if this change would collide with the changes you're making to the landing page. I'm also wondering if the Certification section being so wide (comparing to the one on /learn) is still desired. If it's not, I think we can take this opportunity to update the section.
Yes, we can standardize all of them. My changes are effecting the landing top section.
Thanks, Ahmad. I'm temporarily blocking this issue until the CSS situation is a little less messy. I'll get back to this and come up with a suggestion after is merged.
We will be making changes to the certification section in the near future, so I think we can keep the scope of this issue to just adding some extra padding to the FAQ section, as suggested here: This issue is open for contribution. We typically do not assign issues. Instead, we accept the most quality contribution followed by the one that is made first. Please make sure you read our as well as our , we prioritize contributors following the instructions in our guides. Join us in our or our if you need help contributing; our moderators will guide you through this. Happy contributing.

const faqItems = t<string, string & FaqItem[]>('landing.faqs'); return (  <Col sm={8} smOffset={2} xs={10} xsOffset={1}>   <Col md={8} mdOffset={2} sm={10} smOffset={1} xs={12} className='faq-section' >
{t('landing.faq')}
 <Spacer size='small' /> {faqItems.map((faq, i) => (

padding: 4vw 15px; } <del> .certification-section { </del> <ins> .certification-section, .faq-section { </ins> padding-inline: 4vw; }


Question:
first discussed on the forum here: I had a concern about the starting sentence of step 26 of the js pyramid project here: It starts out with: "The let keyword allows a variable to be reassigned." which I think can be misinterpreted to mean that we can use the keyword to reassign a variable. I believe a reword to "Declaring a variable with the let keyword allows it to be reassigned." will be not as easy to misinterpret. N/A slight reword to instructions needed as per above No response N/A No response
Seems like a good change. This looks like something that can be fixed by "first-time" code contributors to this repository. Here are the files that you should be looking at to work on a fix: From: To: Please make sure you read our , we prioritize contributors following the instructions in our guides. Join us in our or our if you need help contributing; our moderators will guide you through this. Sometimes we may get more than one pull request. We typically accept the most quality contribution followed by the one that is made first. Happy contributing.

# --description-- <del> The `let` keyword allows a variable to be reassigned. This means you could change `character` later to be a completely different value. </del> <ins> Declaring a variable with the `let` keyword allows it to be reassigned. This means you could change `character` later to be a completely different value. </ins> For this project, you will not want to change these variable values. So instead, you should use `const` to declare them. `const` variables are special.


Question: Valid code will fail and give the wrong assert message about using which is confusing. Expected If you search for articles on you will find many of the examples has the min value inside the method, this includes MDN, fCC news articles, etc. The min value should be allowed inside the floor method. Update the regex that checks for to not depend on the rest of the code structure to avoid false positives. Tests: Valid code should pass and not throw unrelated assert messages. No response Device: [e.g. iPhone 6, Laptop] OS: [e.g. iOS 14, Windows 10, Ubuntu 20.04] Browser: [e.g. Chrome, Safari] Version: [e.g. 22] Forum:

You should use `Math.floor()` to round the result down to the nearest whole number. ```js <del> assert.match(code, /consts+randomDices*=s*Math.floors*(s*Math.randoms*(s*)s**s*6s*)s*/); </del> <ins> assert.match(code, /consts+randomDices*=s*Math.floors*((?s*Math.randoms*(s*)s**s*6s*)s*/); </ins> ``` You should add `1` to the end result of your `randomDice` variable. ```js <del> assert.match(code, /consts+randomDices*=s*Math.floors*(s*Math.randoms*(s*)s**s*6s*)s*+s*1s*/); </del> <ins> assert.match(code, /consts+randomDices*=s*Math.floors*((?s*Math.randoms*(s*)s**s*6s*)s*+s*1)?s*/); </ins> ``` # --seed--


Question:
We are using the class to conditionally hide some text on mobile screens: This class comes from Bootstrap, which is something we are going to remove (). So instead of using the class, we can use an check, like this (which is also a little more consistent with how we've handled this kind of conditional rendering): Update the file to replace the class with an check. I noticed that we are using multiple methods for mobile device detection, so I think the check should be standardized, and there should be a shared util for this check. But I'm leaving this out of the scope of this issue, and will create a separate issue for it.
We typically do not assign issues. Instead, we accept the first pull request that comprehensively solves the issue. Issues labelled with or are open for contributions. Please make sure you read . We prioritize contributors following the instructions in our guide. Join us in or if you need help contributing - our community will be happy to assist you.
I already have a pull request that technically resolves this. While it is done the same way we did the lower-jaw i.e checks for a desktop instead of being mobile , it does solve the problem and pass the tests.

"update-email": "Update my Email", "verify-email": "Verify Email", "submit-and-go": "Submit and go to next challenge", <ins> "submit-and-go-2": "Submit and go to next challenge (Ctrl + Enter)", "submit-and-go-3": "Submit and go to next challenge (Command + Enter)", </ins> "go-to-next": "Go to next challenge", <ins> "go-to-next-2": "Go to next challenge (Ctrl + Enter)", "go-to-next-3": "Go to next challenge (Command + Enter)", </ins> "ask-later": "Ask me later", "start-coding": "Start coding!", "go-to-settings": "Go to settings to claim your certification",

import Progress from '../../../components/Progress'; import GreenPass from '../../../assets/icons/green-pass'; import { Spacer } from '../../../components/helpers'; <ins> import { MAX_MOBILE_WIDTH } from '../../../../config/misc'; </ins> import './completion-modal.css'; import callGA from '../../../analytics/call-ga';

const isMacOS = navigator.userAgent.includes('Mac OS'); <ins> const isDesktop = window.innerWidth > MAX_MOBILE_WIDTH; let buttonText; if (isDesktop) { if (isMacOS) { buttonText = isSignedIn ? t('buttons.submit-and-go-3') : t('buttons.go-to-next-3'); } else { buttonText = isSignedIn ? t('buttons.submit-and-go-2') : t('buttons.go-to-next-2'); } } else { buttonText = isSignedIn ? t('buttons.submit-and-go') : t('buttons.go-to-next'); } </ins> return ( <Modal onClose={close}

data-cy='submit-challenge' onClick={() => submitChallenge()} > <del> {isSignedIn ? t('buttons.submit-and-go') : t('buttons.go-to-next')} <span className='hidden-xs'> {isMacOS ? ' (Command + Enter)' : ' (Ctrl + Enter)'} </span> </del> <ins> {buttonText} </ins> </Button> <Spacer size='xxSmall' /> {this.state.downloadURL ? (


Question: All links in the english curriculum need to be replaced. This is the last of the S3 links Here are the new CDN links that should be used instead multiple see explanation above see explanation above No response Device: [e.g. iPhone 6, Laptop] OS: [e.g. iOS 14, Windows 10, Ubuntu 20.04] Browser: [e.g. Chrome, Safari] Version: [e.g. 22] No response

# --instructions-- <del> Time to take a break from Camper Cat and meet fellow camper Zersiax (@zersiax), a champion of accessibility and a screen reader user. To hear a clip of his screen reader in action, add an `audio` element after the `p` element. Include the `controls` attribute. Then place a `source` element inside the `audio` tags with the `src` attribute set to `https://s3.amazonaws.com/freecodecamp/screen-reader.mp3` and `type` attribute set to `"audio/mpeg"`. </del> <ins> Time to take a break from Camper Cat and meet fellow camper Zersiax (@zersiax), a champion of accessibility and a screen reader user. To hear a clip of his screen reader in action, add an `audio` element after the `p` element. Include the `controls` attribute. Then place a `source` element inside the `audio` tags with the `src` attribute set to `https://cdn.freecodecamp.org/curriculum/applied-accessibility/screen-reader.mp3` and `type` attribute set to `"audio/mpeg"`. </ins> **Note:** The audio clip may sound fast and be difficult to understand, but that is a normal speed for screen reader users.

```js assert( $('source').attr('src') === <del> 'https://s3.amazonaws.com/freecodecamp/screen-reader.mp3' </del> <ins> 'https://cdn.freecodecamp.org/curriculum/applied-accessibility/screen-reader.mp3' </ins> ); ```

A sound clip of Zersiax's screen reader in action.
 <audio controls>  <source src="https://s3.amazonaws.com/freecodecamp/screen-reader.mp3" type="audio/mpeg"/>   <source src="https://cdn.freecodecamp.org/curriculum/applied-accessibility/screen-reader.mp3" type="audio/mpeg"/>  </audio>


Question: In the JS Beta project to build a pyramid gen., steps 82 and 83 both show an if statement block in the code editor that is not correctly indented within the while loop it is in. This may confuse new learners if they are relying on the indents to understand the logic and should be fixed to keep the presented code in acceptable shape for learners. N/A the if statement should be indented within the while loops block ! ! N/A No response

--fcc-editable-region-- --fcc-editable-region-- <del> if (done === count) { </del> <ins> if (done === count) { </ins> continueLoop = false; } }

while (continueLoop) { done++; rows.push(padRow(done, count)); <del> if (done === count) { </del> <ins> if (done === count) { </ins> continueLoop = false; } }

while (done !== count) { done++; rows.push(padRow(done, count)); <del> if (done === count) { </del> <ins> if (done === count) { </ins> continueLoop = false; } }


Question:
When invalid code is submitted to step 4 of the gradebook app review project, a message is shown which has a typo. "Your studentMsg function should return a the correct ..." Please remove the just click submit without typing anything to trigger the error message display pls correct the typo No response N/A No response
Thanks for opening this issue. This looks something that can be fixed by "first time" code contributors to this repository. Here are the files that you should be looking at to work on a fix: List of files: Please make sure you read , we prioritize contributors following the instructions in our guides. Join us in or if you need help contributing, our moderators will guide you through this. Sometimes we may get more than one pull requests. We typically accept the most quality contribution followed by the one that is made first. Happy contributing.
Hi I am intrested to work on this, Can I start?
iam interested to work on this issue
Hey We typically do not assign issues. Instead, we accept the first pull request that comprehensively solves the issue. Issues labelled with or are open for contributions. Please make sure you read . We prioritize contributors following the instructions in our guide. Join us in or if you need help contributing - our community will be happy to assist you.
Hi, can I take up this issue? I am new to open source so looking to start with some small contributions.
We do not assign issues except to long time contributors and members. please read through this note here on contributing thanks
I have created a PR for the issue. Waiting for your feedback. Thank you!

assert.strictEqual(studentMsg([56, 23, 89, 42, 75, 11, 68, 34, 91, 19], 100), "Class average: 50.8. Your grade: A++. You passed the course."); ``` <del> Your `studentMsg` function should return a the correct message based on the student's score and the class average. </del> <ins> Your `studentMsg` function should return the correct message based on the student's score and the class average. </ins> ```js assert.strictEqual(studentMsg([33, 44, 55, 66, 77, 88, 99, 100], 92), "Class average: 70.25. Your grade: A. You passed the course.");


Question:
The instructions in step 18 of the js beta to build a calorie counter says: Start by declaring a cleanInputString function that takes a str parameter. However if you misspell the function's name you receive this hint: You should declare a cleanInputString variable. I believe this message should be changed to say "function" instead of "variable" the hint should refer to a not a No response N/A No response
Similar issue was seen in step 28 where the hint said: You should declare an isInvalidInput variable. while the instructions were again to create a function: Start by creating a function called isInvalidInput – it should take a single str parameter. And again, similar issue in step38 hint says: You should declare an addEntry variable. while the step is asking for a function
From Pyramid Generator A function is a block of code that can be reused throughout your application. Functions are declared with the following syntax:
Step 42 mentioned in the previous comment should be fixed. It should say: “The function declaration tells JavaScript that the name identifier is going to be a function.” (Replacing ‘variable’ with ‘identifier’ and ‘keyword’ with ‘declaration’) My understanding is that a function is actually an object in js but I would be surprised if a js course starts telling learners to “declare an object called myFunction” instead of saying “declare a function called myFunction”. Edited…
Step 42 should be a separate issue IMO. It shouldn't be lumped in with the corrections being made to the calorie counter steps
Here the updates for this issue remove this hint and test js assert.isDefined(cleanInputString); the current second hint and test should say this instead js assert.isFunction(cleanInputString); remove this hint and test js assert.isDefined(isInvalidInput) remove this hint and test js assert.isDefined(addEntry); udpate the second hint to the following js assert.isFunction(addEntry); `

# --hints-- <del> You should declare a `cleanInputString` variable. ```js assert.isDefined(cleanInputString); ``` Your `cleanInputString` variable should be a function. </del> <ins> You should declare a `cleanInputString` function. </ins> ```js assert.isFunction(cleanInputString);

# --hints-- <del> You should declare an `isInvalidInput` variable. ```js assert.isDefined(isInvalidInput) ``` </del> `isInvalidInput` should be a function. ```js

# --hints-- <del> You should declare an `addEntry` variable. ```js assert.isDefined(addEntry); ``` Your `addEntry` variable should be a function. </del> <ins> You should declare an `addEntry` function. </ins> ```js assert.isFunction(addEntry);


Question:
In the Building a Cipher project, comment is first mentioned in step 51: But in step 59, we actually introduce comment and its syntax: In step 51, we introduce function parameters, so I think mentioning comment here would be a little overwhelming. I think the comment introduction should either be moved to an earlier challenge or kept in step 59. If we move the comment introduction to an earlier challenge, step 51 can be kept as-is. But if we keep comment introduction in step 59, we should update step 51. Instead of asking the users to comment out the code, I wonder if we could ask them to remove the line entirely (though the code is in step 50, so it's probably a little odd to immediately remove it in the next step).
This does seems to be out of sequence. I would suggest to not comment out in step 51 and let the exception be(the resolution is there in the coming steps). This part of the instruction can be updated from: to:
If we don't ask to comment out the function call in step 51 and tell the campers they will work on fixing the error in the next steps, it would be logic to address the error in the console () and require to pass the two positional arguments to the function call in step 52. But then the function will seem to work fine, although it's still using the and variable inside its body instead of the function parameters. The alternative is to ignore the in the console for step 52, and address it directly in step 53. For that we should simply keep the function call instead of commenting it out and there is no need to swap the step order. Honestly, I don't like particularly any of these options.

Modify your function declaration so that it takes two parameters called `message` and `offset`. <del> After that, you'll see an error appear in the terminal. As a temporary fix, comment out the `caesar()` call. </del> <ins> After that, you'll see an error appear in the terminal. You'll see how to solve it in the next steps. </ins> # --hints-- <del> You should comment out the `caesar()` function call. ```js ({test: () => assert(runPython( `not _Node(_code).find_calls('caesar')` ))}) ``` </del> Your `caesar` function should take `message` and `offset` as the parameters. Remember to separate the parameters with a comma. ```js

shift = 3 --fcc-editable-region-- def caesar(): <ins> --fcc-editable-region-- </ins> alphabet = 'abcdefghijklmnopqrstuvwxyz' encrypted_text = ''

print('encrypted text:', encrypted_text) caesar() <del> --fcc-editable-region-- </del> ```

print('plain text:', text) print('encrypted text:', encrypted_text) <del> #caesar() </del> <ins> caesar() </ins> --fcc-editable-region-- ```

# --description-- <del> Now, uncomment your `caesar()` call. You'll see that your code raises a `TypeError`, because the `caesar` function is defined with two parameters (`message` and `offset`), therefore it expects to be called with two *arguments*. </del> <ins> Currently, your code raises a `TypeError`, because the `caesar` function is defined with two parameters (`message` and `offset`), therefore it expects to be called with two *arguments*. </ins> Calling `caesar()` without the required arguments stops the execution of the code.

print('plain text:', message) print('encrypted text:', encrypted_text) --fcc-editable-region-- <del> # caesar() </del> <ins> caesar() </ins> --fcc-editable-region-- ```


Question:
The step asks for a list comprehension, but the following code is accepted as a solution (with parenthesis): I believe the step must only accept the list comprehension with square brackets []: No response Device: Laptop OS: Windows 11 Browser: Brave Version: 1.64.116 No response
Thank you for reporting this issue. I don't think this is a huge problem, since the code works well with a generator expression too. However, since the instructions are asking for a list comprehension, it makes sense to fix the test. The helpers do not discriminate between the various comprehension types, so I'd import the module and check if the value of the variable is an instance of . This additional check should take place within .

You should assign a list comprehension that iterates over `row` to the `row_str` variable. ```js <del> ({ test: () => assert(runPython(`_Node(_code).find_class("Board").find_function("__str__").find_for_loops()[0].find_bodies()[0].find_variable("row_str").find_comp_iters()[0].is_equivalent("row")`)) }) </del> <ins> ({ test: () => (runPython(` import ast var = _Node(_code).find_class("Board").find_function("__str__").find_for_loops()[0].find_bodies()[0].find_variable("row_str") assert var.find_comp_iters()[0].is_equivalent("row"), "You should iterate over row" assert isinstance(var.tree.value, ast.ListComp), "It's not a list comprehension" `)) }) </ins> ``` The list comprehension assigned to the `row_str` variable should use `i` as iteration variable.


Question:
I noticed that we are using both "a attribute" and "an attribute" in challenge descriptions. And we even use both in the same challenge (): <img width="596" alt="Screenshot 2024-05-21 at 22 44 29" src=""I think both are acceptable, since the articles depend on how we pronounce "src" ("es-ar-see" vs "source"), but I think we should stick to one for consistency. I'll let native English speakers make the call
I always pronounce it as , so I vote
I'm with Jessica on this one. The second sentence should be changed to .
This issue is open to first-time code contributors to this repository. The files that you should be updating are: Please make sure you read our as well as our , we prioritize contributors following the instructions in our guides. Join us in our or our if you need help contributing; our moderators will guide you through this. Sometimes we may get more than one pull request. We typically accept the most quality contribution followed by the one that is made first. Happy contributing.
Hi everyone. This is a great pick up! I am happy to help out there and will get a initial PR up for review today :)
I have reviewed the changes made in PR, all the related file have been fixed correctly and checked locally.
Hello, This is my first Open source contribution so if you guys can give me feedback on what i did wrong and how i should correct it please guide me. from the seven files mentioned above, I have created pull request for each one which is as below. sorry if i messed up, as it is my first try. I am actively looking for any advice, suggestion, criticism. Thank You.

<img src="https://cdn.freecodecamp.org/platform/universal/fcc_secondary.svg"> ``` <del> Inside the existing `img` element, add an `src` attribute with this URL: </del> <ins> Inside the existing `img` element, add a `src` attribute with this URL: </ins> `https://cdn.freecodecamp.org/curriculum/cat-photo-app/relaxing-cat.jpg`

assert(document.querySelector('img')); ``` <del> Your `img` element should have an `src` attribute. You have either omitted the attribute or have a typo. Make sure there is a space between the element name and the attribute name. </del> <ins> Your `img` element should have a `src` attribute. You have either omitted the attribute or have a typo. Make sure there is a space between the element name and the attribute name. </ins> ```js assert(document.querySelector('img').src);

# --hints-- <del> You should have an `img` element with an `src` value of `https://cdn.freecodecamp.org/curriculum/cat-photo-app/relaxing-cat.jpg`. You may have accidentally deleted it. </del> <ins> You should have an `img` element with a `src` value of `https://cdn.freecodecamp.org/curriculum/cat-photo-app/relaxing-cat.jpg`. You may have accidentally deleted it. </ins> ```js assert(

# --description-- <del> After the unordered list, add a new image with an `src` attribute value set to: </del> <ins> After the unordered list, add a new image with a `src` attribute value set to: </ins> `https://cdn.freecodecamp.org/curriculum/cat-photo-app/lasagna.jpg`

); ``` <del> The new image does not have an `src` attribute. Check that there is a space after the opening tag's name and/or there are spaces before all attribute names. </del> <ins> The new image does not have a `src` attribute. Check that there is a space after the opening tag's name and/or there are spaces before all attribute names. </ins> ```js assert($('section')[1].lastElementChild.hasAttribute('src')); ``` <del> The new image should have an `src` value of `https://cdn.freecodecamp.org/curriculum/cat-photo-app/lasagna.jpg`. Make sure the `src` attribute's value is surrounded with quotation marks. </del> <ins> The new image should have a `src` value of `https://cdn.freecodecamp.org/curriculum/cat-photo-app/lasagna.jpg`. Make sure the `src` attribute's value is surrounded with quotation marks. </ins> ```js assert(

); ``` <del> The third image should have an `src` attribute set to `https://cdn.freecodecamp.org/curriculum/cat-photo-app/cats.jpg`. </del> <ins> The third image should have a `src` attribute set to `https://cdn.freecodecamp.org/curriculum/cat-photo-app/cats.jpg`. </ins> ```js const catsImg = document.querySelectorAll('figure > img')[1];

assert.equal(allSongs[0].duration, "4:25"); ``` <del> Your `allSongs` array should have an object with an `src` property set to the string `"https://cdn.freecodecamp.org/curriculum/js-music-player/scratching-the-surface.mp3"`. </del> <ins> Your `allSongs` array should have an object with a `src` property set to the string `"https://cdn.freecodecamp.org/curriculum/js-music-player/scratching-the-surface.mp3"`. </ins> ```js assert.equal(allSongs[0].src, "https://cdn.freecodecamp.org/curriculum/js-music-player/scratching-the-surface.mp3");

assert.equal(allSongs[1].duration, "4:15"); ``` <del> The second object in your `allSongs` array should have an `src` property set to the string `"https://cdn.freecodecamp.org/curriculum/js-music-player/can't-stay-down.mp3"`. </del> <ins> The second object in your `allSongs` array should have a `src` property set to the string `"https://cdn.freecodecamp.org/curriculum/js-music-player/can't-stay-down.mp3"`. </ins> ```js assert.equal(allSongs[1].src, "https://cdn.freecodecamp.org/curriculum/js-music-player/can't-stay-down.mp3");

assert.equal(allSongs[2].duration, "3:51"); ``` <del> The third object in your `allSongs` array should have an `src` property set to the string `"https://cdn.freecodecamp.org/curriculum/js-music-player/can't-stay-down.mp3"`. </del> <ins> The third object in your `allSongs` array should have a `src` property set to the string `"https://cdn.freecodecamp.org/curriculum/js-music-player/can't-stay-down.mp3"`. </ins> ```js assert.equal(allSongs[2].src, "https://cdn.freecodecamp.org/curriculum/js-music-player/still-learning.mp3");


Question:
This sentence seems to be confusing campers on the forum Let's go with this updated description here see explanation above see explanation above No response Device: [e.g. iPhone 6, Laptop] OS: [e.g. iOS 14, Windows 10, Ubuntu 20.04] Browser: [e.g. Chrome, Safari] Version: [e.g. 22] No response
This has been opened for contribution. The first comprehensive PR created will be reviewed and merged. We typically do not assign issues to anyone other than long-time contributors. If you would like to contribute and have not read the contributors docs, please do so here: If you have any issues with contributing, be sure to join us on the , or on the Happy coding
Hi, I have created this PR as a first time contributor (no PRs merged yet) to this codebase. Hope the changes are up to expected requirements. Thanks!

Variable naming follows specific rules: names can include letters, numbers, dollar signs, and underscores, but cannot contain spaces and must not begin with a number. <del> Declare a `character` variable in your code. </del> <ins> Use the `let` keyword to declare a variable called `character`. </ins> _Note_: It is common practice to end statements in JavaScript with a semicolon. `;`


Question:
The contains a lot of unused CSS rules, which should be cleaned up. The unused rules/classes are: .challenge-success-modal .btn-lg .btn-cta-big .completion-modal-body .completion-message .completion-challenge-nameRemove the above classes from Test and confirm that the modal displays properly after the changes
Hi, I can help with this If you would like to assign it to me.

} @media screen and (max-width: 991px) { <del> .challenge-success-modal .btn-lg { font-size: 1rem; } .challenge-success-modal .btn-cta-big { max-width: 100%; font-size: 1rem; } .completion-modal-body { min-height: 340px; } </del> .progress-bar-wrap, .progress-bar-background { height: 10px;

font-size: 1.2rem; } <del> .completion-challenge-name, </del> .completion-block-name { font-size: 1rem; }


Question:
There should be a space between "CSS" and "(Cascading Style Sheets)". <img width="579" alt="Screenshot 2024-05-24 at 14 03 12" src="" Fix the typo in the following file:
This issue is open to first-time code contributors to this repository. The file that you should be updating is linked in the original post. Please make sure you read our as well as our , we prioritize contributors following the instructions in our guides. Join us in our or our if you need help contributing; our moderators will guide you through this. Sometimes we may get more than one pull request. We typically accept the most quality contribution followed by the one that is made first. Happy contributing.

# --description-- <del> In this project, you will learn the basics of CSS(Cascading Style Sheets) by building a cafe menu. CSS is the language used to style an HTML document. It describes how HTML elements should be displayed on the screen. </del> <ins> In this project, you will learn the basics of CSS (Cascading Style Sheets) by building a cafe menu. CSS is the language used to style an HTML document. It describes how HTML elements should be displayed on the screen. </ins> As you learned in the last few steps of the Cat Photo App, there is a basic structure needed to start building your web page. Every HTML document should have a `DOCTYPE` declaration and `html` element. The `DOCTYPE` tells the browser which version of HTML the document is in. And the `html` element represents the root element which contains all other elements.


Question:
The class is used in : The class doesn't have any effect because there isn't any in : That means it's safe to remove the class now. Remove the selector from Remove the class from
This issue is open for contribution. Please make sure you read our as well as our , we prioritize contributors following the instructions in our guides. Join us in our or our if you need help contributing; our moderators will guide you through this. Sometimes we may get more than one pull request. We typically accept the most quality contribution followed by the one that is made first. Happy contributing.

} } <del> .button-group .btn:not(:last-child) { margin-bottom: 10px; } </del> strong { color: var(--secondary-color); }

const { t } = useTranslation(); return ( <div <del> className={`tool-panel-group button-group ${ </del> <ins> className={`tool-panel-group ${ </ins> isMobile ? 'tool-panel-group-mobile' : '' }`} >


Question:
On , there should be a note displayed between the description and the buttons, but we are seeing an empty div instead: <img width="792" alt="Screenshot 2024-05-24 at 22 53 18" src=""The issue is due to the class to the . In Remove the class to make the note show up Remove the class as it is unused
This issue is open for contribution. Please make sure you read our as well as our , we prioritize contributors following the instructions in our guides. Join us in our or our if you need help contributing; our moderators will guide you through this. Sometimes we may get more than one pull request. We typically accept the most quality contribution followed by the one that is made first. Happy contributing.

In this section, you'll see how adding CSS styles to the elements of your CatPhotoApp can change it from simple text to something more.

 Note: Some browser extensions may interfere with elements on the page. If the tests fail, try disabling your extensions for the most reliable experience.


Question:
In the last phrase, it is mentioned a element with , but only an element has : . Rectify to the following: No response . No response
Thanks for opening this issue. This looks like something that can be fixed by "first time" code contributors to this repository. Here are the files that you should be looking at to work on a fix: Change to in the markdown file. Please make sure you read , we prioritize contributors following the instructions in our guides. Join us in our chat room or the forum if you need help contributing, our moderators will guide you through this. Sometimes we may get more than one pull-requests. We typically accept the most quality contribution followed by the one that is made first. Happy contributing.
I think the backticks on the / can be dropped while changing this. Other elements mentioned in the paragraph are not backticked.
But the question is, shouldn't they be? I think they should, to be consistent with the rest of the curriculum. We use backticks with element types.
To be honest I'm not sure what's the current convention, when element type (button/input/output) itself is not actually used in code. This might be also the only project in JS curriculum explicitly naming them in description, instead of referring to them only via id.
Then I feel like the elements shouldn't be mentioned at all. If we mention the element type, I think the types should have backticks. But I guess I can see your point, and I'm not sure what the convention is here.

All of the HTML and CSS for this project has been provided for you. <del> When you're ready to get started, use the `.getElementById()` method to get the input element with the id `number-input`, and store it in a variable called `numberInput`. Use the same method to get the button element with the id `convert-btn` and store it in a variable called `convertBtn`, and the `h2` element with the id `result` and store it in a variable called `result`. </del> <ins> When you're ready to get started, use the `.getElementById()` method to get the `input` element with the id `number-input`, and store it in a variable called `numberInput`. Use the same method to get the `button` element with the id `convert-btn` and store it in a variable called `convertBtn`, and the `output` element with the id `result` and store it in a variable called `result`. </ins> **NOTE**: This project will only convert positive numbers into binary.


Question: Pyodide can crash when adding or method to the class, while NOT trying to write invalid code. I'm mentioning intent, because it can be encountered when attempting to write correct code. ing instance of the class. or method to the class. On each key pressed, code will execute, including the newly written method. So when we are writing the method: Then starting writing inside of the brackets: . Code will be execute also when it's . That's when it will crash hard: Further changes to code will bring up in browser's console: With example challenge to the at the bottom of code. to class definition, add boilerplate: writing between brackets: on the right crashes at the point when it's . Ideally omitting the crashing part. After the crash window needs to be reloaded to make pyodide on the right work again. Tests still appear to work correctly. Recursive function going into maximum call stack size exceeded does not crash pyodide. I've tested example class from above on , it does not crash pyodide.

const ctx: Worker & typeof globalThis = self as unknown as Worker & typeof globalThis; <del> let pyodide: PyodideInterface; </del> <ins> let pyodide: PyodideInterface | null = null; </ins> interface PythonRunEvent extends MessageEvent { data: {

postMessage({ type: 'stopped' }); } <ins> function resetPyodide() { if (pyodide) pyodide = null; void setupPyodide(); } </ins> void setupPyodide(); function initRunPython() { <ins> if (!pyodide) throw new Error('pyodide not loaded'); </ins> // eslint-disable-next-line @typescript-eslint/no-unsafe-call const str = pyodide.globals.get('str') as (x: unknown) => string;

// The runPython helper is a shortcut for running python code with our // custom globals. const runPython = (pyCode: string) => <del> pyodide.runPython(pyCode, { globals }) as unknown; </del> <ins> pyodide!.runPython(pyCode, { globals }) as unknown; </ins> runPython(` import jscustom from jscustom import print

} function handleRunRequest(data: PythonRunEvent['data']) { <del> if (ignoreRunMessages) return; const code = (data.code.contents || '').slice(); // TODO: use reset-terminal for clarity? postMessage({ type: 'reset' }); const { runPython, getResetId, globals, printException } = initRunPython(); // use pyodide.runPythonAsync if we want top-level await </del> try { <del> runPython(code); } catch (e) { const err = e as PythonError; // the formatted exception is printed to the terminal printException(); // but the full error is logged to the console for debugging console.error(err); const resetId = getResetId(); // TODO: if a user raises a KeyboardInterrupt with a custom message this // will be treated as a reset, the client will resend their code and this // will loop. Can we fix that? Perhaps by using a custom exception? if (err.type === 'KeyboardInterrupt' && resetId) { // If the client sends a lot of run messages, it's easy for them to build // up while the worker is busy. As such, we both ignore any queued run // messages... ignoreRunMessages = true; // ...and tell the client that we're ignoring them. postMessage({ type: 'stopped', text: getResetId() }); </del> <ins> if (ignoreRunMessages) return; const code = (data.code.contents || '').slice(); // TODO: use reset-terminal for clarity? postMessage({ type: 'reset' }); const { runPython, getResetId, globals, printException } = initRunPython(); // use pyodide.runPythonAsync if we want top-level await try { runPython(code); } catch (e) { const err = e as PythonError; // the formatted exception is printed to the terminal printException(); // but the full error is logged to the console for debugging console.error(err); const resetId = getResetId(); // TODO: if a user raises a KeyboardInterrupt with a custom message this // will be treated as a reset, the client will resend their code and this // will loop. Can we fix that? Perhaps by using a custom exception? if (err.type === 'KeyboardInterrupt' && resetId) { // If the client sends a lot of run messages, it's easy for them to build // up while the worker is busy. As such, we both ignore any queued run // messages... ignoreRunMessages = true; // ...and tell the client that we're ignoring them. postMessage({ type: 'stopped', text: getResetId() }); } } finally { getResetId.destroy(); printException.destroy(); globals.destroy(); </ins> } <del> } finally { getResetId.destroy(); printException.destroy(); globals.destroy(); </del> <ins> } catch (e) { // This should only be reach if pyodide crashes, but it's helpful to log // the error in case it's something else. console.error(e); void resetPyodide(); </ins> } }


Question:
this makes look like you need to use , but the function call is enough to cause an output to the terminal. Possible solutions: NA NA NA No response
I'd update the instructions removing the part.
Hi, I'm looking to contribute to open source, could I take this ticket on as a way to onboard to this codebase? And also what is the process usually for grabbing a ticket and pushing a PR?
We typically do not assign issues. Instead, we accept the first pull request that comprehensively solves the issue. Issues labelled with or are open for contributions. Please make sure you read . We prioritize contributors following the instructions in our guide. Join us in or if you need help contributing - our community will be happy to assist you.

# --description-- <del> Call the `square_root_bisection` function with the `N` variable as the argument and print the result. </del> <ins> Call the `square_root_bisection` function with the `N` variable as the argument. This will print the result to the console. </ins> Experiment with larger values.

# --hints-- <del> You should call the `square_root_bisection` function with the `N` variable as the argument and print the result. </del> <ins> You should call the `square_root_bisection` function with the variable `N` as the argument. </ins> ```js ({


Question:
A2 English blocks have challenges whose title is displayed next to a completion indicator. The indicator is having a right margin, which creates a gap between the indicator and the text. <img width="746" alt="Screenshot 2024-05-31 at 22 49 13" src=""This issue is because the indicator has a class: This class was harmless as it didn't have any CSS rules associated, until we badges to the user profile page, which caused a class name collision: Remove the class from: Rename the class in to to avoid future collision
I can take this one, but I don't seem to have the permissions to assign myself to this issue.
We typically do not assign issues. Instead, we accept the first pull request that comprehensively solves the issue. Issues labelled with or are open for contributions. Please make sure you read . We prioritize contributors following the instructions in our guide. Join us in or if you need help contributing - our community will be happy to assist you.
Awesome, thanks for clarifying!

margin-left: 1rem; } <del> .badge { </del> <ins> .camper-badge { </ins> margin-right: 1em; } @media (max-width: 768px) {

 {isDonating && (

  <SupporterBadgeEmblem />

)} {isTopContributor && (

  <TopContibutorBadgeEmblem />

challenge: ChallengeWithCompletedNode; }) => ( <Link to={challenge.fields.slug}>       <CheckMark isCompleted={challenge.isCompleted} />  {challenge.title}

const Project = ({ challenge }: { challenge: ChallengeWithCompletedNode }) => ( <Link to={challenge.fields.slug}> {challenge.title}       <CheckMark isCompleted={challenge.isCompleted} />  </Link>


Question:
Describe the bug Instructions ask to modify the list comprehension to give a string only when the item is not zero, and an asterisk character otherwise. The accepted answer is: But other answers like or are equally valid. To Reproduce Steps to reproduce the behavior: to Expected behavior Although the instructions ask for a specific solution, it might not be clear enough. Therefore it would be better to modify the test to accept multiple solutions.
While I do agree, I'm not quite sure how to modify the test to make sure that the two others are seen as possibilities are the moment. I don't think our helper method is equipped enough to handle this.
I would say something like this: Providing all the possible solutions in the list.

The list comprehension assigned to the `row_str` variable should call `str()` on each item `i` in `row` if `i` is truthy, and it should evaluate to `'*'` otherwise. ```js <del> ({ test: () => assert(runPython(`_Node(_code).find_class("Board").find_function("__str__").find_for_loops()[0].find_bodies()[0].find_variable("row_str").find_comp_expr().is_equivalent("str(i) if i else '*'")`)) }) </del> <ins> ({ test: () => assert(runPython(` expressions = ["str(i) if i else '*'","'*' if i == 0 else str(i)","str(i) if i != 0 else '*'"] node =_Node(_code).find_class("Board").find_function("__str__").find_for_loops()[0].find_bodies()[0].find_variable("row_str").find_comp_expr() any(node.is_equivalent(expr) for expr in expressions)`)) }) </ins> ``` # --seed--


Question: Describe the bug Clicking on the certification project name results in both in settings and from the view certification page. ! To Reproduce Steps to reproduce the behavior: to either or (note that you must replace in the link) on a certification project name 404 Page Not Found

'/learn/back-end-development-and-apis/back-end-development-and-apis-projects'; const qaBase = '/learn/quality-assurance/quality-assurance-projects'; const infoSecBase = '/learn/information-security/information-security-projects'; <del> const sciCompPyBase = '/learn/scientific-computing-with-python/' + 'scientific-computing-with-python-projects'; </del> <ins> const sciCompPyBase = '/learn/scientific-computing-with-python'; </ins> const dataAnalysisPyBase = '/learn/data-analysis-with-python/data-analysis-with-python-projects'; const machineLearningPyBase =

{ id: '5e44412c903586ffb414c94c', title: 'Arithmetic Formatter', <del> link: `${sciCompPyBase}/arithmetic-formatter`, </del> <ins> link: `${sciCompPyBase}/build-an-arithmetic-formatter-project/build-an-arithmetic-formatter-project`, </ins> certSlug: Certification.SciCompPy }, { id: '5e444136903586ffb414c94d', title: 'Time Calculator', <del> link: `${sciCompPyBase}/time-calculator`, </del> <ins> link: `${sciCompPyBase}/build-a-time-calculator-project/build-a-time-calculator-project`, </ins> certSlug: Certification.SciCompPy }, { id: '5e44413e903586ffb414c94e', title: 'Budget App', <del> link: `${sciCompPyBase}/budget-app`, </del> <ins> link: `${sciCompPyBase}/build-a-budget-app-project/build-a-budget-app-project`, </ins> certSlug: Certification.SciCompPy }, { id: '5e444147903586ffb414c94f', title: 'Polygon Area Calculator', <del> link: `${sciCompPyBase}/polygon-area-calculator`, </del> <ins> link: `${sciCompPyBase}/build-a-polygon-area-calculator-project/build-a-polygon-area-calculator-project`, </ins> certSlug: Certification.SciCompPy }, { id: '5e44414f903586ffb414c950', title: 'Probability Calculator', <del> link: `${sciCompPyBase}/probability-calculator`, </del> <ins> link: `${sciCompPyBase}/build-a-probability-calculator-project/build-a-probability-calculator-project`, </ins> certSlug: Certification.SciCompPy } ]


Question:
on it says For a beginner, this could be misleading, as they might think, they cannot change the variable. A description like:
We should avoid parenthetical information like that whenever we can, in my opinion. It makes the sentence much harder to parse.
Is it even worth mentioning here? The lesson doesn't show any consequences of immutability, so it might simply be better to remove the sentence.
I feel like it should be mentioned somewhere, but probably the first lesson where its needed
I think it is part of teaching strings. Here is how MDN words it: But it would certainly be worth circling back to it when it becomes relevant to make sure the practical implication of it is shown.
The description accurately mentions that strings in JavaScript are immutable, meaning their contents cannot be changed once created. However, it's important to clarify that while strings themselves are immutable, the variables holding them can be reassigned to new values. Therefore, no changes are necessary in this instance.
I agree, the description is correct, though for someone encountering variables, strings and immutability for the first time, they might get confused, thinking they cannot change the variable as it is a string, which is immutable. you learn how to reassign variables. Maybe not mentioning immutability at this early stage is the better choice.
Good point! Reassigning variables is key. Perhaps mentioning immutability later reinforces the distinction between variable and data type
I would be fine moving it to somewhere closer to where something like array mutation is taught.
I think we should at least update the text to say the variable can be reassigned another value. This early on in the learning process, the difference between a "value" and a "variable containing a value", is likely not that well understood. In some other challenge step, we then show what it actually means that a primitive value is immutable. After they know how to index into a value, then we can show an attempt to update an immutable value directly and explain why it doesn't work.
Let's start there, then. A PR which resolves this issue will update the text: To the text:

JavaScript has seven primitive data types, with `String` being one of them. In JavaScript, a <dfn>string</dfn> represents a sequence of characters and can be enclosed in either single (`'`) or double (`"`) quotes. <del> Note that strings are <dfn>immutable</dfn>, which means once they are created, they cannot be changed. </del> <ins> Note that strings are <dfn>immutable</dfn>, which means once they are created, they cannot be changed. The variable can still be reassigned another value. </ins> Change your `"Hello"` string to use single quotes.


Question:
contains a single CSS rule: This rule is not needed as the underline of the is already turned off by the component library. Remove Remove the class from
This issue is open for contribution. Please make sure you read our as well as our , we prioritize contributors following the instructions in our guides. Join us in our or our if you need help contributing; our moderators will guide you through this. Sometimes we may get more than one pull request. We typically accept the most quality contribution followed by the one that is made first. Happy contributing.

import { CompletedChallenge } from '../../redux/prop-types'; import { getSolutionDisplayType } from '../../utils/solution-display-type'; <del> import './solution-display-widget.css'; </del> import '@freecodecamp/ui/dist/base.css'; interface Props { completedChallenge: CompletedChallenge;

</Button> ); const ShowMultifileProjectSolution = ( <del> <div className='solutions-dropdown'> </del> <ins> <div> </ins> <Dropdown id={`dropdown-for-${id}-${randomIdSuffix}`}> <Dropdown.Toggle className='btn-invert'> {viewText}{' '}

); const ShowProjectAndGithubLinks = ( <del> <div className='solutions-dropdown'> </del> <ins> <div> </ins> <Dropdown id={`dropdown-for-${id}-${randomIdSuffix}`}> <Dropdown.Toggle className='btn-invert'> {viewText}{' '}

<del> .solutions-dropdown a[role='menuitem'] { text-decoration: none; } </del>


Question:
Error message: The string is either empty or holds a space. "empty space" and "blank space" in this context is confusing. Clear wording: No response All No response
Opening this up. A PR which resolves this issue will update the messaging to the "single space" text Jeremy proposed above.
<img width="655" alt="Screenshot 2024-06-07 at 3 20 38 PM" src=""Would you like me to change both beginning and end hints to "single space" make it more simplistic? since the answer is: function padRow(rowNumber, rowCount) { return " " + (rowNumber) + " "; }
Yes, we should use the phrase "single space" in all three spots
aye aye captain!

You should now see the same bunch of characters in your console. Your `padRow` function is doing the exact same thing you were doing earlier, but now it's in a reusable section of its own. <del> Use the addition operator to concatenate a blank space `" "` to the beginning and end of your repeated `character` string. </del> <ins> Use the addition operator to concatenate a single space `" "` to the beginning and end of your repeated `character` string. </ins> Remember that you can use the `+` operator to concatenate strings like this:

# --hints-- <del> You should concatenate an empty space to the beginning of your returned value. </del> <ins> You should concatenate a single space to the beginning of your returned value. </ins> ```js assert.match(padRow(1, 1), /^s/); ``` <del> You should concatenate an empty space to the end of your returned value. </del> <ins> You should concatenate a single space to the end of your returned value. </ins> ```js assert.match(padRow(1, 1), /s$/);


Question:
There is a bug in the challenge learn-basic-debugging-by-building-a-random-background-color-changer/step-8 | when entering it passes the test; ! Device: [MacBook Pro 10.15.7] OS: [ iOS Catalina] Browser: [Brave, Chrome] Version: [...] passes test, when it shouldn't`
Very interesting and confusing finding! This is the passing test: Here's part of the explanation why it passes: Setting to also would pass.

You should not call the `changeBackgroundColor` function. Instead, assign the function reference to the `onclick` property. ```js <ins> assert.strictEqual(typeof btn.onclick, 'function'); assert.strictEqual(typeof changeBackgroundColor, 'function'); </ins> assert.strictEqual(btn.onclick, changeBackgroundColor); ```


Question:
There is a typo in step 87 of Building a Cipher: Fix the typo in the following file:
This issue is open to first-time code contributors to this repository. The file that you should be updating is linked in the original post. Please make sure you read our as well as our , we prioritize contributors following the instructions in our guides. Join us in our or our if you need help contributing; our moderators will guide you through this. Sometimes we may get more than one pull request. We typically accept the most quality contribution followed by the one that is made first. Happy contributing.
Is someone working on this issue? If not, I want to work on it.
We typically do not assign issues. Instead, we accept the first pull request that comprehensively solves the issue. Issues labelled with or are open for contributions. Please make sure you read . We prioritize contributors following the instructions in our guide. Join us in or if you need help contributing - our community will be happy to assist you.

# --description-- <del> Two or more strings can be concatenated by using the `+` operator. For example: `'Hello' + ' there!'` results in `'Hello there!`. </del> <ins> Two or more strings can be concatenated by using the `+` operator. For example: `'Hello' + ' there!'` results in `'Hello there!'`. </ins> Call the `print()` function and use the `+` operator to concatenate the `text` variable to the string `'Encrypted text: '`. Pay attention to the spacing.


Question:
There is an image in the challenge, and the text of the image has a typo: Fix the typo in the following file:
This issue is open to first-time code contributors to this repository. The file that you should be updating is linked in the original post. We typically do not assign issues. Instead, we accept the most quality contribution followed by the one that is made first. Please make sure you read our as well as our , we prioritize contributors following the instructions in our guides. Join us in our or our if you need help contributing; our moderators will guide you through this. Happy contributing.
Fixes Typo in step 1 of Building a Binary Search Tree

This is what a Binary Search Tree looks like:       Begin by defining an empty `TreeNode` class. The `TreeNode` class represents a node in a binary search tree. Use the `pass` keyword to fill the class body and avoid an error.


Question:
In the fill in the blank challenges, the size of the blanks are based on the number of characters in that blank. It's 11px per letter, plus an additional 11px buffer - This works pretty good, but sometimes you get a word with really wide letters and it doesn't fit: <img width="774" alt="Screenshot 2024-06-17 at 5 36 44 PM" src=""^ You can see is a little too wide to fit because it has wide letters. Other times, you have a bunch of narrow letters like with in the image. That fits, but there's more space on each side than needed. The challenge I noticed this on is still in beta, so you will have to run the repo with upcoming changes shown to see this specific one - but you can see it in any of the fill in the blank challenges. to http://localhost:8000/learn/a2-english-for-developers/learn-how-to-document-code-for-a-project/task-38 in the first blank that one of the letters gets cut off. The in firefox, the in Chrome. So browsers are handling it differently. in the third blank the extra space in the input before and after the word. See the image above The answers to fit in the blanks better. I think the solution I would prefer is to make a map of the letters and their spacing and make the size of the input based on what letters are in the answers. Or perhaps just a default size of the 11px or something, and a small group of narrow letters that get maybe 8, and small group wide letters that get maybe 13 or something. Or perhaps we could use a monospace font.
Not sure why, but this is what it looks like for me (Chrome, and in incognito/on Windows). ! Also, the text color doesn't seem to change to white in night mode.
I don't think monospace fonts are quite the answer; at least not itself. ! Sure it's fine for say the word "When" but for "descriptive", it's a little bigger than the blank.
I'm only using the font for the blanks, but the point remains the same.
I think using 14 maxlength will be be a better solution. before : ! after !
That's not a viable solution. That's hard-coding a value for this one specific input. They're dynamically generated we can't do that.
I think this is the way to go. Then we can reliably know the size of every character, space our inputs accordingly, and we get the feature of visual feedback when a word is too long for that blank.
This is because the spacing is configured for 11px wide characters. I'd be willing to bet that monospace font is bigger. :)

} .fill-in-the-blank-input { <ins> font-family: monospace; </ins> padding: 0; text-align: center; background-color: var(--primary-background);

)}`} onChange={this.handleInputChange} data-index={node.value} <del> style={{ width: `${ blankAnswers[node.value].length * 11 + 11 }px` }} </del> <ins> size={blankAnswers[node.value].length} </ins> aria-label={t('learn.blank')} /> );


Question:
There's typo in two hints. Instead of element it mentions . - - This is something that can be fixed by "first time" code contributors to this repository. Here are the files that you should be looking at to work on a fix: List of files: Please make sure you read , we prioritize contributors following the instructions in our guides. Join us in or if you need help contributing, our moderators will guide you through this. Sometimes we may get more than one pull requests. We typically accept the most quality contribution followed by the one that is made first. Happy contributing.
I was making a PR for a different issue and saw this, so I the fix to the PR.

}; ``` <del> When the `#search-input` element contains the value `Pikachu` and the `#search-button` element is clicked, the `#types` element should contain a single inner element with the value `ELECTRIC`. Make sure the `#type` element content is cleared between searches. </del> <ins> When the `#search-input` element contains the value `Pikachu` and the `#search-button` element is clicked, the `#types` element should contain a single inner element with the value `ELECTRIC`. Make sure the `#types` element content is cleared between searches. </ins> ```js async () => {

}; ``` <del> When the `#search-input` element contains the value `94` and the `#search-button` element is clicked, the `#types` element should contain two inner elements with the text values `GHOST` and `POISON`, respectively. Make sure the `#type` element content is cleared between searches. </del> <ins> When the `#search-input` element contains the value `94` and the `#search-button` element is clicked, the `#types` element should contain two inner elements with the text values `GHOST` and `POISON`, respectively. Make sure the `#types` element content is cleared between searches. </ins> ```js async () => {


Question:
There's typo in two hints. Instead of element it mentions . - - This is something that can be fixed by "first time" code contributors to this repository. Here are the files that you should be looking at to work on a fix: List of files: Please make sure you read , we prioritize contributors following the instructions in our guides. Join us in or if you need help contributing, our moderators will guide you through this. Sometimes we may get more than one pull requests. We typically accept the most quality contribution followed by the one that is made first. Happy contributing.
I was making a PR for a different issue and saw this, so I the fix to the PR.

const searchButton = document.getElementById('search-button'); let alertMessage; window.alert = (message) => alertMessage = message; // Override alert and store message <del> const letters = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz' const numbers = '0123456789'; const charactersLength = letters.length; const numbersLength = numbers.length; const firstLetter = letters.charAt(Math.floor(Math.random() * charactersLength)); const secondLetter = letters.charAt(Math.floor(Math.random() * charactersLength)); const thirdLetter = letters.charAt(Math.floor(Math.random() * charactersLength)); const fourthLetter = letters.charAt(Math.floor(Math.random() * charactersLength)); const randomNumber1 = numbers.charAt(Math.floor(Math.random() * numbersLength)); const randomNumber2 = numbers.charAt(Math.floor(Math.random() * numbersLength)); const badName = firstLetter + secondLetter + thirdLetter + fourthLetter + randomNumber1 + randomNumber2; const randomInvalidPokeId = badName; </del> <ins> const randomInvalidPokeId = crypto.randomUUID().substring(0, 6); </ins> searchInput.value = randomInvalidPokeId; searchInput.dispatchEvent(new Event('change')); searchButton.click(); <del> const res = await fetch('https://pokeapi-proxy.freecodecamp.rocks/api/pokemon/' + randomInvalidPokeId.toString()); // Fetch from proxy to simulate network delay </del> <ins> const res = await fetch('https://pokeapi-proxy.freecodecamp.rocks/api/pokemon/' + randomInvalidPokeId); // Fetch from proxy to simulate network delay </ins> if (!res.ok) { <del> await new Promise(resolve => setTimeout(resolve, 1000)); // Additional delay to allow the alert to trigger </del> <ins> await new Promise(resolve => setTimeout(resolve, 2000)); // Additional delay to allow the alert to trigger </ins> assert.include(['pokémon not found', 'pokemon not found'], alertMessage.trim().replace(/[.,?!]+$/g, '').toLowerCase()); }

let alertMessage; window.alert = (message) => alertMessage = message; // Override alert and store message <del> const randomValidPokeId = Math.floor(Math.random() * 1025) + 1; </del> <ins> const randomValidPokeId = String(Math.floor(Math.random() * 1025) + 1); </ins> searchInput.value = randomValidPokeId; searchInput.dispatchEvent(new Event('change')); searchButton.click(); <del> const res = await fetch('https://pokeapi-proxy.freecodecamp.rocks/api/pokemon/' +  randomValidPokeId.toString()); // Fetch from proxy to simulate network delay </del> <ins> const res = await fetch('https://pokeapi-proxy.freecodecamp.rocks/api/pokemon/' +  randomValidPokeId); // Fetch from proxy to simulate network delay </ins> if (res.ok) { <del> await new Promise(resolve => setTimeout(resolve, 1000)); // Additional delay to allow UI to update </del> <ins> await new Promise(resolve => setTimeout(resolve, 2000)); // Additional delay to allow UI to update </ins> <del> const data = await res.json(); const typesEl = document.getElementById('types'); const actualTypes = data.types.map(typeSlot => typeSlot.type.name); </del> <ins> const data = await res.json(); const typesEl = document.getElementById('types'); const actualTypes = data.types.map(typeSlot => typeSlot.type.name); </ins> assert.lengthOf(typesEl.children, actualTypes.length); assert.sameMembers(actualTypes, [...typesEl.children].map(el => el.innerText.trim().toLowerCase())); } } catch (err) {


Question: This endpoint needs to use jwtaccesstoken in the same way that web login does.

/* eslint-disable @typescript-eslint/no-unsafe-member-access */ <del> import { setupServer, superRequest } from '../../jest.utils'; </del> <ins> import { setupServer, superRequest, createSuperRequest } from '../../jest.utils'; </ins> import { AUTH0_DOMAIN } from '../utils/env'; <ins> const mockedFetch = jest.fn(); jest.spyOn(globalThis, 'fetch').mockImplementation(mockedFetch); const newUserEmail = 'a.n.random@user.com'; const mockAuth0NotOk = () => ({ ok: false }); const mockAuth0InvalidEmail = () => ({ ok: true, json: () => ({ email: 'invalid-email' }) }); const mockAuth0ValidEmail = () => ({ ok: true, json: () => ({ email: newUserEmail }) }); </ins> jest.mock('../utils/env', () => { // eslint-disable-next-line @typescript-eslint/no-unsafe-return return {

expect(redirectUrl.pathname).toBe('/authorize'); }); }); <ins> describe('GET /mobile-login', () => { let superGet: ReturnType<typeof createSuperRequest>; beforeAll(() => { superGet = createSuperRequest({ method: 'GET' }); }); beforeEach(async () => { await fastifyTestInstance.prisma.userRateLimit.deleteMany({}); await fastifyTestInstance.prisma.user.deleteMany({ where: { email: newUserEmail } }); }); it('should be rate-limited', async () => { await Promise.all( [...Array(10).keys()].map(() => superGet('/mobile-login')) ); const res = await superGet('/mobile-login'); expect(res.status).toBe(429); }); it('should return 401 if the authorization header is invalid', async () => { mockedFetch.mockResolvedValueOnce(mockAuth0NotOk()); const res = await superGet('/mobile-login').set( 'Authorization', 'Bearer invalid-token' ); expect(res.body).toStrictEqual({ type: 'danger', message: 'We could not log you in, please try again in a moment.' }); expect(res.status).toBe(401); }); it('should return 400 if the email is not valid', async () => { mockedFetch.mockResolvedValueOnce(mockAuth0InvalidEmail()); const res = await superGet('/mobile-login').set( 'Authorization', 'Bearer valid-token' ); expect(res.body).toStrictEqual({ type: 'danger', message: 'The email is incorrectly formatted' }); expect(res.status).toBe(400); }); it('should set the jwt_access_token cookie if the authorization header is valid', async () => { mockedFetch.mockResolvedValueOnce(mockAuth0ValidEmail()); const res = await superGet('/mobile-login').set( 'Authorization', 'Bearer valid-token' ); expect(res.status).toBe(200); expect(res.get('Set-Cookie')).toEqual( expect.arrayContaining([expect.stringMatching(/jwt_access_token=/)]) ); }); it('should create a user if they do not exist', async () => { mockedFetch.mockResolvedValueOnce(mockAuth0ValidEmail()); const existingUserCount = await fastifyTestInstance.prisma.user.count(); const res = await superGet('/mobile-login').set( 'Authorization', 'Bearer valid-token' ); const newUserCount = await fastifyTestInstance.prisma.user.count(); expect(existingUserCount).toBe(0); expect(newUserCount).toBe(1); expect(res.status).toBe(200); }); it('should redirect to returnTo if already logged in', async () => { mockedFetch.mockResolvedValueOnce(mockAuth0ValidEmail()); const firstRes = await superGet('/mobile-login').set( 'Authorization', 'Bearer valid-token' ); expect(firstRes.status).toBe(200); const res = await superRequest('/mobile-login', { method: 'GET', // eslint-disable-next-line @typescript-eslint/no-unsafe-assignment setCookies: firstRes.get('Set-Cookie') }) .set('Authorization', 'Bearer does-not-matter') .set('Referer', 'https://www.freecodecamp.org/back-home'); expect(res.status).toBe(302); expect(res.headers.location).toBe( 'https://www.freecodecamp.org/back-home' ); }); }); </ins> });

import rateLimit from 'express-rate-limit'; // @ts-expect-error - no types import MongoStoreRL from 'rate-limit-mongo'; <ins> import isEmail from 'validator/lib/isEmail'; </ins> import { AUTH0_DOMAIN, MONGOHQ_URL } from '../utils/env'; import { auth0Client } from '../plugins/auth0'; <ins> import { createAccessToken } from '../utils/tokens'; </ins> import { findOrCreateUser } from './helpers/auth-helpers'; <del> const getEmailFromAuth0 = async (req: FastifyRequest) => { </del> <ins> const getEmailFromAuth0 = async ( req: FastifyRequest ): Promise<string | null> => { </ins> const auth0Res = await fetch(`https://${AUTH0_DOMAIN}/userinfo`, { headers: { Authorization: req.headers.authorization ?? '' } }); <del> if (!auth0Res.ok) { req.log.error(auth0Res); throw new Error('Invalid Auth0 Access Token'); } </del> <ins> if (!auth0Res.ok) return null; </ins> <del> const { email } = (await auth0Res.json()) as { email: string }; return email; </del> <ins> // For now, we assume the response is a JSON object. If not, we can't proceed // and the only safe thing to do is to throw. const { email } = (await auth0Res.json()) as { email?: string }; return typeof email === 'string' ? email : null; </ins> }; /**

// all auth routes. fastify.addHook('onRequest', fastify.redirectIfSignedIn); <del> fastify.get('/mobile-login', async req => { </del> <ins> fastify.get('/mobile-login', async (req, reply) => { </ins> const email = await getEmailFromAuth0(req); <del> await findOrCreateUser(fastify, email); </del> <ins> if (!email) { return reply.status(401).send({ message: 'We could not log you in, please try again in a moment.', type: 'danger' }); } if (!isEmail(email)) { return reply.status(400).send({ message: 'The email is incorrectly formatted', type: 'danger' }); } const { id } = await findOrCreateUser(fastify, email); reply.setAccessTokenCookie(createAccessToken(id)); </ins> }); done();


Question:
Under the section, add the following line as the first item:
This issue is open to first-time code contributors to this repository. The file that you should be updating is linked in the original post. We typically do not assign issues. Instead, we accept the most quality contribution followed by the one that is made first. Please make sure you read our as well as our , we prioritize contributors following the instructions in our guides. Join us in our or our if you need help contributing; our moderators will guide you through this. Happy contributing.

#### 2. [JavaScript Algorithms and Data Structures Certification](https://www.freecodecamp.org/learn/javascript-algorithms-and-data-structures-v8/) <ins> - [Learn Introductory JavaScript by Building a Pyramid Generator](https://www.freecodecamp.org/learn/javascript-algorithms-and-data-structures-v8/#learn-introductory-javascript-by-building-a-pyramid-generator) </ins> - [Learn Basic JavaScript by Building a Role Playing Game](https://www.freecodecamp.org/learn/javascript-algorithms-and-data-structures-v8/#learn-basic-javascript-by-building-a-role-playing-game) - [Learn Form Validation by Building a Calorie Counter](https://www.freecodecamp.org/learn/javascript-algorithms-and-data-structures-v8/#learn-form-validation-by-building-a-calorie-counter) - [Learn Basic String and Array Methods by Building a Music Player](https://www.freecodecamp.org/learn/javascript-algorithms-and-data-structures-v8/#learn-basic-string-and-array-methods-by-building-a-music-player)


Question: In step 41 of the RPG project in the JS beta curriculum, the instruction states: Change the property of the to be "You enter the store.". I believe this sentence is not 100% clear without either removing the word “the” in front of or adding the word “variable” to the right of . As it is, the sentence misleads a bit because it says “the ” which makes it sound like it is referring to some text somewhere, instead of the text variable. so either: Change the property of to be "You enter the store.". or Change the property of the variable to be "You enter the store.". will be clearer. Please look at questions posted on the forum for examples of people missing the point of the request with the current wording. I personally prefer the second one. N/A N/A N/A Example of confused learner:

# --description-- <del> Now you need to modify your display text. Change the `innerText` property of the `text` to be `"You enter the store."`. </del> <ins> Now you need to modify your display text. Change the `innerText` property of the `text` variable to be `"You enter the store."`. </ins> # --hints--

button1.onclick = buyHealth; button2.onclick = buyWeapon; button3.onclick = goTown; } --fcc-editable-region--


Question:
Code in the doesn't seem to be evaluated in production for Cash Register project. (Edit)This appear to be related to the code saving / resetting. In development there isn't such issue. Including building production client and serving it. This is actually the only challenge from the new challenges that is using . Old challenges are working fine when using . Both when names start with ` might be somehow deciding factor, but there isn't any other new challenge to check that. After adding function to user code, error moves normally to the next used in test non-defined variable - and then . Steps to reproduce the behavior: (Be logged in, and have previously saved code for project). to solution. Example: tests. errors. Code present in the should be evaluated after the user code, and before running tests. (Edit) When logged out there's different error, or no errors at all(?!). This might be somehow related to saving / resetting code.
Thanks again for the detailed report, You were dead right about the issue: it's due to the fact that saved challenges don't include head or tail (aka and ) and we were just using them in place of challengeFiles (which does have that stuff).
I have marked this as a showstopper seeing as it is affecting camper's ability to complete a certificate project. It would be nice to get the fix in as soon as possible, so the forum isn't filled with support threads for this.

challengeFiles: SavedChallengeFiles; }; <ins> // TODO: remove unused properties and stop returning them from api? (e.g. // history, ext, name) </ins> export type SavedChallengeFile = { fileKey: string; ext: Ext;

<ins> import type { ChallengeFile, SavedChallengeFile } from '../../../redux/prop-types'; import { mergeChallengeFiles } from './saved-challenges'; const jsChallenge = { id: '1', contents: 'js contents', fileKey: 'jsFileKey', name: 'name', ext: 'js' as const, head: 'head', tail: 'tail', history: [], seed: 'original js contents' }; const cssChallenge = { id: '2', contents: 'css contents', fileKey: 'cssFileKey', name: 'name', ext: 'css' as const, head: 'head', tail: 'tail', history: [], seed: 'original css contents' }; const htmlChallenge = { id: '3', contents: 'html contents', fileKey: 'htmlFileKey', name: 'name', ext: 'html' as const, head: 'head', tail: 'tail', history: [], seed: 'original html contents' }; const savedJsChallenge: SavedChallengeFile = { contents: 'saved js contents', fileKey: 'jsFileKey', name: 'name', ext: 'js' as const }; const savedCssChallenge: SavedChallengeFile = { contents: 'saved css contents', fileKey: 'cssFileKey', name: 'name', ext: 'css' as const }; const savedHtmlChallenge: SavedChallengeFile = { contents: 'saved html contents', fileKey: 'htmlFileKey', name: 'name', ext: 'html' as const }; describe('mergeChallengeFiles', () => { it('should return files if savedChallengeFiles is undefined', () => { const files: ChallengeFile[] = [htmlChallenge]; const savedChallengeFiles = undefined; const result = mergeChallengeFiles(files, savedChallengeFiles); expect(result).toEqual(files); }); it('should return an empty array if files is undefined', () => { const files = undefined; const savedChallengeFiles = [savedJsChallenge]; const result = mergeChallengeFiles(files, savedChallengeFiles); expect(result).toEqual([]); }); it('should return files if savedChallengeFiles has a different length', () => { const files: ChallengeFile[] = [cssChallenge]; const savedChallengeFiles: SavedChallengeFile[] = [ savedCssChallenge, savedJsChallenge ]; const result = mergeChallengeFiles(files, savedChallengeFiles); expect(result).toEqual(files); }); it('should return files if the fileKey properties do not match', () => { const files: ChallengeFile[] = [jsChallenge, cssChallenge]; const savedChallengeFiles: SavedChallengeFile[] = [ savedHtmlChallenge, savedCssChallenge ]; const result = mergeChallengeFiles(files, savedChallengeFiles); expect(result).toEqual(files); }); it('should use the contents from the saved file', () => { const files: ChallengeFile[] = [cssChallenge, htmlChallenge, jsChallenge]; const savedChallengeFiles = [ savedJsChallenge, savedCssChallenge, savedHtmlChallenge ]; const result = mergeChallengeFiles(files, savedChallengeFiles); expect(result).toEqual([ { ...cssChallenge, contents: savedCssChallenge.contents }, { ...htmlChallenge, contents: savedHtmlChallenge.contents }, { ...jsChallenge, contents: savedJsChallenge.contents } ]); }); }); </ins>

<ins> import { ChallengeFile, SavedChallengeFile } from '../../../redux/prop-types'; export function mergeChallengeFiles( files?: ChallengeFile[] | null, savedFiles?: SavedChallengeFile[] | null ): ChallengeFile[] { if (!files) return []; if (!savedFiles) return files; if (files.length !== savedFiles.length) return files; const sortedChallengeFiles = files.sort((a, b) => a.fileKey.localeCompare(b.fileKey) ); const sortedSavedChallengeFiles = savedFiles.sort((a, b) => a.fileKey.localeCompare(b.fileKey) ); const fileKeysMatch = sortedChallengeFiles.every( (file, index) => file.fileKey === sortedSavedChallengeFiles[index].fileKey ); if (!fileKeysMatch) return files; return sortedChallengeFiles.map((file, index) => ({ ...file, contents: sortedSavedChallengeFiles[index].contents })); } </ins>

import MultifileEditor from './multifile-editor'; import DesktopLayout from './desktop-layout'; import MobileLayout from './mobile-layout'; <ins> import { mergeChallengeFiles } from './saved-challenges'; </ins> import './classic.css'; import '../components/test-frame.css';

return challenge.id === challengeMeta.id; }); <del> createFiles(savedChallenge?.challengeFiles || challengeFiles || []); </del> <ins> createFiles( mergeChallengeFiles(challengeFiles, savedChallenge?.challengeFiles) ); </ins> initTests(tests); if (showProjectPreview) openModal('projectPreview');


Question: Thanks for opening this issue. This looks something that can be fixed by "first time" code contributors to this repository. Here are the files that you should be looking at to work on a fix: List of files: Please make sure you read , we prioritize contributors following the instructions in our guides. Join us in or if you need help contributing, our moderators will guide you through this. Sometimes we may get more than one pull requests. We typically accept the most quality contribution followed by the one that is made first. Happy contributing.

**User Stories:** 1. You should have an `input` element with an `id` of `"search-input"` <del> 1. You should have a `button` element with an `id` of `"search-button` </del> <ins> 1. You should have a `button` element with an `id` of `"search-button"` </ins> 1. You should have an element with an `id` of `"pokemon-name"` 1. You should have an element with an `id` of `"pokemon-id"` 1. You should have an element with an `id` of `"weight"`


Question:
In the last part of step 5 in the rock, paper, scissors review project, the instructions given say: If there is a winner, you will want to show the resetGameBtn button and hide the optionsContainer so the player can play again. Tips You can use the property to show the resetGameBtn button and hide the optionsContainer. I have 2 concerns here. 1- at no point is there any mention of what type of display the resetGameBtn requires (is it block, inline-block, flex...?) I guessed 'block' which worked but the lack of this detail made me hesitate. 2- the mention of '' is confusing. In the previous project, using style.display was discussed before in the rpg project () but it was never referred to or mentioned as '' before. I wasn't sure if 'el' meant the element in question or if there was an actual 'el' variable somewhere. I ended up going with what made sense (replacing the 'el' with the element reference) but I'm not sure how easy this would be for someone with only the last few js projects under their belt. A clarification would be great here. N/A N/A No response N/A No response
I fixed the wording of the challenge to make it more clear to the user.
This issue has not been triaged yet, in the future please do not create a PR until then. Anyway, I will open it up to contribution.
my bad sir, won't happen again.

**Tips** <del> - You can use the `el.style.display` property to show the `resetGameBtn` button and hide the `optionsContainer`. </del> <ins> Use the `style.display` property on an element, with the value `"block"` or `"none"`, to show or hide the element. </ins> # --hints--

} else { assert.equal(winnerMsgElement.innerText, "Computer has won the game!"); } ``` You should hide the `optionsContainer` and if the player or computer has reached three points.


Question:
Example Code Below the expenses list, create a while loop. Use True for the condition, and print the string 'nExpense Tracker' inside the loop body to show the title of the program. Highlighted portion should instead be changed to False, since while loops terminate when their condition is false.
As an alternative "A while loop is another kind of loop that runs a portion of code until a specified condition is <b</b:"
My suggestion for clarity "A while loop is another kind of loop that runs a portion of code a specified condition is ."
I would go with:

# --description-- <del> A `while` loop is another kind of loop that runs a portion of code until a specified condition is `True`: </del> <ins> A `while` loop is another kind of loop that runs a portion of code as long as a specified condition is `True`. The loop terminates when the condition becomes `False`: </ins> ```py while condition:


Question:
The form element is missing a closing tag, but the challenge still accept it and let me move onto the next step It should respond with "You are missing the closing tag", instead of accepting it and letting you move onto the next step ! Device: [e.g. iPhone 6, Laptop] OS: [e.g. iOS 14, Windows 10, Ubuntu 20.04] Browser: [e.g. Chrome, Safari] Version: [e.g. 22] According to It should result in a valid form element, because the browser will close it. However, the element technically does not have any "Tag omission" so it should have an end tag in the HTML (even if it gets to the DOM by the browser).
This is no more the first project, it would become regex galore, and when possible instead we prefer to not use regex, so fixing all these tests is probably not worth it
We don't need to keep testing for closing tags everywhere. But this challenge is about building a form, so having one test to check the initial form element is created correctly doesn't seem unreasonable.
Agreed, this seems like a good reason to regex test a closing tag. Opening for contribution.

assert.equal(document.querySelector('form')?.action, 'https://register-demo.freecodecamp.org/'); ``` <ins> Your `form` element should have a closing tag `</form>`. ```js assert.match(code, /</form>/); ``` </ins> # --seed-- ## --seed-contents--