Comments (4)
Hmm, this raises another barrier to running on Windows. Currently, Bowler will generate inline fixer classes to run the appropriate selectors, filters, and modifiers, due to the way that lib2to3 works. This is fine when using forked processes, because the child processes have the same set of locally generated classes and functions. But Windows can only use spawned processes, requiring all classes and functions to be defined globally so that they are available in the children.
We should instead have Bowler use a single class defined at the global scope, and build some other mechanisms for loading those fixers into the lib2to3 refactoring tool.
from bowler.
@jreese would it make sense to default to in_process=True
on Windows for now?
from bowler.
That seems like a reasonable decision until we can find a better alternative.
from bowler.
FYI I had the same AttributeError: Can't pickle local object 'Query.create_fixer.<locals>.Fixer'
error on Mac OS X with Python 3.8.1.
Query.execute(in_process=True)
helped for now :)
EDIT: just found out this is already known: #111 (comment)
from bowler.
Related Issues (20)
- libCST support HOT 1
- pybowler.io TLS certificate has expired HOT 1
- Templates for common refactorings HOT 4
- Migrate Website to Docusaurus 2 Alpha
- how to handle moved function? HOT 1
- How to select strings and put an 'r' in front? HOT 4
- Do defaults to execute work?
- What are the restrictions on chaining select methods? HOT 4
- Refactoring Python 2.7 files does not work (parse error on print statement) HOT 4
- Some kind of test that verifies the requirements.txt is enough to run the tests
- Rename methods HOT 2
- Unable to chain remove_argument() HOT 5
- Question: I have a working select and modifier but want it to remove the matched node, can only make the node a blank line HOT 3
- Crash on functions with certain typehinting HOT 4
- Unable to apply hunk to file without trailing newline HOT 1
- Doc bugs: what is the syntax for `bowler test`?, obsolete or future-functionality documentation, and a doc info request HOT 1
- bowler/README.md documents `rename_function` however this functionality does not appear to exist
- Bowler should include docs on how to test/debug/understand lib2to3 patterns
- Ingore notebook syntax HOT 1
- `modify_argument` loses the trailing `,` in call arguments HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from bowler.