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

Context block in messages.xlf leaks full path (4.1.3) #16989

Closed
cburgmer opened this issue May 24, 2017 · 2 comments
Closed

Context block in messages.xlf leaks full path (4.1.3) #16989

cburgmer opened this issue May 24, 2017 · 2 comments

Comments

@cburgmer
Copy link

I'm submitting a ... (check one with "x")

[x] bug report => search github for a similar issue or PR before submitting
[ ] feature request
[ ] support request => Please do not submit support request here, instead see https://github.com/angular/angular/blob/master/CONTRIBUTING.md#question

Current behavior
When running ng-xi18n -p src/tsconfig.app.json --i18nFormat xlf and one of the node_modules includes translatable strings, the full path of that context is written to the messages.xlf file:

       <trans-unit id="cedd5f9cee5d6a1681605d996cf45ab5398fabcd” datatype="html">
         <source>Source Language</source>
         <target/>
        <context-group purpose="location">
          <context context-type="sourcefile”>/Users/my_user/my_project/node_modules/my_dependency/index.ts</context>
          <context context-type="linenumber">42</context>
        </context-group>
       </trans-unit>

Expected behavior
I'd expect something along the lines of

       <trans-unit id="cedd5f9cee5d6a1681605d996cf45ab5398fabcd” datatype="html">
         <source>Source Language</source>
         <target/>
        <context-group purpose="location">
          <context context-type="sourcefile”>node_modules/my_dependency/index.ts</context>
          <context context-type="linenumber">42</context>
        </context-group>
       </trans-unit>

What is the motivation / use case for changing the behavior?

  • On a team other committers will generate different output, conflicting when checking in.
  • I don't want to leak my internal file structure.

Please tell us about your environment:

$ npm --version
4.2.0
$ cat package.json | grep '"@angular/compiler-cli"'
    "@angular/compiler-cli": "^4.1.3",
@ocombe
Copy link
Contributor

ocombe commented May 25, 2017

Yes this is something that we will fix. It's a duplicate of #16639, so I'm closing this one.

@ocombe ocombe closed this as completed May 25, 2017
@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Sep 11, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants