jiebi/CodeConvo huggingface dataset:
Change:
in Step 70 of the music player project (js beta) the step requests a ternary statement that is assigned to a variable. People on the forum have a fair amount of struggles with this which is expected given that this may be the first time they are putting these two things together (ternary and assignment). But, now that I've personally moved on to the spam filter project, I noted a curious thing. Step 5 of the spam filter project has a handy-dandy example of exactly the type of thing needed back in the music player project: Here is an example of assigning the result of a ternary operator to an element's text content: Example Code So this issue is a request to consider adding a similar example into step 70. A quick search for this step in the forum will show many examples of people struggling with this code's construction as further evidence of need. I realise that this may make the text too long for step 70 though. If the example is , please modify it to include the 'else' section too. And maybe explain what is el. (el is the element reference) Thanks for your help. N/A N/A No response N/A No response
I think we can simplify the example to something like: And say "here's an example of assigning the result of a ternary operator to a variable. now do this for the elements text contents."
I started working on this and I was wondering how the localization is handled for the challenge markdowns? do I change one of the markdowns and run a script to apply it all?
You only need to update the English markdown. The rest are handled through Crowdin and our automated syncs. However, this issue has not been marked as open for contribution yet.
yeah I realized the issue is marked as discussing still, what more is needed to move the issue forward?
No one else has chimed in, so I'll go ahead and open it for contribution. A PR which resolves this issue should apply my suggestion:

Discussion:
console.log(element.textContent); // Output: This is some text content ``` <ins> You can use a ternary operator to conditionally set the text content value. Here is an example of assigning the result of a ternary operator to a variable: ```js const example = condition ? "I'm true" : "I'm false"; ``` </ins> Use a ternary operator to check if `currentTitle` evaluates to a truthy value. If it does, set `playingSong.textContent` to `currentTitle`. Otherwise, set it to an empty string. Then below that, use a `ternary` operator to check if `currentArtist` is truthy. If so, set `songArtist.textContent` to `currentArtist`. Otherwise, set it to empty string.
Change:
The text desription of this challenge is all wrong. It asks you to get a lot of elements, but the code to do so appears to already be populated when the page loads. See screenshot. As such following the instructions would duplicate the code. All the task requires is that you create the following variables. But that is not what the task description asks for: let diceValuesArr = []; let isModalShowing = false; let score = 0; let total = 0; let round = 1; let rolls = 0; let diceValuesArr = []; let isModalShowing = false; let score = 0; let total = 0; let round = 1; let rolls = 0; My code above works. But this does not match what the description asks for. ! Windows 10, Chrome No response

Discussion:
``` ```js <del> const listOfAllDice = document.querySelectorAll(".die"); const scoreInputs = document.querySelectorAll("#score-options input"); const scoreSpans = document.querySelectorAll("#score-options span"); const currentRound = document.getElementById("current-round"); const currentRoundRolls = document.getElementById("current-round-rolls"); const totalScore = document.getElementById("total-score"); const scoreHistory = document.getElementById("score-history"); const rollDiceBtn = document.getElementById("roll-dice-btn"); const keepScoreBtn = document.getElementById("keep-score-btn"); const rulesContainer = document.querySelector(".rules-container"); const rulesBtn = document.getElementById("rules-btn"); </del> --fcc-editable-region-- --fcc-editable-region--
Change:
There’s a typo in the instruction of step 11, which introduces the built-in function hasattr, which is mistyped as “hasatttr”. Campers who follow it would find the console raises “NameError: name ‘hasatttr’ is not defined”. Correct the typo No response Device: PC OS: Windows 10 Browser: Chrome Version: 126.0.6478.182 No response
Thank you for reporting the issue. This issue is open to first-time code contributors to this repository. The file that you should be updating is: 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.
Thanks for quick response. I have made a pull request.

Discussion:
# --description-- <del> The `hasatttr` built-in function takes an object as its first argument and a string representing an attribute name as its second argument. It returns a boolean indicating if the object has the specified attribute. </del> <ins> The `hasattr` built-in function takes an object as its first argument and a string representing an attribute name as its second argument. It returns a boolean indicating if the object has the specified attribute. </ins> Now you are going to use the `__init_subclass__` method to check if the child class has the `degree` attribute at the moment of the instantiation.
Change:
When I want to add my x account to my profile the format of the link must be but the domain nowadays is and when I add it with x instead of twitter it shows me an error ! to the settings of your profile the Your Internet Presence section to add/change the Twitter account link It should allow both domains to be entered not only ! Device: [Desktop] OS: [Ubuntu 22.04] Browser: [Firefox v128.0 - 64bit] If the context is not enough for the issue reply to this issue and mention my username
! Huh?? That's me too!!!
Hello, I am new to contributing so please inform me if I am doing anything wrong. The Line254 effects social link validation. could be changed to X.com for a quick patch although moderators may want to redefine all twitter references to x. Line239
Hey Yes, I think the same but I think it should not be changed to x.com we have to change the value to array instead of string like this: then use a conditional statement to be sure the entered data from a user includes one of these two.

Discussion:
const allowedSocialsAndDomains = { githubProfile: 'github.com', linkedin: 'linkedin.com', <del> twitter: 'twitter.com', </del> <ins> twitter: ['twitter.com', 'x.com'], </ins> website: '' };

const url = new URL(val); const topDomain = url.hostname.split('.').slice(-2); if (topDomain.length === 2) { <del> return topDomain.join('.') === domain; </del> <ins> return Array.isArray(domain) ? domain.some(d => topDomain.join('.') === d) : topDomain.join('.') === domain; </ins> } return false; } catch (e) {
Change:
In the building a spam filter project's step 's instructions, we are told: "Remember that arrays have a .some() method. " However, we cannot remember as it was not taught. In fact it is not actually taught until step 100 of the building a spreadsheet project as far as I'm aware: I suggest that the part of lesson 100 that applies to teaching the some() method be moved into the spam filter project's step 12. N/A Adding the missing lesson for some() before or during step 12 of the building a spam filter project. No response N/A No response
Hello I am a first timer, can i take up this issue? because adding the .some() function explaination to step 12 will solve this issue and i think it will be pretty easy to do that..

Discussion:
# --description-- <del> Arrays have a `.some()` method. Like the `.filter()` method, `.some()` accepts a callback function which should take an element of the array as the argument. The `.some()` method will return `true` if the callback function returns `true` for at least one element in the array. Here is an example of a `.some()` method call to check if any element in the array is an uppercase letter. ```js const arr = ["A", "b", "C"]; arr.some(letter => letter === letter.toUpperCase()); ``` </del> Add a `someeven` property to your `spreadsheetFunctions` - use the `.some()` method to check if any element in the array is even. # --hints--

# --description-- <del> Remember that arrays have a `.some()` method. Use the `.some()` method to check if testing your `msg` on any of your `denyList` regular expressions returns `true`. </del> <ins> Arrays have a `.some()` method. Like the `.filter()` method, `.some()` accepts a callback function which should take an element of the array as the argument. The `.some()` method will return `true` if the callback function returns `true` for at least one element in the array. Here is an example of a `.some()` method call to check if any element in the array is an uppercase letter. ```js const arr = ["A", "b", "C"]; arr.some(letter => letter === letter.toUpperCase()); ``` Use the `.some()` method to check if testing your `msg` on any of your `denyList` regular expressions returns `true`. </ins> Use `regex` as the parameter for the callback function, for clarity.
Change:
There is a typo in the following sentence: . Rectify typo from time to times. No response Device: Laptop OS: Windows 11 Pro 23H2 .3880 Browser: Brave Version: Version 1.67.134 Chromium: 126.0.6478.186 (Official Build) (64-bit)]() No response
This has been opened for First Timers only 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

