Go to CS2113/T main site
  • Dashboards home
  • Participation dashboard
  • Forum dashboard
  • iP progress
  • iP comments
  • iP Code
  • tP progress
  • tP comments
  • tP Code
  • Forum activities dashboard

    This dashboard is updated weekly.

    [This page was last updated on Apr 08 2021] [ indicates those watching the forum (kudos πŸ‘)]

    I received this comment on my PR, but I don't quite understand what it means:

    "It is good that new exception classes are created for different purpose. However, in this case, it currently seems to be doing the same thing as its parent class, Exception. Consider revising empty classes by removing them or updating them accordingly."

    Aren't more exceptions to catch bad error cases better? That's what I understood from one of my previous questions.

    My teammate tried my jar and he got this error on my jar:

    Error: LinkageError occurred while loading main class duke.Duke

        java.lang.UnsupportedClassVersionError: duke/Duke has been compiled by a more recent version of the Java Runtime (class file version 58.0), this version of the Java Runtime only recognizes class file versions up to 55.0
    

    Why does this happen, is this a problem?

    How to fix this problem, if it is not acceptable problem?

    I was too excited to start doing the Level 9 increment (and A-JavaDoc), that I overlooked the instructions to do them in separate branches again (since A-MoreOOP was done on master branch).

    So, my work is done on master branch. How to reverse it and make the new branches for the git merging requirement? I'm sure it would be quite troublesome. During final grading, will they track this git merging, or will only the final product be graded?

    try {

                Parser.executeCommand(Parser.input, command);
    
            } catch (InvalidCommandException e) {
    
                Ui.showInvalidCommandError();
    
            } catch (EmptyInputException e) {
    
                Ui.showEmptyInputError();
    
            } catch (StringIndexOutOfBoundsException e) {
    
                Ui.showNoTimeAddedError();
    
            } catch (InvalidEventTimeException e) {
    
                Ui.showInvalidEventTimeError();
    
            } catch (InvalidDeadlineTimeException e) {
    
                Ui.showInvalidDeadlineTimeError();
    
            } catch (NumberFormatException e) {
    
                Ui.showInvalidIntegerTaskIndexError();
    
            } catch (IndexOutOfBoundsException e) {
    
                Ui.showTaskIndexNotExistsError();
    
            }
    

    The above is my code. As you can see, there are many exceptions I tried to catch. But, I didn't know you can shrink them all down to this:

    public void run() {

    ui.showWelcome();
    
    boolean isExit = false;
    
    while (!isExit) {
    
        try {
    
            String fullCommand = ui.readCommand();
    
            ui.showLine(); // show the divider line ("_______")
    
            Command c = Parser.parse(fullCommand);
    
            c.execute(tasks, ui, storage);
    
            isExit = c.isExit();
    
        } **catch (DukeException e) {**
    
            ui.showError(e.getMessage());
    
        } finally {
    
            ui.showLine();
    
        }
    
    }
    

    }

    Source: Week 7, A-MoreOOP.

    How to do that?

    I'm not sure why the Github Classroom autograder is rejecting my work, even though my code works fine on my local machine.

    I've pushed the entire thing to the Github Classroom, so I don't see why there would be a build error.

    Therefore, I am stuck on Week 2 Ex 2. Why is this?

    In Week 2, the iP weekly homework instructs us to complete "Level-0: Greet", and commit it. But, I believe that my sourcetree only commits to my local repository, rather than my public Github account for some reason. To do so, I need to push the commit to my account. Is this the correct way?

    Does the automatic grading script check our accounts at 00:00 before our tutorial and grades us accordingly?

    Sorry, could I ask, what are the tags thing you just mentioned? I was not aware of that feature.

    I’m happy to say that I have managed to push my commit to my online GitHub fork for the first implementation πŸ˜ƒ

    Very nasty to give us invalid inputs so early in the course! Is this the expectation we should have for future encounters in the module? If I recall correctly, it was mentioned that the "Practical Exam" would be other students attempting to break our software, isn't it?

    Update: I have completed Week 2 Ex 3 and Ex 4 with no issue, it is only Ex 2 that is having issue. I'm confused at why this is the case, could it be because of the risk of invalid input in args?

    Thanks for viewing.

    as prof said in the other thread, try checking for null and return nothing

    I did that, but it seems like my autograder is still rejecting my answer, for some reason. :>

    as prof said in the other thread, try checking for null and return nothing

    Okay, did a bit more googling and managed to solve it. Apparently, in Java, having null arguments is not equivalent to having 0 arguments. πŸ‘Ž Learnt something new about Java today!

    Though, it is a bit too tricky to be the second testcase overall for this course 😦

    @Leeyp it was not done intentionally.

    Hopefully, no such encounters in the future 🀞

    PE is a different matter entirely. We will talk about it when it is the right time!

    Hi, would like to clarify on this task too. Is it expected to observe a "Autograding fail" result (Points 0/1) in the Git autograding status upon pushing?

    Expansion of the error message states testMain failed.

    But the code runs fine on local terminal upon manual insertion of the names.

    The test case can be completed assuming adversarial inputs. If you solved it, you will get a green tick like for Ex 3 and 4 (arguably a lot easier!). Good luck.

    Dear Prof,

    I'm unclear about the requirements for Task 3.

    The prompt from Task 3 expects this, when a task is marked as done, with [x], and if its not done, it is [ ].

    But, the partial code generously provided by the prompt using "A-Classes" gives us a [tick] and [x] instead:

    So, which style of "done" is expected of us?

    A secondary question - do we need to include tags for special increments like A-CodingStandard and Extension: A-Classes? I don't think I really need to code anything for those since they seem about 'style' and 'good coding practices'. πŸ˜•

    Lastly, may I clarify what it means to commit for A-CodingStandards or A-Classes? Are those compulsory for the project, or for students to "get "A"" ? How do we submit or fulfill those extensions?

    Thank you!

    Great, thank you prof. I will leave it like this then. I was just concerned if it was too long or ugly.

    Dear Prof,

    Thank you so much for your advice. I have managed to solve the problem and do things the right way.

    Now, I have another question.

    In my "wrong" A-JavaDoc, I wrote javadoc comments for "Find" methods written in Level 9.

    But, when I did the "right" way and branched out, then merged back, my Javadoc comments are gone, since Javadoc is meant to be done parallel from Level 9, the "Find" functions didn't exist yet!

    So, my new master branch had lost the Javadoc comments for Level-9 work. This, is intended, by design.

    But, now, how do I get back the Javadoc comments from my old commit/push? Since the "new" master branch is now "behind" my old branch, missing Javadoc comments for Find methods, I tried merging back to the old commit to make a new commit, but it wouldn't let me, because the new commits deleted information from the old commits.

    In the end, to solve this problem, I did a very non-gitty way of copy pasting my old work (Javadoc comments for Level 9 work) into my newest master branch, re-committed, and re-pushed as per normal.

    But I wonder if there is a more gitty way of doing things, that is to save/merge with an older commit which has useful stuff that was deleted later, but you didn't want it to be deleted previously?

    Sorry if my question doesn't make much sense, I tried making it as clear as I can!

    TL;DR: Old work done sequentially has Javadoc comments for "Find" function. New work done in parallel has no Javadoc comments for "Find" function. How to get my Javadoc comments from an old commit to reappear in git?

    Dear Prof,

    Thank you for your advice. Seems like that was a careless mistake that could have led to very disturbing and urgent consequences!

    Do I have to fix all my commits for all my previous IP work? Since, if the TA checks, then it would be disturbing if they cannot run my code for something like Level-1 or Level-6, etc? Or is that fine, since only my final Jar is being graded?

    Thank you so much!

    Ok, thanks prof!

    I have a custom exception message, but I put it into Ui class instead. So, it will print the message when this exception is triggered. Is that the wrong way?

    Because otherwise my try/catch statement will be the one that is empty, and that is the one that the Coding Quality guidelines say is bad.

    Great idea, thanks prof!

    What is the correct format for representing try-catch blocks in sequence diagrams? Would it be using alt? Because technically 90% of the code in try block still can get executed before the catch is triggered. Alt implies that it is a strict either or.

    Thanks!

    Is there any specific UML notation for methods with the same name that are overloaded?

    e.g.

    public void printThing(String message) {

    print(message);
    

    }

    public void printThing(String message, int x) {

    while (x--) {
    
        print(message);
    
    }
    

    }

    The original commands from prof didnt work for me. I did this instead and it works:

    git update-index --chmod=+x runtest.sh

    git commit -m "Update runtest.sh"

    I have to define a function that may throw several exceptions, but that makes the function definition line very long. I remember that there is a "hard limit" on how long a line can be. If this function definition line exceeds this limit, how do I format the layout? Thank you!

    I have pushed a "Level-1" tag on a commit for my ip, but i found some bugs, fixed them, committed and push again. From what i understand, i cannot assign 2 commits with the same tag. How do i delete tags and re-tag the correct commit? will the tags be used to trace which commit will be graded? thanks!

    i dont quite understand what we are supposed to do with this. i understand that we are required to take in 2 values and compare them, but in the test file, null is passed into main, are we also expected to be managing the error handling for "wrong" arguments passed into the function? thanks

    i see, so on github it will be alright for it to be left as failed?

    as prof said in the other thread, try checking for null and return nothing

    Adding this if statement to check for null works for me.

    Also, would like to know if || args.length > 1 is redundant in this case? Thank anyone in advance.

    if (args == null || args.length > 1) { return; }

    its the length that is redundant, you cannot check length of null

    no problem, actually you can check it out by running each condition individually, i believe only args==null will work

    edit: i realised there are differences between local and remote tags, i have deleted remote tags via github browser, but local tags tripped me a bit. using this command in cmd in your repo folder works

    git tag -d tagname

    you can try if this works for you

    https://github.com/nus-cs2113-AY2021S2/forum/issues/47

    okay thanks prof!

    I have also observed in some sites that suggest using a break block to catch an exception

    do you have an example that we could follow from? currently im using a opt, and using my main method to "create" and exception instance, which is isnt very accurate but the closest that i can get

    sure prof, without giving too much of what i have, this is what i have for now (changed from opt to alt)

    i named the 2 conditions "successful execution" and "exception caught"

    the only inaccurate part is where the main function calls the constructor of exception, which should actually be called during method1 or method 2

    i would think that might be too complex for the diagram itself, because my structure is a bit more nested than this. when comparing readability and accuracy, should i prioritise readability and acknowledge the "bug"

    hi prof, may i personally message you about this? how can i reach you?

    Not sure about the grading thing, but you have to push the changes from sourcetree (after you commit) in order to see it on GitHub.

    On GitHub, go to the Actions tab. You should see your latest revision getting checked. If it is correct, you should see a green tick once it is done.

    The test case is when null is given instead of the 2 names. You have to check for null. (And do nothing if null)

    What is the link that you used?

    You should directly use != for comparison with null instead. Null is not an empty string, but the lack of one, so you can't check its length.

    Try without .git behind

    Hmm strange. You managed to do the other exercises?

    Could it be that your Github account is not set up properly on Sourcetree?

    You need to add a configuration by clicking on the "Add Configuration" button beside the run button. A window will pop up, then click on "+" on the top left and select application. Select Java 11 for the first input, and Duke class for the main class. Press ok and you should see the run button turn green.

    Yep it is the Corretto 11 option. (By the way, you need to select "Application" in the screenshot)

    Click on the icon on the right of the input box. Something should pop up and you should be able to select from there.

    For expected.txt, you only want to include the parts that the program outputs and exclude what the user is supposed to input.

    I also had the same issue. The way I solved it was to add an empty line before the code for the table.

    I am having some difficulties cloning from GitHub Classroom.

    When I try to clone using HTTPS on source tree, this error below came up. Please assist, thanks!

    I used this link:

    https://github.com/cs2113-AY2021S2/week-2-ex3-jovanhuang.git

    The page is valid when I click on the link using my github account though.

    The same happens for the other exercises.

    I followed @okkhoy tutorial on connecting SourceTree with Github closely though. Are there any ways to check if that is set up properly?

    I tried cloning using command line, but this error persists.

    try this:

    https://stackoverflow.com/a/62145210

    Sourcetree doesnt have all the required credentials for private repo

    This works! Thank you so much to Prof and all the others who helped! πŸ‘ πŸ˜ƒ

    It is the right place to add your account.

    This is what I did -

    Under authentication, try deleting the old account and add again. This time round, add using your github username and for the password, use generated token.

    It's because Windows has a different line ending (\r\n) compared to Linux (\n) which is used by the platform for running the test cases.

    Try replacing each System.out.println(thingToPrint) call with System.out.print(thingToPrint + '\n') instead as a temporary workaround... trying to find a more permanent one too myself.

    Thank you so much for this workaround solution. I was having the same problem where the test cases failed on my local computer but passed on github. Tried this solution and it works!

    I had the same issue. I changed the tick to "X" and the cross to " ". The "X" is the alphabet X in this case.

    Hello, I'm wondering how I can add in exceptions in my sequence diagram. This is my attempt in displaying it on my sequence diagram. Am I displaying the exception handling part correctly?

    There are 2 exception being thrown here, one under the alt, another at the end.

    \

    @okkhoy

    EDIT: (RESOLVED)

    I asked my TA and she suggested to change the break box to a return arrow.

    I am getting the error below when attempting to execute runtest.bat in IntelliJ. (I have already changed the directory of the folder to the one that my current project is located in.)

    Any suggestions to fix this?

    I am failing every testcase on IntelliJ when I try to run TestMain, but I get the correct output on my console when I run Main. The error message is shown below, how should I interpret it?

    πŸ’‘ You can use Markdown to format your text

    After I have edited the "Duke.java" code in IntelliJ, and committed in IntelliJ, my SourceTree sensed that it is the readme.md file that got changed?

    Hi, my IDE seems to be unable to run the Duke.java file. (There is no "run" button available.) Attached is the screenshot of how the IDE page.

    Also, Im very lost at how I should be downloading the files for the exercises and submitting my answers using sourcetree.

    Capture

    Have you configured the JDK?

    My IDE's homescreen looks different from the one shown in the video. Any advice on how to select the JDK?

    You need to add a configuration by clicking on the "Add Configuration" button beside the run button. A window will pop up, then click on "+" on the top left and select application. Select Java 11 for the first input, and Duke class for the main class. Press ok and you should see the run button turn green.

    There doesnt seem to be a Java11 option under configuration... (My SDK is selected as: "11 Amazon Corretto version 11.0.9", is this the correct version to be used?)

    Yep it is the Corretto 11 option. (By the way, you need to select "Application" in the screenshot)

    Thanks, found the java 11 option. However, the code is still unable to run. (Attached error message below). I have tried changing "Duke class" to "Duke" and "class Duke", similar error message is shown for both.

    I suspect this is not imported properly.

    Why is the folder named Duke.java on the left side of your second screen shot? Can you expand that and show what you have?

    The only item under the folder is "Duke.java". (No other visible files)

    Click on the icon on the right of the input box. Something should pop up and you should be able to select from there.

    Nothing shows up when I search for "Duke".

    I suspect this is not imported properly.

    Why is the folder named Duke.java on the left side of your second screen shot? Can you expand that and show what you have?

    Update: Seems that it is indeed a problem with my importing. I failed to import the entire folder. Sorry for the troubles.

    Thanks prof! (Didnt realise it was the same problem)

    You need to set the Java path. The command prompt is unable to fetch the Java compiler.

    The error message is : 'javac' is not recognized as an internal or external command ...

    Sorry I don't really understand. The main file is able to run with no problem. Are the following settings correct? I cant seem to find an option asking for Java path

    Hi Im trying to finish the "Tracker" task at the IP dashboard. I have followed the instruction on week 2 ip to tick the "Issue" check box to enabled the issue tracker of my fork. However in my ip progress dashboard, the Tracker task is still in red meaning not done yet.

    I can access the URL for issues so i guess my tracker has been enabled successfully, and i also waited for more than a day for the dashboard website to update. However its still mark as undone. Can somebody help why?

    For different increment level, do we need to ensure the feature for the previous level can work simultaneously with the new level feature? For example when I'm done with level 2 increment, which is to add task to a tasks list. And then for level-3 do I still need to keep this feature in the code, or I just need to rewrite the code to satisfy the level3 requirement only?

    Besides, there are 3 tasks(read book, return book and buy bread) given in the level 3 example for list output, so my question is that when we are designing our code, do we need to set the list and program output the same as given in the example?Β  That is only task 2 needs to be done.

    Thank you.

    Thank you for answering my first questions prof. My second question is regarding level3 β€œmark as done” increment. Do we need to design our own task list and can choose which ever task to be done and undone? Or do we have to run our code to give same output as the website level-3 example? @okkhoy

    Got it thank you very much:) @okkhoy

    hey prof my wk4 ex 1 passed the test locally but when i pushed it to Github classroom it always faild. Is it bcz the github classroom auto-grading is still not available? @okkhoy

    Sorry prof but my output is correct when i run Main, and i changed all println in Main to print( + "\n"), i still failed the test case. My error message is the same as shown in the screenshot above. 😦 @okkhoy

    Yea... i think there's no problem with the letter cases... @okkhoy

    omg thanks for the tips, after changing all the println to print + "\n" and line separator to "\n", it finally passed the test locally πŸ˜ƒ

    @okkhoy hi prof can you help to take a look at this? Thank you!

    I am trying to use the batch file which is for text-ui testing. I have put some inputs into input.txt and have written the expected output into EXPECTED.TXT.

    input.txt

    EXPECTED.TXT

    However, the program only takes the first line in the input.txt and ignored other lines. The compiler replied "Exception in thread "main" java.util.NoSuchElementException: No line found".

    Where have I made mistakes?

    If I have completed programming up to Level-3 (tag) but I found a typo in Level-1 (tag). Is it possible to edit Level-1 (tag)?

    My computer setup:

    • IntelliJ Idea version 2020.2.2

    • Java 11.0.9_12

    Exercise: Create Rectangle objects

    Expected output: "java.awt.Rectangle[x=0,y=0,width=5,height=10]"

    I failed to run the tests althought my actual output is the same as the expected output.

    The IDE keeps reporting that "contents have differences only in line separators".

    What am I doing wrongly? 😦

    What if I found a bug in my Level-1 but I have already working on Level-3? Is it OK to correct the bug in Level-3 only?

    I made big changes between Level-1 and Level-2. Will it be problematic?

    I find out that if I declare the Scanner object outside a static method (i.e. declare the static final Scanner object globally) can solve the problem.

    May I know where we can find the coding standards that we are to follow? I can't seem to find it through the slides or the website.

    Hi, when I don't input an argument the code exits cleanly when i run Main. However, when running TestMain I encounter a NullPointe Exception and I am unable to figure out why.

    Thank you!

    oh right, I referred to @Leeyp 's closed post for the answer. Thank you!

    I'm not sure if it's the right way to correct this issue, but I solved the problem by printing a '\n' character instead of a println.

    Hi everyone, i will provide the guide on how to bundle and handle the resource in the jar file.

    1. First, create a resource directory under the build path.

    2. You need to put your resource(eg txt file) into that resource directory.

    3)When you build your shadow jar the resource is supposed to be inside(to check just open it with winrar).

    1. To access this resource file, you will first need to create a InputStream and direct it to your resource directory.

    2. Next, create a InputStreamReader to store the content of your inputStream. (You cannot use FileReader because the resource will be inside your jar file and your jar file is like a ZIP file.)

    6)Next, once the data is stored into your InputStreamReader you will need a BufferedReader to decrypt and read the content like how you read a normal file using file reader.

    Note: You cannot write to the resource file inside the jar file, it is meant to be read only. If you want, you can copy the file inside the resource of the jar and save it outside the jar file.

    Hi, when we do a PR merge on GITHUB they will prompt to delete away the old branch . Is it okay if we delete that old branch ?

    Submission: Submit your product name, target user profile, the value proposition, and the public link to your collaborative project notes via TEAMMATES. You'll receive an email from TEAMMATES with the submission link. Only one member needs to submit on behalf of the team. All members can view/update the submission.

    Hi prof,

    When will the submission link be avail? Thank You

    If i don't push my file from source tree i can also edit it directly from the main file inside github right?

    How can we know our codes are 100% correct? Are there any checkers?

    @JoviYeung92 just to be sure I answer correctly, are you talking about the individual project (iP) or the exercises on GitHub classroom?

    For iP, each increment would add something new to the codebase you have developed so far. You need to test it on your machine to see if things are working. During the tutorials, you are required to show a quick demo to your tutors. So things get validated there.

    If you are talking about the exercises on GitHub classrooms, there are tests that run via GitHub actions (as mentioned by @8kdesign ) if the test passes, you are doing the right thing.

    I am preparing a video to demonstrate how to import the exercise to the IDE, do your development and testing; once your tests pass locally, you can push your code, which forms the submissions.

    okay prof, thanks for the information.

    Ensure the correct version of JDK is selected in File -> Project Structure...

    Adding this if statement to check for null works for me.

    Also, would like to know if '|| args.length > 1' is redundant in this case? Thank anyone in advance.

    'if (args == null || args.length > 1) {

            return;
    
        }'
    

    Adding this if statement to check for null works for me.

    Also, would like to know if || args.length > 1 is redundant in this case? Thank anyone in advance.

    if (args == null || args.length > 1) { return; }

    its the length that is redundant, you cannot check length of null

    Thank you

    May I know how to see if the result is passed on GitHub?

    you will see a green tick next to the commit like this:

    Thank you!

    Library

    Argparse4j Library (https://argparse4j.github.io/)

    Purpose

    This library is used for parsing user arguments from the command-line interface.

    License

    The library is released under the MIT License and it could be found at https://argparse4j.github.io/license.html.

    Library

    Gson Library (https://github.com/google/gson)

    Purpose

    This library is used for serializing and deserializing JSON data to and from Java objects when storing data in files.

    License

    The library is released under the Apache-2.0 License and it could be found at https://github.com/google/gson.

    I believe the NoSuchElementException error can be solved by checking if your scanner object has next line using hasNextLine() method before getting the nextLine() value or in the while loop.

    Thanks prof!

    Thanks prof!

    Can I clarify if this is intended?

    In Circle.Java and Rectangle.Java, line 1 was written as "public class Circle implements Shape{" and "public class Rectangle implements Shape{".

    Was the use of "implements" intended as I could not get my program to produce the expected output unless I change the implement to extends.

    I completed the Level-2 iP by creating a new Class and realized that if commit and push to GitHub, I will have 2 files in src/main/java/.

    My questions are:

    1. Can I check whether we are allowed to create a new class (.java file)?

    2. If we are allowed to, would having such additional files affects the grading? (be it manual or auto-grading in the future)

    (Edit) 3. Do we assign the tag (Level-2) to Duke.java or Task.java?

    Thank you. πŸ˜ƒ

    iP Level 2
    1. You are allowed to create new classes. Just please don't change the folder structure inside
    1. Additional java files are necessary for many of the increments, so it is OK to create them appropriately. It won't adversely affect the grading.
    1. Tag the commit, not the file. One way to go about it to tag the latest commit which has the feature completed, irrespective of what files are updated in that commit.

    Hi Professor, understood with much thanks. πŸ˜ƒ

    I believe we have to use "implements" if we are accessing an interface method and use "extends" to access a class. So since Circle is a class, extends should be used here. Not sure tho.

    Yes, I have googled it as well. You're absolutely correct on using "implements" for interfaces.

    Similarly, I believe that it should be "extends" since it's referring to a superclass but I'm lost too haha.

    This is an oversight on my part. I did not remove the implements from the template.

    For this one,

    1. If you wish to continue with implements, please make Shape an interface (Interfaces are covered in Week 5 material).
    1. If not, you can change implements to extends and make Shape a class.

    in both cases, the polymorphic behavior of the area method is apparent.

    Hi Professor, Understood. Thank you for the clarification! πŸ‘πŸΌ

    Am wondering if anyone has faced the same issue as I can't seem to understand where the issue lies.

    • Prior to implementing Level-5, running the runtest was simple as no exceptions were raised

    • Adding exception handlers caused the following to happen (Figure 1) during the text-ui-test

    (Figure 1. Using text-ui test showed this)

    (Figure. 2 Doing manual testing will show this)

    This (Figure 2) was printed in System.err.println if anyone is wondering. Have tried changing it back to System.out.println but the issue still remains that the exception was caught and the program was terminated ONLY in the text-ui and not manual.

    Anyone had faced this error when cloning?

    I have finished from ex 1 to 8 without issues then left for awhile, upon returning, I can't seem to clone the file as this error was shown.

    Can't seem to find any fixes on the internet either.

    Update: Have tried the solutions from the other threads but none seems to work for me

    Update 2: Apparently the cause was the changing of the credentials manager. Have revert it back to nothing and it works!

    I have traced all my data, methods and objects but then I realized that somehow the text-ui test on intellij is having some issues that I can't find answers on the internet.

    These are some new issues that I found that shows more issues with the exception and text-ui testing

    It somehow throws an exception when I do manual testing for having insufficient parameters, but it allows it when using text-ui testing? Both of which i did the exact same inputs of a (space) after the todo

    Thanks for the help Prof @okkhoy, I realized it was a logical error on my end when handling the exceptions itself. Apologies for the confusion.

    Did the same as above and it worked. Thanks!

    Must we include photos for AboutMe page or is it optional?

    Are we graded on what we include in our text-ui-test component (such as our new features) or is it just for our own testing?

    Thank you!

    I've implemented TaskListTest using JUnit but it was not reflected as done on the tP individual dashboard. The commit was counted in hence I believe that the dashboard was updated.

    What should I do so that it will be updated as done?

    Hi, whenever I use source tree to clone/push anything the credential helper selector keep popping up and I'm not sure what to select. Just clicking cancel works but it will still pop up the next time I use source tree. Does anyone know which option I should select or is there a way to get rid of it? Thank you!

    It seems like that was the issue, thank you!

    Noted, thank you prof!

    To roughly put, our team is thinking of implementing a program to allow the user to clear emails more efficiently by streamlining the process. However, we thought of some questions on our implementation and would love to have some clarifications. The questions are listed below:

    1. Can we implement a fake email inbox, sent mailbox etc? So all the data will be pre-loaded to simulate a real email account. This is due to a concern of Internet issue. Otherwise,

    2. Can we send emails to actual email accounts? (Requires the use to internet, to check that emails are received, and using external packages)

    3. If checking of gmail online is not allowed, what is the suggested method we can implement the send email function

    Thank you!

    I think the title is self explanatory. Does anyone know what am I doing wrong and if there is a way to solve this issue?

    Thank you in advanced!

    I am having trouble linking sourcetree to Github. The details of error I am facing is exactly like what was described in the link below:

    https://community.atlassian.com/t5/Sourcetree-questions/Can-t-link-SourceTree-to-GitHub-account/qaq-p/1570763

    Any help is deeply appreciated, thank you so much!

    Thanks all for the help. In the end, I think i managed to login by setting the following:

    Once i type in my username and click on "Refresh OAuth Token", it will lead me to a webpage and i just have to allow access.

    Wondering if any groups are facing this issue where by:

    text-ui-test is not building successfully due to the version of gradle stated in gradle-wrapper?

    I am referring to the distributionUrl in gradle > wrapper > gradle-wrapper.properties.

    6.2-bin is not working for me but once I changed to 6.3 it is fine.

    Is there a way to 'create' another object in PlantUML sequence diagram?

    For example: Parser should create CloseCommand object. But I cant seem to join the activation block for CloseCommand to the top.

    Screenshot 2021-04-02 at 11 11 29 AM

    As depicted, this week we are supposed to be accepting an invitation. However, I have yet to receive any of it + the link provided does not work. Has anyone managed to accept the invite?

    Screenshot 2021-01-31 at 10 12 49 PM

    Just received an invite

    The link for Week 2 Ex 4 states that "Invitations for this assignment have been disabled", upon clicking "Accept this assignment".

    Would like to check if there's an "Ex 4" task to be completed for Week 2?

    It now works, thanks.

    @Leeyp it was not done intentionally.

    Hopefully, no such encounters in the future 🀞

    PE is a different matter entirely. We will talk about it when it is the right time!

    Hi, would like to clarify on this task too. Is it expected to observe a "Autograding fail" result (Points 0/1) in the Git autograding status upon pushing?

    Expansion of the error message states testMain failed.

    But the code runs fine on local terminal upon manual insertion of the names.

    The test case is when null is given instead of the 2 names. You have to check for null. (And do nothing if null)

    I did some googling, and apparently passing a "null" string into main is highly unusual. However, I still attempted to insert a checker for null by checking for the length of the string input, and exiting Main in the event of a null input, but still failing testMain. Any ideas where I'm going wrong?

    Hello,

    When I push my code to Github, the tabsize is automatically size 8. So I manually edit and change the tab size on github to size 4 and commit again but it is still size 8.

    Please advise. Thanks

    Hello Prof, My tab space is 4 on intellJ and my indentation is correct on intellJ but when i push to github it becomes 8.

    Hello Prof,

    I am using the same directory to edit/commit and push, also only using IntelliJ and I did not change any settings and did not install any plugins.

    Hello Prof, I have fixed it by just reformatting the entire code again.

    Hello, we were facing some checkstyle failures with our initial tP PRs so we wanted to disable the Java CI Action for now since these are just initial parts of the code. I want to check, does it disable anything else that's required if we do that, because I see that there might be other tasks in gradle.yml.

    Nah, for each question repository you have to:

    1. Clone the repository

    2. Make changes to the code such that the tests in the repository can be passed

    3. Commit your changes and push it back to GitHub.

    Then, the Autograding workflow will run the test cases, and if your changes passed the test cases you'll get the tick.

    It's because Windows has a different line ending (\r\n) compared to Linux (\n) which is used by the platform for running the test cases.

    Try replacing each System.out.println(thingToPrint) call with System.out.print(thingToPrint + '\n') instead as a temporary workaround... trying to find a more permanent one too myself.

    How can I fix the arrow?

    Specification on the link:

    Fridge -down-> "*" Food : maintain

    #diagram in PR

    I could not find my identifier when joining github classroom so I skipped that part and did wk2-ex1 directly.

    May I ask if anyone has chosen the identifier #0230650_ ? Maybe we have a similar student number.

    Prof helped to manually match identifier to account.

    https://se-education.org/guides/conventions/java/basic.html

    It is under other links

    Also, Im very lost at how I should be downloading the files for the exercises and submitting

    You should refer to the e-lecture videos like "W2-Admin-SubmittingExercisesOnGHClassroom" on luminous.

    "If you give it two different string objects that contain the same letters, it is supposed to yield true because they are two distinct objects even if they contain the same text. "(From W3.5 comparing strings)

    Shouldn't the "true" in the sentence be "false"?

    Hi, currently I'm having a problem with rendering the markdown table when doing user guide. Everything looks good in Intellij preview. However when I push it to github, the table is causing problems as shown in the picture.

    This is how it should be done right?

    action | format

    --- | ---

    command1 | format1

    command2 | format2

    command3 | format 3

    Here's the link to the document if need:

    https://iamakilahamed.github.io/ip/

    It works now when I was fixing some spelling mistakes from other parts of the website not related to the table. However, I don't think that spelling mistakes could be the problem behind the table not being able to render.

    Yes, you are right. That was the problem. Thank you.

    I followed the link above and created a personal token. Can I ask where to do step 9: click on sourceTree preference & Click add Account. I'm not sure if I am on the right track because I failed to add an account as the screenshot on StackOverflow shown, the comment is I already have a Github account. Maybe I found the wrong place to add the account?

    sourcetree

    @jovanhuang Thanks! It successfully works now!

    @okkhoy Sure. Sorry about that, I will pay attention next time!

    Setup:

    IntelliJ 2020.3.1 (Community Version)

    Windows 10

    Java 11.0.9_12 (corretto-11, the one recommended by the module)

    Hi, I'm failing most of my test cases when testing locally on the IDE with these errors.

    Its passing on Github however (green tick), anyone know the fix to this issue?

    Also, are my exercises considered to have passed (seeing that they passed on Github but failed when tested locally)?

    My IDE showed the same test case failed as yours but it passed on Github.

    Thanks @tehtea and @okkhoy ! It seems to fix the issue for now πŸ˜ƒ

    Library

    Apache Commons Lang Library

    commons-lang3 (MVNrepository)

    Purpose

    This library is used for parsing user input strings into a command and/or its argument(s).

    License

    commons-lang3 (v3.4) is released under Apache License 2.0.

    Stated under README.md > License.

    Thanks Prof, will let you know the updated version we will change to.

    My team and I decided to use version 3.11.

    Similar question here. I did not choose my identifier and skipped it to attempt the exercises directly.

    It seems like I cannot go back to choose my identifier now, could anyone advise me on how to do so or it does not matter since the submission of the work is associated to my GitHub account?

    @okkhoy Hi Prof, I just sent you an email with my student number and the associated Github username. Sorry for the inconvenience caused.

    I am able to visit https://github.com/cswbibibi/ip/issues as well. Perhaps you could contact the teaching team since the problem is not rectified after the daily update?

    I am using sourcetree for macOs Catalina 10.15.6

    when I try to push to my forked repository, I get an error message like this:

    Pushing to https://github.com/geezzzyyy/lender.git

    remote: Permission to geezzzyyy/lender.git denied to geezzzyyy.

    fatal: unable to access 'https://github.com/geezzzyyy/lender.git/': The requested URL returned error: 403

    how should I solve this issue? thanks

    I first realized this problem during last Friday's lecture, till now, still unable to push.

    Could be a temporary issue, please try again?

    Hi Prof, can i check if there are any preferences between the usage of strip() and trim() function? Ex 7 does not permit the usage of strip() from the result of my submissions.

    Ive read

    https://www.journaldev.com/33291/java-string-trim-method-examples#:~:text=This method uses Unicode code,it uses the Unicode standard.

    and it suggests to use strip() instead of trim().

    Would like to ask for any guidance on this issue. Thank you!

    Thanks Prof! Appreciate the honesty πŸ˜ƒ

    Hi,

    I'd like to ask if part 3 of the week 6 lecture is intentionally left out as I don't seem to find it.

    Thanks in advance!

    Alright, thanks prof!

    try this:

    https://stackoverflow.com/a/62145210

    Sourcetree doesnt have all the required credentials for private repo

    How do we get a tick for the GitHub Classroom Autograding Workflow component? Do we just attend the GitHub Classroom sessions during our respective tutorial sessions?

    It keep saying: The job was not started because the spending limit for Actions and Packages has been exceeded.

    I am not sure if it is the problem of my code or a setting issue.

    Library

    Apache Commons Validator Library

    commons-validator 1.7 MVNrepo

    Purpose

    This library is used to validate a given URL input

    License

    Apache License, Version 2.0

    I believe we have to use "implements" if we are accessing an interface method and use "extends" to access a class. So since Circle is a class, extends should be used here. Not sure tho.

    just change the line separator method to "\n" and it will be fine

    Ctrl + Alt + Shift + S to open up the JDK selection screen