Skip to content

feat: skip namespacing when already prefixed - #6258

Merged
jedevc merged 1 commit into
dagger:mainfrom
jedevc:namespacing-prefixes
Dec 13, 2023
Merged

jedevc merged 1 commit into
dagger:mainfrom
jedevc:namespacing-prefixes

Conversation

@jedevc

@jedevc jedevc commented Dec 12, 2023

Copy link
Copy Markdown
Contributor

This goes some way to fixing #6071 (@sipsma up to you if you want to leave it open for tracking the subpackage aspect, or splitting up core)

This allows a module "foo" to define it's own "FooContainer" type that won't be additionally namespaced into "FooFooContainer".


Previously, we skipped namespacing if the object was named the same as the module.

However, with this patch we can now additionally skip namespacing if the object if prefixed with the namespace.

@jedevc
jedevc requested a review from sipsma December 12, 2023 12:16
@jedevc jedevc added the zenith label Dec 12, 2023

@sipsma sipsma left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just need to delete debugging println before merge, otherwise LGTM!

Comment thread core/schema/schema.go Outdated

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can delete

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oop forgot about this one lol 😱

Previously, we skipped namespacing if the object was named the same as
the module.

However, with this patch we can now additionally skip namespacing if the
object if prefixed with the namespace.

Signed-off-by: Justin Chadwell <[email protected]>
@jedevc
jedevc force-pushed the namespacing-prefixes branch from ab3aa99 to a8b54e2 Compare December 13, 2023 11:16
@jedevc

jedevc commented Dec 13, 2023

Copy link
Copy Markdown
Contributor Author

@helderco curious if you've seen this python flake before: https://github.com/dagger/dagger/actions/runs/7194438979/job/19594973142#step:5:3880 (not a blocker for this PR, it just happened here last)

I've seen it across a few PRs (and started happening recently), but it always seems to disappear with a re-run.

@jedevc
jedevc merged commit 970bcfe into dagger:main Dec 13, 2023
@jedevc
jedevc deleted the namespacing-prefixes branch December 13, 2023 11:54
@helderco

Copy link
Copy Markdown
Contributor

@helderco curious if you've seen this python flake before: https://github.com/dagger/dagger/actions/runs/7194438979/job/19594973142#step:5:3880 (not a blocker for this PR, it just happened here last)

I've seen it across a few PRs (and started happening recently), but it always seems to disappear with a re-run.

Yeah, I've seen that but put it back of mind. It's the garbage collector in automatic provisioning during a stress test:

async with dagger.Connection(dagger.Config(retry=None)) as client:

I'll see if I can replicate locally and fix it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants