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

Provide a way of getting a map supporting lookup from packageName to Uri #24022

Closed
nex3 opened this issue Aug 7, 2015 · 11 comments
Closed

Provide a way of getting a map supporting lookup from packageName to Uri #24022

nex3 opened this issue Aug 7, 2015 · 11 comments
Assignees
Labels
area-core-library SDK core library issues (core, async, ...); use area-vm or area-web for platform specific libraries. library-io P1 A high priority bug; for example, a single project is unusable or has many test failures type-enhancement A request for a change that isn't a bug

Comments

@nex3
Copy link
Member

nex3 commented Aug 7, 2015

By analogy with Platform.packageRoot. This is useful for ensuring that spawned tools like the analyzer or the VM run in the same package context as the current process.

/cc @davidmorgan

@nex3 nex3 added Type-Enhancement area-core-library SDK core library issues (core, async, ...); use area-vm or area-web for platform specific libraries. library-io labels Aug 7, 2015
@sethladd
Copy link
Contributor

sethladd commented Aug 7, 2015

For completeness, what would the getter return?

@nex3
Copy link
Member Author

nex3 commented Aug 7, 2015

Personally, I'd prefer it return the URI of the package spec file if one was used for the current isolate (or maybe for the VM as a whole?). That doesn't exactly match the behavior of Platform.packageRoot, though, which returns exactly the value of the --package-root flag provided to the VM, if any. In general that tends to be less than optimally helpful, though, since there may be a package root/spec in effect even if it's not explicitly passed.

@whesse whesse added the P1 A high priority bug; for example, a single project is unusable or has many test failures label Aug 7, 2015
@whesse whesse added this to the 1.12 milestone Aug 7, 2015
@mit-mit mit-mit modified the milestones: 1.13, 1.12 Aug 17, 2015
@mit-mit
Copy link
Member

mit-mit commented Aug 17, 2015

Punting to 1.13 based on prioritization in #23372

@sethladd
Copy link
Contributor

sethladd commented Sep 3, 2015

cc @iposva-google who I think is looking into this.

@mit-mit mit-mit changed the title Provide a Platform.packageSpec getter Provide a way of getting a map supporting lookup from packageName to Uri Sep 29, 2015
@mit-mit
Copy link
Member

mit-mit commented Oct 5, 2015

@mit-mit mit-mit closed this as completed Oct 5, 2015
@sethladd
Copy link
Contributor

sethladd commented Oct 5, 2015

👍

@nex3
Copy link
Member Author

nex3 commented Oct 29, 2015

This has been rolled back, so I'm re-opening.

Also, the new name for this property is Isolate.packageConfig.

@nex3 nex3 reopened this Oct 29, 2015
@kevmoo kevmoo modified the milestones: 1.14, 1.13 Oct 30, 2015
@kevmoo kevmoo removed this from the 1.14 milestone Jan 13, 2016
@mit-mit
Copy link
Member

mit-mit commented Jan 14, 2016

I believe this has landed

@mit-mit mit-mit closed this as completed Jan 14, 2016
@nex3
Copy link
Member Author

nex3 commented Jan 14, 2016

This hasn't landed yet; the new APIs don't include a map, just a function to do the lookup, which isn't what we asked for. @mit-mit can you reopen?

@iposva-google
Copy link
Contributor

"Personally, I'd prefer it return the URI of the package spec file if one was used for the current isolate" is exactly what you asked for and getting with Isolate.packageConfig. Keeping closed.

@nex3
Copy link
Member Author

nex3 commented Jan 15, 2016

I'm sorry, you're right. I'll file a separate issue for the map.

@kevmoo kevmoo added type-enhancement A request for a change that isn't a bug and removed type-enhancement labels Mar 1, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-core-library SDK core library issues (core, async, ...); use area-vm or area-web for platform specific libraries. library-io P1 A high priority bug; for example, a single project is unusable or has many test failures type-enhancement A request for a change that isn't a bug
Projects
None yet
Development

No branches or pull requests

6 participants