Comments (3)
Hi.
First: My answer here also considers PR #459 and #460.
The choice to have users define this property explicitly, especially when overriding middleware, was made on purpose. I wanted to put an emphasis on the fact that there should be an option to not change the library passed as input. However, provided with the reactions received so far, and a fresh look over a year from implementing this I am happy to back off while I still can :-)
I am still not merging your PRs just yet for the following reasons:
- What's the reason for opening two distinct PRs? They appear to belong together. I do not particularly mind merging two PRs, but I am just wondering if I am missing a point. Is it because most Middleware already has the default set, but not the ones in #459?
- In #460: Any reason why you made this a default in
BlockMiddleware
, but not in the superclassMiddleware
or the sister classLibraryMiddleware
? - The docs (https://github.com/sciunto-org/python-bibtexparser/blob/main/docs/source/customize.rst) should probably be slightly extended and adapted to reflect these changes.
from python-bibtexparser.
- What's the reason for opening two distinct PRs? They appear to belong together. I do not particularly mind merging two PRs, but I am just wondering if I am missing a point. Is it because most Middleware already has the default set, but not the ones in Adding missing default
allow_inplace_modification
. Simplifying examples #459?
The two concern different options. #459 just makes existing code consistent. Instead, #460 applies a default that was not there yet.
- In
BlockMiddleware
: defaultallow_parallel_execution=True
#460: Any reason why you made this a default inBlockMiddleware
, but not in the superclassMiddleware
or the sister classLibraryMiddleware
?
Will fix.
- The docs (https://github.com/sciunto-org/python-bibtexparser/blob/main/docs/source/customize.rst) should probably be slightly extended and adapted to reflect these changes.
Agreed. I get the setting the default allow_parallel_execution=True
requires a bit more caution on the user side, so clear documentation is indeed important. Do you happen to have a simple example in mind for when allow_parallel_execution=True
would break things?
from python-bibtexparser.
Keeping the discussion centralized:
Point 2 is (and was) resolved:
-
LibraryMiddleware
does not have theallow_parallel_execution
option:python-bibtexparser/bibtexparser/middlewares/middleware.py
Lines 206 to 209 in e3757c1
-
#460 sets the default on
Middleware
. -
BlockMiddleware
has its own constructor.
Point 3: I added a documentation commit to #460
from python-bibtexparser.
Related Issues (20)
- Separator first names HOT 3
- Custom middleware HOT 3
- Errors in name-split HOT 3
- ✨ Nice way to handle enclosings for months while writing with the default stack HOT 1
- Suppress warnings HOT 3
- `DuplicateFieldKeyBlock.ignore_error_block` retains `{}` in field values HOT 4
- some suggestions from a first-time user HOT 1
- How to replace bp.bparser.BibTexParser() ? HOT 2
- Enclosing middleware fails for certain content HOT 3
- Use case sensitive entry type HOT 4
- Make behaviour entry closer to `dict`: check if field is present
- Discussion: closer `dict` mimicking `Entry` HOT 1
- Apply style using pre-commit HOT 1
- Normalize field keys (to lowercase) HOT 8
- docs: links to code not working
- docs: switch themes? HOT 4
- Error in latex_to_unicode
- split_multiple_persons_names() bug HOT 1
- More flexible handling of case sensitivity in all keys HOT 3
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 python-bibtexparser.