Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Glossaire.sh error on beta site #669

Closed
pascalchevrel opened this issue Mar 4, 2016 · 3 comments
Closed

Glossaire.sh error on beta site #669

pascalchevrel opened this issue Mar 4, 2016 · 3 comments
Assignees

Comments

@pascalchevrel
Copy link
Member

@pascalchevrel pascalchevrel commented Mar 4, 2016

running glossaire on the beta site yields errors:
Silme couldn't extract data for /var/cache/transvision/hg//RELEASE_EN-US/COMMUN/browser
/var/cache/transvision/hg//RELEASE_EN-US/COMMUN/browser/extensions/pocket/locales/en-US/en-US: [Errno 2] No such file or directory: '/var/cache/transvision/hg//RELEASE_EN-US/COMMUN/browser/extensions/pocket/locales/en-US/en-US'
English strings have been updated.
./app/scripts/glossaire.sh: ligne 229 : [: false : nombre entier attendu comme expression
./app/scripts/glossaire.sh: ligne 229 : [: false : nombre entier attendu comme expression

I don't know why, I'll investigate on my local instance.

@pascalchevrel
Copy link
Member Author

@pascalchevrel pascalchevrel commented Mar 4, 2016

ok, I can reproduce locally when I set checkrepo=false in the script

@pascalchevrel
Copy link
Member Author

@pascalchevrel pascalchevrel commented Mar 4, 2016

                if [ "$checkrepo" = true ]
                then
                    updateLocale ${!repo_l10n} $locale $repo_name/$locale
                    updated_locale=$?
                fi
              ...
                if [ "$forceTMX" = true -o "$updated_english" = true -o "$updated_locale" -eq 1 ]
                then
                    buildCache $locale

updated_locale is only defined in the if clause if checkRepo=true, that's why the script fails when checkrepo=false.

@flodolo
Copy link
Contributor

@flodolo flodolo commented Mar 4, 2016

It's actually initialized on line 212, right before this piece of code. The problem is that it is initialized to false, while it should be initialized to 0 (updateLocale returns either 0 or 1, since return only work with 0-255 like exit).

@flodolo flodolo self-assigned this Mar 5, 2016
pascalchevrel added a commit that referenced this issue Mar 6, 2016
glossaire.sh: initialize update_locales to 0, not false (fix issue #669)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.