Comments (3)
Came across this issue as well. tomlkit.items.Array does implement __delitem__
so you can delete an item with del doc["array"][doc["array"].index(s)]
to get functionality similar to list.remove(s)
. It's not pretty though.
from tomlkit.
Ooh, nasty! Failing silently = not good!
Obvious thing to use insert
is a list comprehension:
mru = [x for x in self.parsed_toml_doc['mru_files']]
mru.insert(0, thing)
and then reset
self.parsed_toml_doc['mru_files'] = mru
from tomlkit.
This was fixed
from tomlkit.
Related Issues (20)
- unwrap() sometimes returns an internal tomlkit object
- How to diferentiate between inline and exploded tables when creating new TOML
- Float subtraction with tomlkit.items.Integer raises a NotImplementedType exception
- "IndexError: list index out of range" when using dotkeys and non-dotkeys HOT 1
- tomlkit does not work with pydantic `dict()` method HOT 1
- Uncaught exception in parse HOT 1
- Can I use tomlkit to dump a multi-line string? HOT 1
- Missing types in the `append()` method of the `Table` class HOT 2
- Bug in dumps? Stringifying subtables and nested arrays of tables, in arrays of tables HOT 1
- Request to be added to Tomlkit OSS-Fuzzer project members HOT 2
- Support `Decimal` serialization? HOT 1
- Support `bidict` inputs?
- Add indent control for multi-line `Array`
- Difference in whitespace in dot notation disappears
- I am switching to `rtoml` HOT 4
- Comments from original TOML end up in the wrong spot HOT 3
- datetime.utcnow and datetime.utcfromtimestamp are deprecated in Python 3.12
- Adding np.array and tomlkit.items.Float leads to NotImplementedType
- Write table with keys containing a dot HOT 3
- Bottleneck parsing
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 tomlkit.