#bookbrainz

/

      • nikhil_rana joined the channel
      • 2023-02-25 05637, 2023

      • nikhil_rana has quit
      • 2023-02-25 05641, 2023

      • Siddhart1o1 joined the channel
      • 2023-02-25 05657, 2023

      • Siddhart1o1
        monkey Hi. I fixed the author and Disambiguation in this issue https://tickets.metabrainz.org/browse/BB-703. I also added loadGender middelware in series get request ```router.get('/:bbid', middleware.loadEntityRelationships, middleware.loadSeriesItems,middleware.loadGenders, (req, res) => {
      • 2023-02-25 05657, 2023

      • Siddhart1o1
         _setSeriesTitle(res);
      • 2023-02-25 05658, 2023

      • BrainzBot
        BB-703: Series of authors are not displayed correctly
      • 2023-02-25 05659, 2023

      • Siddhart1o1
         entityRoutes.displayEntity(req, res);
      • 2023-02-25 05659, 2023

      • Siddhart1o1
        });``` . can you help me with next steps?
      • 2023-02-25 05600, 2023

      • pbryan
        Hi Siddhart1o1, monkey's probably asleep right now.
      • 2023-02-25 05614, 2023

      • pbryan
        Do you have a PR that he can review?
      • 2023-02-25 05621, 2023

      • Siddhart1o1
        yes
      • 2023-02-25 05627, 2023

      • Siddhart1o1
      • 2023-02-25 05620, 2023

      • Siddhart1o1
        monkey told me to make changes. But I have some confusion in Genders Field
      • 2023-02-25 05633, 2023

      • pbryan
        OK, I'm not familiar with the code base, so I'm afraid I won't be of much help.
      • 2023-02-25 05604, 2023

      • pbryan
        I do see a bunch of ESlint errors though that are probably worth addressing in the meantime.
      • 2023-02-25 05620, 2023

      • pbryan
        s/errors/warnings/
      • 2023-02-25 05642, 2023

      • pbryan
        Actually both errors and warnings.
      • 2023-02-25 05637, 2023

      • Siddhart1o1
        yes these will be fixed. Do you know any docs from which i can get understanding of CodeBase?
      • 2023-02-25 05604, 2023

      • Siddhart1o1 has quit
      • 2023-02-25 05611, 2023

      • Siddhart1o1 joined the channel
      • 2023-02-25 05644, 2023

      • monkey
        Siddhart1o1: I'll review the PR on Monday :)
      • 2023-02-25 05645, 2023

      • monkey
        In the meantime, if you were looking for docs, we have: https://bookbrainz-dev-docs.readthedocs.io/en/lat… with some description of the schema and other moving parts of the codebase
      • 2023-02-25 05628, 2023

      • Siddhart1o1 has quit
      • 2023-02-25 05658, 2023

      • Siddhart1o1 joined the channel
      • 2023-02-25 05607, 2023

      • Siddhart1o1
        monkey Thanks.  Actually I Have not made new PR I wanted to some help in gender Field rest I have done. I added ```loadGenders``` middleware as you said, but I am not able to understand further.
      • 2023-02-25 05645, 2023

      • Siddhart1o1
        I will wait for your further instruction. Meanwhile I will explore codebase, different projects and bugs. Thanks.
      • 2023-02-25 05611, 2023

      • Siddhart1o1
        Or you can suggest some resources for the framework we are using, or any library. which will help me understand the codebase
      • 2023-02-25 05629, 2023

      • kellnerd joined the channel
      • 2023-02-25 05635, 2023

      • Siddhart1o1 has quit
      • 2023-02-25 05647, 2023

      • Siddhart1o1 joined the channel
      • 2023-02-25 05647, 2023

      • kellnerd has quit
      • 2023-02-25 05649, 2023

      • Himanshu joined the channel
      • 2023-02-25 05633, 2023

      • Siddhart1o1 has quit
      • 2023-02-25 05627, 2023

      • Himanshu has quit
      • 2023-02-25 05618, 2023

      • Deogee joined the channel
      • 2023-02-25 05626, 2023

      • Deogee
        Hello guys. I am interested in contributing to bookbrainz. I ran into an issue while setting up the project. I went through the chat backlog and couldnt find a solution.
      • 2023-02-25 05627, 2023

      • Deogee
        The issue is that i'm getting the error "/usr/bin/env: ‘bash\r’: No such file or directory" when i run  "/usr/bin/env: ‘bash\r’: No such file or directory"
      • 2023-02-25 05627, 2023

      • Deogee
        i'm using wsl on windows
      • 2023-02-25 05611, 2023

      • Deogee
        sorry i meant when i run ./scripts/database-init-docker.sh
      • 2023-02-25 05648, 2023

      • Deogee
        If anyone could save me some time i'll appreiate
      • 2023-02-25 05609, 2023

      • pbryan
        Hi Deogee. Welcome!
      • 2023-02-25 05635, 2023

      • pbryan
        What OS are you using?
      • 2023-02-25 05632, 2023

      • Deogee
        i'm using wsl on windows
      • 2023-02-25 05646, 2023

      • pbryan
        Heh, yeah, just saw you said that. Sorry. Slowpoke here.
      • 2023-02-25 05657, 2023

      • pbryan
        OK, so are you in a bash shell when running the script?
      • 2023-02-25 05608, 2023

      • Deogee
        haha no worries
      • 2023-02-25 05606, 2023

      • Deogee
        yes i am
      • 2023-02-25 05657, 2023

      • pbryan
        OK, standby...
      • 2023-02-25 05628, 2023

      • Deogee
        Alright
      • 2023-02-25 05648, 2023

      • pbryan
        So, you're trying to run the `./scripts/database-init-docker.sh` script?
      • 2023-02-25 05612, 2023

      • Deogee
         yes , i also tried navigating to th bookbrainz-site folder and running yarn install
      • 2023-02-25 05612, 2023

      • Deogee
        But i get the same error
      • 2023-02-25 05641, 2023

      • pbryan
        How are you trying to run the script?
      • 2023-02-25 05621, 2023

      • Deogee
        i went inside the file and manually type the script
      • 2023-02-25 05621, 2023

      • Deogee
        The first one is docker-compose up
      • 2023-02-25 05622, 2023

      • Deogee
        Thats where i get the error
      • 2023-02-25 05658, 2023

      • Deogee
        after running docker-compose up
      • 2023-02-25 05600, 2023

      • pbryan
        Oh, definitely do not try to type each line of the script, if that's what you mean.
      • 2023-02-25 05612, 2023

      • Deogee
        sorry i did'nt clarify that
      • 2023-02-25 05614, 2023

      • Rohan11 joined the channel
      • 2023-02-25 05652, 2023

      • pbryan
        You should just let bash execute the script by typing ./scripts/database-init-docker.sh.
      • 2023-02-25 05615, 2023

      • Rohan11 has quit
      • 2023-02-25 05620, 2023

      • Deogee
         i could'nt run this "`./scripts/database-init-docker.sh`" on wsl
      • 2023-02-25 05634, 2023

      • pbryan
        What happens when you try that?
      • 2023-02-25 05645, 2023

      • pbryan
        Oh, and exclude the `backticks`.
      • 2023-02-25 05625, 2023

      • Deogee
        i still get "/usr/bin/env: ‘bash\r’: No such file or directory"
      • 2023-02-25 05638, 2023

      • RohanSasne joined the channel
      • 2023-02-25 05653, 2023

      • pbryan
        Hmm.
      • 2023-02-25 05629, 2023

      • pbryan
        What happens if you type /usr/bin/env in the bash shell?
      • 2023-02-25 05629, 2023

      • RohanSasne
        Hey Rohan this side, I would love to contribute to BookBrainz this summer :) currently going through the documentation for the project and will come with a draft proposal really soon :))
      • 2023-02-25 05642, 2023

      • pbryan
        Hi RohanSasne. Welcome!
      • 2023-02-25 05615, 2023

      • Deogee
        i'm trying to send a file of what i get
      • 2023-02-25 05620, 2023

      • Deogee
        but its not working
      • 2023-02-25 05630, 2023

      • Deogee
        its basically a bunch of stuffs
      • 2023-02-25 05634, 2023

      • pbryan
        You can't send files over IRC. You can paste as a gist in GitHub?
      • 2023-02-25 05651, 2023

      • Deogee
        SHELL=/bin/bash
      • 2023-02-25 05651, 2023

      • Deogee
        NVM_INC=/home/deogee/.nvm/versions/node/v18.14.2/include/node
      • 2023-02-25 05651, 2023

      • Deogee
        WSL2_GUI_APPS_ENABLED=1
      • 2023-02-25 05652, 2023

      • Deogee
        WSL_DISTRO_NAME=Ubuntu
      • 2023-02-25 05653, 2023

      • Deogee
        WT_SESSION=ea072174-e9d9-4be9-9dff-303c0c1cb9cd
      • 2023-02-25 05653, 2023

      • Deogee
        NAME=DESKTOP-GLQ2AJ4
      • 2023-02-25 05653, 2023

      • Deogee
        PWD=/mnt/c/Users/ahmad/Desktop/Projects/Web/github/bookbrainz-site
      • 2023-02-25 05654, 2023

      • Deogee
        LOGNAME=deogee
      • 2023-02-25 05654, 2023

      • Deogee
        HOME=/home/deogee
      • 2023-02-25 05655, 2023

      • Deogee
        LANG=C.UTF-8
      • 2023-02-25 05602, 2023

      • Deogee
        These are the first few lines
      • 2023-02-25 05616, 2023

      • pbryan
        OK, that's good. That tells us that `env` is there.
      • 2023-02-25 05631, 2023

      • pbryan
        And if you type `bash` in the command line? (It should seem like it's does nothing with no error.)
      • 2023-02-25 05622, 2023

      • Deogee
        No error.. But nothings logged also
      • 2023-02-25 05632, 2023

      • pbryan
        Right. OK.
      • 2023-02-25 05603, 2023

      • pbryan
        Hmm.
      • 2023-02-25 05625, 2023

      • pbryan
        So, let's try typing manually: /usr/bin/env bash
      • 2023-02-25 05644, 2023

      • pbryan
        Seems to do nothing, no error?
      • 2023-02-25 05611, 2023

      • Deogee
        Exactly. No error, nothing logged
      • 2023-02-25 05618, 2023

      • pbryan
        OK, did you modify this script in some way?
      • 2023-02-25 05626, 2023

      • pbryan
        I think it's the \r at the end that's the problem.
      • 2023-02-25 05612, 2023

      • pbryan
        I suspect you may have edited the file with an editor in Windows, and it modified the script to add CR to the end of lines.
      • 2023-02-25 05656, 2023

      • Deogee
        I don't think i did. But just incase i'll clone the repo and try again
      • 2023-02-25 05600, 2023

      • pbryan
        OK.
      • 2023-02-25 05635, 2023

      • pbryan
        Ah.
      • 2023-02-25 05639, 2023

      • pbryan
        Here's another clue.
      • 2023-02-25 05600, 2023

      • pbryan
        It seems that git will add CRs to lines.
      • 2023-02-25 05605, 2023

      • pbryan
        In Windows.
      • 2023-02-25 05624, 2023

      • pbryan
      • 2023-02-25 05651, 2023

      • RohanSasne has quit
      • 2023-02-25 05604, 2023

      • RohanSasne joined the channel
      • 2023-02-25 05654, 2023

      • Deogee
        i'm checking it out
      • 2023-02-25 05656, 2023

      • Deogee
        By the way i ran other scripts in the same folder and i get the same error
      • 2023-02-25 05623, 2023

      • Deogee
        cloning...
      • 2023-02-25 05644, 2023

      • pbryan
        Seems that you'll need to set core.autocrlf to false and clone.
      • 2023-02-25 05618, 2023

      • pbryan
        This will be worth noting in the documentation.
      • 2023-02-25 05652, 2023

      • Deogee
        let me try so
      • 2023-02-25 05629, 2023

      • RohanSasne has quit
      • 2023-02-25 05640, 2023

      • Deogee
        It'll definatly  help in the documentation
      • 2023-02-25 05607, 2023

      • Deogee
        ''''''''''''''''''''''
      • 2023-02-25 05633, 2023

      • Deogee
        oops that was a mistak
      • 2023-02-25 05634, 2023

      • pbryan
        OK, for checking out the files only, core.autocrlf false is safe, but for working on the project, the safest is core.autocrlf input.
      • 2023-02-25 05657, 2023

      • pbryan
        This way if any files are committed by you, any CRs will be removed.
      • 2023-02-25 05633, 2023

      • Deogee
         i did core.autocrlf false and now i'm getting  '-bash: /scripts: No such file or directory'
      • 2023-02-25 05602, 2023

      • Deogee
        even though i can clealy see the file
      • 2023-02-25 05621, 2023

      • pbryan
        Did you put dot in front of scripts? ./scripts/...
      • 2023-02-25 05603, 2023

      • Deogee
        i did
      • 2023-02-25 05630, 2023

      • Deogee
        and i see the folder when i type ls
      • 2023-02-25 05612, 2023

      • pbryan
        So exact command you're entering is?
      • 2023-02-25 05620, 2023

      • Deogee
        ./scripts/database-init-docker.sh
      • 2023-02-25 05655, 2023

      • pbryan
        Hmm.
      • 2023-02-25 05630, 2023

      • pbryan
        How did you set core.autocrlf false?
      • 2023-02-25 05656, 2023

      • Deogee
        i typed "git config --global core.safecrlf false" on the terminal before cloning
      • 2023-02-25 05623, 2023

      • pbryan
        OK.
      • 2023-02-25 05618, 2023

      • Deogee
        i'll delete and try cloning again
      • 2023-02-25 05622, 2023

      • pbryan
        Just for fun, if it happens again, run "bash" inside of the command line before running the "./scripts/database-init-docker.sh" command.
      • 2023-02-25 05624, 2023

      • Deogee
        Alright
      • 2023-02-25 05602, 2023

      • Deogee
        Same error(/usr/bin/env: ‘bash\r’: No such file or directory) even after typing "bash" before running the command
      • 2023-02-25 05613, 2023

      • pbryan
        That error tells me that the clone is still somehow pulling CRs.
      • 2023-02-25 05622, 2023

      • pbryan
        (Inserting CRs.)
      • 2023-02-25 05640, 2023

      • pbryan
        Oh, you set core.safecrlf?
      • 2023-02-25 05613, 2023

      • pbryan
        core.safecrlf != core.autocrlf
      • 2023-02-25 05634, 2023

      • Deogee
        i did these
      • 2023-02-25 05635, 2023

      • Deogee
        git config --global core.autocrlf true
      • 2023-02-25 05635, 2023

      • Deogee
        git config --global core.safecrlf false
      • 2023-02-25 05653, 2023

      • Deogee
      • 2023-02-25 05611, 2023

      • Deogee
        i ran the two commands before cloning
      • 2023-02-25 05622, 2023

      • pbryan
        core.autocrlf true is the opposite of what we want here.
      • 2023-02-25 05644, 2023

      • pbryan
        I would suggest setting it to input.
      • 2023-02-25 05615, 2023

      • Deogee
        what about core.safecrif
      • 2023-02-25 05605, 2023

      • pbryan
        Geez, the git docs aren't very clear. Reading...
      • 2023-02-25 05658, 2023

      • Deogee
        haha i'm going through them too
      • 2023-02-25 05626, 2023

      • pbryan
        OK.
      • 2023-02-25 05631, 2023

      • pbryan
        So...
      • 2023-02-25 05606, 2023

      • pbryan
        Things are recommending that for Windows, you should checkout with CRLF, but we don't want that here because we're going to run these in docker, which is a Linux environment, which rejects the CRs.