Discussion:
Your fCC Authors Page is now complete. But you could improve on a few things. <del> First, if you click the `Load More Authors` button a couple of time, you'll see that it won't add more authors to the page. That's because you've reached the end of the authors list. For a better user experience, you should make it clear when there's no more data to display by disabling the button and changing its text. An `if` statement is the perfect tool for this. </del> <ins> First, if you click the `Load More Authors` button a couple of times, you'll see that it won't add more authors to the page. That's because you've reached the end of the authors list. For a better user experience, you should make it clear when there's no more data to display by disabling the button and changing its text. An `if` statement is the perfect tool for this. </ins> Inside the `fetchMoreAuthors` function, write an `if` statement and set the condition to `authorDataArr.length <= endingIndex` – meaning there's no more data to load.
Change:
Initial text of the button is . After step clicking button is expected to change text to , capitalizing the second word. Clicking it again is expected to change text to . Which is too differing from initial capitalization. n/a Capitalization should be consistent throughout the project. Either Show rules and Hide rules; or Show Rules and Hide Rules. No response n/a No response
We will do this option

Discussion:
When the user clicks on the `Show rules` button, the rules for the game should display on the screen. When they click on the button again, the rules should be hidden. <del> Use an event listener to invert the value of the `isModalShowing` variable, toggle the visibility of the `rulesContainer`, and change the text of the `rulesBtn` to `Show Rules` or `Hide Rules`. </del> <ins> Use an event listener to invert the value of the `isModalShowing` variable, toggle the visibility of the `rulesContainer`, and change the text of the `rulesBtn` to `Show rules` or `Hide rules`. </ins> # --hints--

assert.isTrue(rulesContainer.checkVisibility()); ``` <del> When your `rulesBtn` is clicked, your `rulesBtn` should say `Hide Rules`. </del> <ins> When your `rulesBtn` is clicked, your `rulesBtn` should say `Hide rules`. </ins> ```js <del> assert.strictEqual(rulesBtn.innerText.trim(), "Hide Rules"); </del> <ins> assert.strictEqual(rulesBtn.innerText.trim(), "Hide rules"); </ins> ``` When your `rulesBtn` is clicked again, your `isModalShowing` should be `false`.

assert.isFalse(rulesContainer.checkVisibility()); ``` <del> When your `rulesBtn` is clicked again, your `rulesBtn` should say `Show Rules`. </del> <ins> When your `rulesBtn` is clicked again, your `rulesBtn` should say `Show rules`. </ins> ```js <del> assert.strictEqual(rulesBtn.innerText.trim(), "Show Rules"); </del> <ins> assert.strictEqual(rulesBtn.innerText.trim(), "Show rules"); </ins> ``` # --seed--

isModalShowing = !isModalShowing; if (isModalShowing) { <del> rulesBtn.textContent = "Hide Rules"; </del> <ins> rulesBtn.textContent = "Hide rules"; </ins> rulesContainer.style.display = "block"; } else { <del> rulesBtn.textContent = "Show Rules"; </del> <ins> rulesBtn.textContent = "Show rules"; </ins> rulesContainer.style.display = "none"; } });
Change:
There is an extra spacer in the top of the donate page. It might be cause by the donate page or its wrappers. The spacer should be removed or adjusted so it does not show up unecessarly. The issue is viewable locally or on production by viewing the donate page. <img width="1067" alt="Screenshot 2024-07-23 at 3 02 34 PM" src=""- 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
Hi, can I be assigned to this task?
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.
sorry, the issue not so clear for me... where is extra space mentioned in issue? is it this gap under the topbar? !
I think we should just remove the spacers: If the page content needs some extra space below the nav, then the content could have some margin/padding in its CSS.

