Issue with Context annotations
See original GitHub issueSince the Context
class is in the same file as the code that imports the mutmut_config
, it cannot be used for the annotations. We are extensively using annotations in our code and want to do the same for mutmut_config.py
.
The issue is probably caused by cyclic import error and is shout since the import exceptions are in try-except.
I suggest moving the class into a separate module. In general, I think it’s a good idea to separate the code into a few modules.
Issue Analytics
- State:
- Created 3 years ago
- Comments:5 (2 by maintainers)
Top Results From Across the Web
Tweet annotations - Twitter Developers
Context annotations are delivered as a context_annotations field in the payload. These annotations are inferred based on semantic analysis (keywords, hashtags, ...
Read more >Annotation for context definition | ContextDefinition.php
When providing plugin annotations, contexts can be defined to support UI interactions through providing limits, and mapping contexts to appropriate plugins.
Read more >twitterdev/twitter-context-annotations: Flat files ... - GitHub
We aim to provide an updated file ~quarterly to encompass new entities that have been added – so please check back in a...
Read more >Problem with annotation spring context with differ modules
I made application based on spring annotation configuration. This application is moduled, i'm build it with maven. I scan application to find ...
Read more >problem building a rest api with @Context annotation
I have a lot of parameters posted to the REST api I am trying to build. So I want to use the @Context...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Let me think a bit over this later today, I’ll propose smt in a PR
Hm… well, I don’t think moving the class to another module will help much, as you’d still trigger the import in
__init__.py
to get to a submodule right?You’d have to make PR that changes the code so that the mutmut_config isn’t imported automatically like that. This seems like a good change anyway since this is more of a hack than a good design imo. Maybe something like a function in
mutmut/__init__.py
calledread_config
that does looks something like this:and then make sure that it’s called by
main()
.