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

Option to hide "_build_tuple('_winapi'): could not locate source" messages #444

mpdehaan opened this issue Dec 11, 2018 · 5 comments


Copy link

@mpdehaan mpdehaan commented Dec 11, 2018

A lot of the _underscore speedup or optional modules generate warnings on screen, that will result in filing tickets about the applications, when they are really safe to ignore.


_build_tuple('_winapi'): could not locate source

Having some facility to either manually provide a list of these modules to ignore to the system, or globally disable all of these messages, is something I'd really need to have to use this.

Copy link

@dw dw commented Dec 11, 2018

So far when this comes up I've just been lowering the log levels involved. Really all this stuff is basically just debug output. Ideally 'mitogen.importer' would be a separate component that could have ERROR lever set by default, so these things would be all filtered entirely. It's actually easy to fix, but it requires figuring out which logger categories are most useful (Presently, debug output is overwhelming for pretty much everyone including me)

dw added a commit that referenced this issue Dec 11, 2018
Copy link

@dw dw commented Dec 11, 2018

Also note though that these messages are very useful, because they are recording network roundtrips that shouldn't exist.

Copy link

@mpdehaan mpdehaan commented Dec 13, 2018

Ah, so I really should blacklist those... good point... (I have yet to dig in to how to do that)...

Copy link

@dw dw commented Dec 13, 2018

it's not documented yet! mitogen.master.Router is the temporary home for a .responder attribute, which is a mitogen.master.ModuleResponder. It has a router.responder.blacklist_prefix(...) function that lets you set string prefixes for modules the target should never round-trip for. Before starting any context, call e.g. blacklist_prefix('_winapi') and the problem should go away.

Note this applies to round-trips the target should never make. The log message you hit is due to module dependency scanning in the master (i.e. the error may be due to some import of some import of some import for a legit package we always use). In that case, the log level lowering fix committed above is the only solution.

IIRC there is a ticket open elsewhere (and if not, this can be it) to automatically handle speedup modules. The master knows when the dep scanner hits a native module -- it just doesn't tell the target not to bother trying to load it, because it will be refused. A list of native modules just needs to be made an additional field in the LOAD_MODULE message

dw added a commit that referenced this issue Jan 19, 2019
dw added a commit that referenced this issue Jan 19, 2019
d2eb01f tests: pin idna to last supporting 2.6-compat version.
b90889c tests: pin idna to last supporting 2.6-compat version.
9da6e6a tests: don't call Router.shutdown() twice.
b2b7e7b tests: file_service_test fixes
04755c3 issue #426: tighten up PushFileService types.
8fa3c74 issue #426: RouterMonitor format incorrect for 3->2 forward.
d8b9634 issue #426: PushFileService missing to_text() call.
1e9f344 issue #426: big hack so reset_connection has task_var access
18bfde5 issue #444: update Changelog.
835bead tests: allow running scripts from any subdir.
81c93e1 ci: remove duplicate /usr/bin/time call
ca9ae45 issue #426: TemporaryEnvironment must coerce to Unicode.
4bc0d0e issue #426: apply_mode_spec() must handle bytes.
a8921bb tests: fix scaling in fork_histogram
374a361 docs: try to fix CSS difference between local and rtfd
861be2e docs: wrap text around logos
b084d83 docs: fit SVG viewbox to ansible logo
98d06e2 docs: delete shame.rst to make room for new chapters.
5f3244a docs: import pcaps (using LFS) to regenerate charts.
6936b93 tests: import
5a96d13 issue #426: fix all.yml sorting, one more delegate_to
bd82fa1 issue #426: fix low_level_execute_command.yml breakage.
a6e6bc4 issue #426: to_text filter.
d15f533 Turn on Travis build notifcations, but send them to IRC.
9d87f03 issue #426: disable Ansible smart transport.
49d37bf issue #426: remove LANG and LC_ALL during tests.
a6e6fd1 issue #426: more 2->3 test fixes.
67f710f issue #426: use delegate_to in fixup_perms2 and copy.yml
a67a436 docs: add #374 to Changelog.
2b229a6 docs: add thanks entry.
Copy link

@dw dw commented Jan 19, 2019

Closing this in favour of the older 'fix logging' tickets. ModuleResponder blacklist documentation is covered by the getting started docs ticket. Thanks for reporting this

@dw dw closed this Jan 19, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants