-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
fix: workspace from dump may not match the one from yaml #1756
Conversation
Codecov Report
@@ Coverage Diff @@
## master #1756 +/- ##
==========================================
- Coverage 80.86% 79.38% -1.49%
==========================================
Files 135 135
Lines 6893 6897 +4
==========================================
- Hits 5574 5475 -99
- Misses 1319 1422 +103
Continue to review full report at Codecov.
|
Latency summaryCurrent PR yields:
Breakdown
Backed by latency-tracking. Further commits will update this comment. |
@@ -52,6 +52,12 @@ def parse(self, cls: Type['BaseExecutor'], data: Dict) -> 'BaseExecutor': | |||
if dump_path: | |||
obj = cls.load(dump_path) | |||
obj.logger.success(f'restore {cls.__name__} from {dump_path}') | |||
# consider the case where `dump_path` is not based on `obj.workspace`. This is needed |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
weird line break
# consider the case where `dump_path` is not based on `obj.workspace`. This is needed | ||
# for | ||
workspace_loaded_from = data.get('metas', {})['workspace'] | ||
workspace_in_dump = getattr(obj, 'workspace', None) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why do we have the scenario that workspace
is not defined?
Changes introduced
After refactoring in #1722, it seems that there was a bug when indexers are moved to docker.
The problem is that when the executor is loaded from the
mapped volume
in docker, the workspace is still in the.bin
and although is capable of recreating itself, it tries to fetch the data from the old workspace.Solution
I propose to have the workspace switched to the
workspace
folder from where is it loaded as it indicates that it has been "moved" or "mapped into thedocker
system".In the long term, I would suggest to get rid of
.bin
and have a single source of configuration from YAML and have every executor know what to expect