Discussion:
/> ) : null} <SignoutModal /> <del> {isChallenge && !examInProgress && isRenderBreadcrumb ? ( <div className='breadcrumbs-demo'> <BreadCrumb block={block as string} superBlock={superBlock as string} /> </div> ) : isExSmallViewportHeight ? ( <Spacer size='xxSmall' /> ) : ( <Spacer size='small' /> )} </del> <ins> {isChallenge && !examInProgress && (isRenderBreadcrumb ? ( <div className='breadcrumbs-demo'> <BreadCrumb block={block as string} superBlock={superBlock as string} /> </div> ) : ( <Spacer size={isExSmallViewportHeight ? 'xxSmall' : 'small'} /> ))} </ins> {fetchState.complete && children} </div> {showFooter && <Footer />}
Change:
1) Navigate to a multifile challenge: 2) Input some code over multiple lines: 3) Save code 4) Refresh page ! Seen in: I assume this has to do with the container defaulting to the size it is originally given (e.g. 1 line), even though the saved code spans more.
An issue with the label is open 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
This is where the bounds come from. A function called in . In order to fix this, we're going to have to save the current editable region boundaries and then load from them in this function.
Hi Would using be appropriate for persisting the editable region bounds? We could potentially leverage the existing or methods to handle this, rather than writing to every time is called. Please let me know your thoughts or if there’s a better approach. Thanks!
The editable region boundaries are already persisted in local storage, as shown in the screenshot. The issue is when the editor component is mounted, it is preferring the editable regions defined in the challenge seed, as opposed to using the boundaries kept in the saved code from local storage.

Discussion:
ext: Ext; name: string; history?: string[]; <ins> editableRegionBoundaries?: number[]; </ins> contents: string; };

return sortedChallengeFiles.map((file, index) => ({ ...file, <del> contents: sortedSavedChallengeFiles[index].contents </del> <ins> contents: sortedSavedChallengeFiles[index].contents, editableRegionBoundaries: sortedSavedChallengeFiles[index].editableRegionBoundaries </ins> })); }
Change:
The second paragraph of step 8 in the Number Sorter project is awkwardly phrased. The instructions begin as follows: You should use () to print out the result of inputValues. Write the code for this inside the sortInputArray function. To see the result for the inputValues array, log out the inputValues array to the console. Then click on the sort button and open up the console. You should see an array of strings like this: The second paragraph should really say: To see the logged inputValues array, click on the sort button and open up the console. You should see an array of strings like this: It's clearer than the original text. The 1st and 2nd paragraphs together can flow better together as well since the first paragraph just told us to log the inputValues array (so saying again 'log out the inputValues array' sounds wrong). N/A rewrite the 2nd paragraph with clearer text. No response N/A No response
I can work on this issue.
I will open this up as it sounds like a reasonable change. Please make sure you have read the . When an issue has the label, it is not yet ready for a PR. It must be triaged first.

Discussion:
You should use `console.log()` to print out the result of `inputValues`. Write the code for this inside the `sortInputArray` function. <del> To see the result for the `inputValues` array, log out the `inputValues` array to the console. Then click on the sort button and open up the console. You should see an array of strings like this: </del> <ins> To see the logged `inputValues` array, click on the sort button and open up the console. You should see an array of strings like this: </ins> ```js [ '8', '2', '4', '1', '3' ]
Change:
I have completed this, but noticed there is an error in the code which doesn't seem to cause any problems during the lessons. In lesson 20 we use an if statement (seen in the first code block below) and the action is . This stays the same in steps 21 through 25. However from steps 26 onwards has been replaced by as highlighted in the second code block below. (Please note that I did not change the code and have pressed Reset a number of times but the code stays the same) Please advise First code block: Second code block: I expect code that passed to stay the same and be correct - is the code in the second code block above correct? No response Device: HP Laptop OS: Windows 10 Browser: Firefox Version: 128.0.2 No response
Thanks for reporting this. The answer is no, that snippet of code is not correct and it should be fixed. Each occurrence of should be replaced with

Discussion:
terms = [] for n, coefficient in self.coefficients.items(): if not coefficient: <del> coefficient </del> <ins> continue </ins> --fcc-editable-region-- if n == 0: terms.append(f'{coefficient:+}')

terms = [] for n, coefficient in self.coefficients.items(): if not coefficient: <del> coefficient </del> <ins> continue </ins> if n == 0: terms.append(f'{coefficient:+}') elif n == 1:
Change:
Step 18 of the spreadsheet project (js beta) asks us to: Set the aria-label attribute for the input element to the same value as the id attribute. This should be doable just by saying: ; But this code is not accepted and the hint shown is: You should assign letter + number to input.ariaLabel. I think the step should accept assigning into input.ariaLabel No response N/A No response
Yeah, I agree. should pass the test. Since the instruction is vague, I think the test should allow both answers: - Note that the hint text needs to be updated as well. I guess it could be something like:

Discussion:
``` <del> You should assign `letter + number` to `input.ariaLabel`. </del> <ins> You should give `input.ariaLabel` the same value as `input.id`. </ins> ```js <del> assert.match(code, /input.ariaLabels*=s*letters*+s*number/); </del> <ins> assert.match(code, /input.ariaLabels*=s*((letters*+s*number)|(input.id))/); </ins> ``` # --seed--
Change:
The instructions for step 102 of the spreadsheet project (js beta) want us to "use the first two numbers from an array to generate a random whole number." They also say that "The range for this number starts at the smaller positive number (inclusive) among the first two numbers and ends just before the sum of these two numbers." However, looking at the solution, no effort is made to sort out which number is smallest before finding the random value. This tells me that this step is assuming we know that the array is in ascending sorted order. I would like the step to just say this explicitly. For eg it could say: Create a random property. This property should use the first two numbers from an array that has been sorted in ascending order to generate a random whole number. (the change is I said 'an array that has been sorted in ascending order') Or, we could just not care in what order the random number gets generated? (and change the instructions to say to get a random number between the first two numbers of the array regardless of which one goes first?) N/A instructions can be more explicit or checks can be more lenient No response N/A No response
I wrote about this also on discord - I'm not sure why the constraint to have the first number smaller. There's no reason to not allow first number to be higher than second one. Both will give number from different, valid ranges: -number from to . -number from to .
Yeah, I'd just update the text to say:

Discussion:
# --description-- <del> Create a `random` property. This property should use the first two numbers from an array to generate a random whole number. The range for this number starts at the smaller positive number (inclusive) among the first two numbers and ends just before the sum of these two numbers. Use the `Math.floor()` and `Math.random()` methods for the calculation. </del> <ins> Create a `random` property. This property should use the first two numbers from an array to generate a random whole number. The range for this number starts at the first number (inclusive) of the two and ends just before the sum of these two numbers. Use the `Math.floor()` and `Math.random()` methods for the calculation. </ins> # --hints--
Change:
the check for step 15 of the shopping cart does not allow a space to be placed to the immediate right-hand-side of the word constructor (just before the parenthesis), however that seems to be valid syntax. update the check for this step to allow a space to the immediate right-hand-side of the word constructor No response N/A No response
I found a similar issue with another step here: (it also doesn't allow the constructor to have a single space to the immediate right of the word constructor) Can this be fixed at the same time?

Discussion:
You should add a `constructor` method to the `ShoppingCart` class. ```js <del> assert.match(code,  /classs+ShoppingCarts*{s*constructor(s*)s*/) </del> <ins> assert.match(code,  /classs+ShoppingCarts*{s*constructors*(s*)s*/) </ins> ``` Your `constructor` method should be empty. ```js <del> assert.match(code,  /classs+ShoppingCarts*{s*constructor(s*)s*{s*}s*}/) </del> <ins> assert.match(code,  /classs+ShoppingCarts*{s*constructors*(s*)s*{s*}s*}/) </ins> ``` # --seed--