🐍 A Python lib for (de)serializing Python objects to/from JSON

Overview

Python versions Downloads PyPI version Code Coverage Scrutinizer Code Quality

  • Turn Python objects into dicts or (json)strings and back
  • No changes required to your objects
  • Easily customizable and extendable
  • Works with dataclasses, attrs and POPOs

💗 this lib? Leave a ★ and tell your colleagues!

Example of a model to serialize:

>>> @dataclass
... class Person:
...    name: str
...    birthday: datetime
...
>>> p = Person('Guido van Rossum', birthday_guido)

Example of using jsons to serialize:

>>> out = jsons.dump(p)
>>> out
{'birthday': '1956-01-31T12:00:00Z', 'name': 'Guido van Rossum'}

Example of using jsons to deserialize:

>>> p2 = jsons.load(out, Person)
>>> p2
Person(name='Guido van Rossum', birthday=datetime.datetime(1956, 1, 31, 12, 0, tzinfo=datetime.timezone.utc))

Installation

pip install jsons

Usage

import jsons

some_instance = jsons.load(some_dict, SomeClass)  # Deserialization
some_dict = jsons.dump(some_instance)  # Serialization

In some cases, you have instances that contain other instances that need (de)serialization, for instance with lists or dicts. You can use the typing classes for this as is demonstrated below.

from typing import List, Tuple
import jsons

# For more complex deserialization with generic types, use the typing module
list_of_tuples = jsons.load(some_dict, List[Tuple[AClass, AnotherClass]])

(For more examples, see the FAQ)

Documentation

Meta

Recent updates

1.6.0

  • Feature: Support for Python3.10.
  • Feature: Support for attrs.

1.5.1

  • Bugfix: ZoneInfo failed to dump if attached to a datetime.

1.5.0

  • Feature: Support for ZoneInfo on Python3.9+.
  • Change: microseconds are no longer stripped by default (thanks to pietrodn).

1.4.2

  • Bugfix: get_origin did not work with python3.9+ parameterized collections (e.g. dict[str, str]).

1.4.1

  • Bugfix: Types of attributes that are not in the constructor were not properly looked for. See issue #128.

1.4.0

  • Feature: DefaultDicts can now be deserialized.
  • Feature: Dicts with any (hashable) key can now be dumped and loaded.
  • Feature: Suppress specific warnings.
  • Bugfix: Loading a verbose-serialized object in a list could sometimes deserialize that object as a parent class.
  • Bugfix: Unwanted stringification of NoneValues is now prevented in Optionals and Unions with NoneType.
  • Bugfix: Fixed a bug with postponed annotations and dataclasses. See also Issue34776.
  • Bugfix: Types of attributes that are not in the constructor are now looked for in annotations.

1.3.1

  • Bugfix: Fixed bug where classmethods were included in the serialized result.

1.3.0

  • Feature: Added warn_on_fail parameter to default_list_deserializer that allows to continue deserialization upon errors.
  • Feature: Added transform that can transform an object to an object of another type.
  • Feature: Added serializer and deserializer for pathlib.Path (thanks to alexmirrington).
  • Change: When loading a list fails, the error message now points to the failing index.
  • Bugfix: Fixed bug when dumping an object with an innerclass.

1.2.0

  • Bugfix: Fixed bug with postponed typehints (PEP-563).
  • Bugfix: Loading an invalid value targeting an optional did not raise.
  • Bugfix: Loading a dict did not properly pass key_transformers.
  • Bugfix: Loading a namedtuple did not properly use key_transformers.
  • Bugfix: Utilized __annotations__ in favor _field_types because of deprecation as of 3.8.

1.1.2

  • Feature: Added __version__ which can be imported from jsons
  • Bugfix: Dumping a tuple with ellipsis failed in strict mode.

1.1.1

  • Feature: Added a serializer for Union types.
  • Change: Exceptions are more clear upon deserialization failure (thanks to haluzpav).
  • Change: You can no longer announce a class with a custom name.
  • Bugfix: Fixed dumping optional attributes.
  • Bugfix: Dataclasses inheriting from JsonSerializable always dumped their attributes as if in strict mode.

1.1.0

  • Feature: Added strict parameter to dump to indicate that dumping a certain cls will ignore any extra data.
  • Feature: When using dump(obj, cls=x), x can now be any class (previously, only a class with __slots__).
  • Feature: Support for dumping Decimal (thanks to herdigiorgi).
  • Feature: Primitives are now cast if possible when dumping (e.g. dump(5, str)).
  • Feature: Dumping iterables with generic types (e.g. dump(obj, List[str])) will now dump with respect to that types (if strict)
  • Feature: The default_dict serializer now optionally accepts types: Optional[Dict[str, type]].
  • Change: Improved performance when dumping using strict=True (up to 4 times faster!).
  • Bugfix: set_validator with multiple types did not work.

1.0.0

  • Feature: Added a serializer/deserializer for time.
  • Feature: Added a serializer/deserializer for timezone.
  • Feature: Added a serializer/deserializer for timedelta.
  • Feature: Added a serializer/deserializer for date.
  • Bugfix: Dumping verbose did not store the types of dicts (Dict[K, V]).
  • Bugfix: Loading with List (no generic type) failed.
  • Bugfix: Loading with Dict (no generic type) failed.
  • Bugfix: Loading with Tuple (no generic type) failed.

Contributors

Special thanks to the following contributors of code, discussions or suggestions:

pietrodn, georgeharker, aecay, bibz, thijss, alexmirrington, tirkarthi, marksomething, herdigiorgi, jochembroekhoff, robinklaassen, ahmetkucuk, casparjespersen, cypreess, gastlich, jmolinski, haluzpav, finetuned89

Comments
  • Should dump be able to also pass class type to dictionary

    Should dump be able to also pass class type to dictionary

    Say I have a class inheritance structure, and I want to generically be able to dump/load with the correct class types in the inheritance structure.

    @dataclass
    class A(object):
        foo: int
    
    @dataclass
    class B(A):
        bar: int
    

    Assume that when loading, I do now know which class type it was dumped from. I would have to analyse the content to determine which class to load as, and then pass this to the cls property of jsons.load method.

    Would it make sense to implement an optional flag when dumping to a dictionary that contains information of what class type it was dumped as, that can then be used for loading?

    feature 
    opened by casparjespersen 15
  • Poor Performance on Serialization

    Poor Performance on Serialization

    It seems like serialization using jsons.dump(obj) is at least 10 times slower than writing custom serialization method to each class. In my case, obj was a nested dataclasses and data was in the order of 100MBs.

    I can pull up some numbers but I just wanted to start a discussion if this is a known issue and if so, what might cause this?

    performance 
    opened by ahmetkucuk 14
  • Wrongly serialized utc datetime

    Wrongly serialized utc datetime

    The datetime instance is wrongly serialized if initialized from utcnow(). Example:

    dt_local = datetime.datetime.now()
    print(dt_local)
    # >>> 2019-02-16 17:48:34.714603
    
    print(jsons.dump(dt_local))
    # >>> 2019-02-16T17:48:34+01:00
    
    dt_utc = datetime.datetime.utcnow()
    print(dt_utc)
    # >>> 2019-02-16 16:48:34.715108
    
    print(jsons.dump(dt_utc))
    # >>> 2019-02-16T16:48:34+01:00
    # this last one is clearly wrong
    
    feature 
    opened by haluzpav 10
  • Fix unspecified List deserialization

    Fix unspecified List deserialization

    This code:

    import jsons
    from typing import List
    
    jsons.load(["Hello", "World"], List)
    

    would fail with a: TypeError: 'NoneType' object is not callable.

    This is because the bare List type contains an __args__[0] which is a TypeVar, which is not callable when deserializing.

    This pull request fixed that by checking if the __args__[0] is actually usable and not just a bare TypeVar.

    opened by stan-janssen 7
  • 'mro' of 'type' object needs an argument

    'mro' of 'type' object needs an argument

    UserWarning: Failed to dump attribute "<class 'MyClassName'>" of object of type "MyType". Reason: descriptor 'mro' of 'type' object needs an argument. Ignoring the attribute.

    Hi there, I'm trying to switch to this from jsonpickle and am running into a case in which the above failure happens hundreds of times on a variety of nested objects. Any idea what the issue is?

    bug 
    opened by T-P-F 6
  • #160 list deserializer propagates fork_inst

    #160 list deserializer propagates fork_inst

    resolves #160 Other container serializers/deserializers don't seem to be affected by this bug, since they seem to already handle fork_inst correctly, though I haven't tested this.

    opened by patrickguenther 5
  • Allow get_type_hints to work with dataclasses where __init__ is created automatically and using delayed annotations

    Allow get_type_hints to work with dataclasses where __init__ is created automatically and using delayed annotations

    as per https://bugs.python.org/issue34776

    there can be issues when doing something like:

    from __future__ import annotations
    from typing import Optional, get_type_hints
    
    @dataclass
    class Foo:
       a: Optional[int]
    
    
    get_type_hints(Foo.__init__)
    
    

    will give

    Traceback (most recent call last):
      File "<stdin>", line 1, in <module>
      File "/usr/lib/python3.7/typing.py", line 1001, in get_type_hints
        value = _eval_type(value, globalns, localns)
      File "/usr/lib/python3.7/typing.py", line 260, in _eval_type
        return t._evaluate(globalns, localns)
      File "/usr/lib/python3.7/typing.py", line 464, in _evaluate
        eval(self.__forward_code__, globalns, localns),
      File "<string>", line 1, in <module>
    NameError: name 'Optional' is not defined
    

    Which causes such classes not to be able to read in by jsons.

    A workaround is to ensure that get_type_hints has the module dict of the class available to it.

    opened by georgeharker 4
  • performance issues

    performance issues

    Hi there,

    Loading a 1Go JSON file may take a while. Using the standard JSON API with the same JSON file may take approximatively 35 seconds.

    with jsons: time~ 20min

        with open(json_path, "r") as json_file:
            content = json_file.readlines()
            json_data = jsons.loads(content[0], CustomObject)
    

    The readlines function take 2 or 3 seconds.

    with json: time~ 35s

        with open(json_path, "r") as json_file:
            content = json.load(json_file)
            json_data = CustomObject(**content)
    

    What I'm doing wrong ?

    performance 
    opened by hugoliv 4
  • `jsons.dumps(np.array([0]))` reaches maximum recursion depth

    `jsons.dumps(np.array([0]))` reaches maximum recursion depth

    import jsons
    import numpy as np
    jsons.dumps(np.array([0]))
    

    causes the following error message to repeat:

    During handling of the above exception, another exception occurred:
    
    Traceback (most recent call last):
      File "/usr/local/anaconda3/lib/python3.7/site-packages/jsons/_main_impl.py", line 63, in dump
        return serializer(obj, cls=cls, **kwargs_)
      File "/usr/local/anaconda3/lib/python3.7/site-packages/jsons/serializers/default_object.py", line 56, in default_object_serializer
        **kwargs_)
      File "/usr/local/anaconda3/lib/python3.7/site-packages/jsons/serializers/default_dict.py", line 25, in default_dict_serializer
        strip_nulls=strip_nulls, **kwargs)
      File "/usr/local/anaconda3/lib/python3.7/site-packages/jsons/_main_impl.py", line 65, in dump
        raise SerializationError(str(err))
    jsons.exceptions.SerializationError: maximum recursion depth exceeded in comparison
    
    opened by shaunharker 4
  • Serializer of datetime with UTC

    Serializer of datetime with UTC

    Hi~, I using udatetime and jsons, the udatetime return UTC timezone is +00:00

    udatetime.utcnow()
    datetime.datetime(2019, 4, 12, 8, 31, 12, 471970, tzinfo=+00:00)
    

    So, is allow to add +00:00 to _datetime_offset_str in _datetime_impl.py ?

    if tzone.tzname(None) not in ('UTC', 'UTC+00:00'):
    

    edit to

    if tzone.tzname(None) not in ('UTC', 'UTC+00:00', '+00:00'):
    
    opened by abriko 4
  • Inherited class is lost while deserialization.

    Inherited class is lost while deserialization.

    Inherited class is lost while deserialization. In the example below, the object chmsg3 is serialized as a class ChatMessageSection with the weight attribute ('weight': 17, '-cls': 'main.ChatMessageSection'}]). But after deserialization the object becomes a ChatMessage.

    import jsons
    from dataclasses import dataclass
    from typing import List
    
    @dataclass
    class ChatUser:
        name: str
    
    @dataclass
    class ChatMessage:
        user: ChatUser
        msg_text: str
    
    @dataclass
    class ChatMessageSection(ChatMessage):
        weight: int
    
    @dataclass
    class ChatMessages:
        msg_list: List[ChatMessage]
    
    chmsg = ChatMessage(ChatUser("Thierry"), "Bonjour")
    chmsg2 = ChatMessage(ChatUser("Casimir"), "Hello")
    chmsg3 = ChatMessageSection(ChatUser("Leonard"), "Coucou", weight=17)
    chat_msgs = ChatMessages([chmsg, chmsg2, chmsg3])
    
    print(chat_msgs, end="\n\n")
    dumped = jsons.dump(chat_msgs, strip_microseconds=True, verbose=jsons.Verbosity.WITH_EVERYTHING)
    print(dumped, end="\n\n")
    instance = jsons.load(dumped)
    print(instance, end="\n\n")
    
    bug 
    opened by ThierryPfeiffer 4
  • DeserializationError: Invalid type:

    DeserializationError: Invalid type: "decimal.Decimal"

    Hey there,

    When "deserializating" a dictionary that contains a decimal.Decimal field, to a class that accepts that field as an int or a float, JSONS is throwing an exception:

    Traceback (most recent call last):
      File "testing-ground/decimal_jsons_test.py", line 19, in <module>
        a = jsons.load(dictionary, Something)
      File "testing-ground/env/lib/python3.10/site-packages/jsons/_load_impl.py", line 101, in load
        return _do_load(json_obj, deserializer, cls, initial, **kwargs_)
      File "testing-ground/env/lib/python3.10/site-packages/jsons/_load_impl.py", line 113, in _do_load
        result = deserializer(json_obj, cls, **kwargs)
      File "testing-ground/env/lib/python3.10/site-packages/jsons/deserializers/default_object.py", line 40, in default_object_deserializer
        constructor_args = _get_constructor_args(obj, cls, **kwargs)
      File "testing-ground/env/lib/python3.10/site-packages/jsons/deserializers/default_object.py", line 64, in _get_constructor_args
        key, value = _get_value_for_attr(obj=obj,
      File "testing-ground/env/lib/python3.10/site-packages/jsons/deserializers/default_object.py", line 94, in _get_value_for_attr
        result = sig_key, _get_value_from_obj(obj, cls, sig, sig_key,
      File "testing-ground/env/lib/python3.10/site-packages/jsons/deserializers/default_object.py", line 140, in _get_value_from_obj
        value = load(obj[sig_key], cls_, meta_hints=new_hints, **kwargs)
      File "testing-ground/env/lib/python3.10/site-packages/jsons/_load_impl.py", line 83, in load
        cls, meta_hints = _check_and_get_cls_and_meta_hints(
      File "testing-ground/env/lib/python3.10/site-packages/jsons/_load_impl.py", line 200, in _check_and_get_cls_and_meta_hints
        raise DeserializationError(msg, json_obj, cls)
    jsons.exceptions.DeserializationError: Invalid type: "decimal.Decimal", only arguments of the following types are allowed: str, int, float, bool, list, tuple, set, dict, NoneType
    

    But JSONS is capable of deserializing this dictionary just fine, we just need to modify the list of types it is supposed to be able to deserialize, here, we just need to add decimal.Decimal to the list of VALID_TYPES

    For this code:

    import jsons
    from decimal import Decimal
    from dataclasses import dataclass
    
    dictionary = {
        'value': Decimal(15.0)
    }
    
    @dataclass
    class Something:
        value: float
    
    a = jsons.load(dictionary, Something)
    print(a.value)
    

    Observed behavior: Jsons throws the above exception

    Expected behavior: a.value is initialized to 15.0

    Thanks

    opened by bziolo-dtiq 0
  • What's the key difference between `jsons` and `pydantic`?

    What's the key difference between `jsons` and `pydantic`?

    For serialization, one can export an instance of pydantic model to json

    from datetime import datetime
    from pydantic import BaseModel
    
    class BarModel(BaseModel):
        whatever: int
    
    class FooBarModel(BaseModel):
        foo: datetime
        bar: BarModel
    
    
    m = FooBarModel(foo=datetime(2032, 6, 1, 12, 13, 14), bar={'whatever': 123})
    print(m.json())
    #> {"foo": "2032-06-01T12:13:14", "bar": {"whatever": 123}}
    

    For deserialization, one can directly parse string into an instance of pydantic model

    from datetime import datetime
    from pydantic import BaseModel
    
    class User(BaseModel):
        id: int
        name = 'John Doe'
        signup_ts: datetime = None
    
    m = User.parse_raw('{"id": 123, "name": "James"}')
    print(m)
    #> id=123 signup_ts=None name='James'
    

    So, why jsons over pydantic?

    I can see that jsons being more lightweight for obvious reasons, but I wish to hear from the authors as well!

    opened by Raven888888 0
  • SerializationError: object of type 'abc' has no len()

    SerializationError: object of type 'abc' has no len()

    For some reason I cant seem to get a json dump for a pydantic baseModel class object

    eg:

    import jsons
    from pydantic import BaseModel 
    
    class abc(BaseModel):
        value: int
    
    d = abc(value=1)
    
    jsons.dump(d)
    

    OUTPUT SerializationError: object of type 'abc' has no len()

    EXPECTED The object should serialise fine.

    This is using jsons-1.6.3 and pydantic-1.9.1

    opened by duxbuse 2
  • How to make `jsons.dump()` treat `bytes` the same as Python3 `str`?

    How to make `jsons.dump()` treat `bytes` the same as Python3 `str`?

    How can one make jsons.dump() treat bytes the same as Python3 str? Some sort of serializer/class/setting change/override, perhaps?

    On my system (below) jsons.dump() prints my bytes type variables in a List-like format, even when assigning said variables a str literal (I think... maybe I don't understand Python3 properly? Quite possible). The pertinent excerpt:

    "{'originally_bytes_type': ['1', '2', '3', '4'], 'originally_str___type': '1234'}"

    All the context:

    $ cat jsons-dump-string-type-test.py
    #!/usr/bin/env python3
    
    from dataclasses import dataclass
    import jsons
    
    @dataclass
    class strs_and_bytes:
        originally_bytes_type : bytes
        originally_str___type : str
    
    sandb1 = strs_and_bytes \
    (
        originally_bytes_type = '1234' ,
        originally_str___type = '1234' ,
    )
    
    print('"' + str(jsons.dump(sandb1)) + '"')
    $ python3 jsons-dump-string-type-test.py
    "{'originally_bytes_type': ['1', '2', '3', '4'], 'originally_str___type': '1234'}"
    $ python3 --version
    Python 3.8.10
    $ pip3 install josons
    ^CERROR: Operation cancelled by user
    $ pip3 install jsons
    Requirement already satisfied: jsons in /usr/local/lib/python3.8/dist-packages (1.6.3)
    Requirement already satisfied: typish>=1.9.2 in /usr/local/lib/python3.8/dist-packages (from jsons) (1.9.3)
    $ lsb_release -a
    No LSB modules are available.
    Distributor ID:	Ubuntu
    Description:	Ubuntu 20.04.4 LTS
    Release:	20.04
    Codename:	focal
    $
    
    opened by johnnyutahh 2
  • add default (de)serializer for Literal values

    add default (de)serializer for Literal values

    I implemented these for a project I'm working on that uses jsons, then noticed https://github.com/ramonhagenaars/jsons/issues/170 and figured I may as well see if you like the implementation enough to go with it.

    I included the strictly_equal_literal as a compromise between correctness and utility.

    From https://peps.python.org/pep-0586/#equivalence-of-two-literals

    Two types Literal[v1] and Literal[v2] are equivalent when both of the following conditions are true:

    1. type(v1) == type(v2)
    2. v1 == v2

    I took that to mean that for a value to really match a literal it should match in both type and value. The only problem with that is that I've found it to be very useful to allow jsons to "coerce" values that are equal in value into the literal value, the use case that prompted me to implement this actually relies on that behaviour.

    opened by buckley-w-david 0
  • In nested objects, `load` is only called for the root object instead of being called for each one

    In nested objects, `load` is only called for the root object instead of being called for each one

    Hi, I have a problem where I'm trying to deserialize nested objects, and have each of their respective load functions trigger.

    Code example:

    from typing import List
    import jsons
    
    class B(jsons.JsonSerializable):
        c: List[str]
        
        @classmethod
        def load(cls, json_obj, **kwargs):
            print("Loading", cls)
            return jsons.load(json_obj, cls, **kwargs)
    
    class A(jsons.JsonSerializable):
        b: B
        
        @classmethod
        def load(cls, json_obj, **kwargs):
            print("Loading", cls)
            return jsons.load(json_obj, cls, **kwargs)
    
    obj = {'b': {'c': ['d', 'd']}}
    
    jsons.load(obj, A) # Nothing printed
    A.load(obj) # Only "Loading <class '__main__.A'>" is printed
    

    What I would expect as default behavior in this case is to have both Loading <class ...B> and Loading <class ...A> printed. Is there any way to achieve this behavior?

    Thanks!

    opened by itaiperi 1
Releases(v1.6.3)
  • v1.6.3(Jun 9, 2022)

  • v1.6.2(May 11, 2022)

  • v1.6.1(Jan 9, 2022)

    • Bugfix: Loading dicts with hashed keys could cause an error due to being loaded twice (thanks to georgeharker).
    • Bugfix: IntEnums were not serialized with their names when use_enum_name=True (thanks to georgeharker).
    • Bugfix: Named tuples did not use typing.get_type_hints for getting the types, causing trouble in future annotations (thanks to georgeharker).
    Source code(tar.gz)
    Source code(zip)
  • v1.6.0(Oct 31, 2021)

  • v1.5.1(Sep 1, 2021)

  • v1.5.0(Jul 18, 2021)

  • v1.4.2(Apr 10, 2021)

  • v1.4.1(Mar 31, 2021)

  • v1.4.0(Feb 6, 2021)

    • Feature: DefaultDicts can now be deserialized.
    • Feature: Dicts with any (hashable) key can now be dumped and loaded.
    • Feature: Suppress specific warnings.
    • Bugfix: Loading a verbose-serialized object in a list could sometimes deserialize that object as a parent class.
    • Bugfix: Unwanted stringification of NoneValues is now prevented in Optionals and Unions with NoneType.
    • Bugfix: Fixed a bug with postponed annotations and dataclasses. See also Issue34776.
    • Bugfix: Types of attributes that are not in the constructor are now looked for in annotations.
    Source code(tar.gz)
    Source code(zip)
  • v1.3.1(Jan 4, 2021)

  • v1.3.0(Oct 9, 2020)

    • Feature: Added warn_on_fail parameter to default_list_deserializer that allows to continue deserialization upon errors.
    • Feature: Added transform that can transform an object to an object of another type.
    • Feature: Added serializer and deserializer for pathlib.Path (thanks to alexmirrington).
    • Change: When loading a list fails, the error message now points to the failing index.
    • Bugfix: Fixed bug when dumping an object with an innerclass.
    Source code(tar.gz)
    Source code(zip)
  • v1.2.0(Jul 3, 2020)

    • Bugfix: Fixed bug with postponed typehints (PEP-563).
    • Bugfix: Loading an invalid value targeting an optional did not raise.
    • Bugfix: Loading a dict did not properly pass key_transformers.
    • Bugfix: Loading a namedtuple did not properly use key_transformers.
    • Bugfix: Utilized __annotations__ in favor _field_types because of deprecation as of 3.8.
    Source code(tar.gz)
    Source code(zip)
  • v1.1.1(Dec 22, 2019)

    • Feature: Added a serializer for Union types.
    • Change: Exceptions are more clear upon deserialization failure (thanks to haluzpav).
    • Change: You can no longer announce a class with a custom name.
    • Bugfix: Fixed dumping optional attributes.
    • Bugfix: Dataclasses inheriting from JsonSerializable always dumped their attributes as if in strict mode.
    Source code(tar.gz)
    Source code(zip)
  • v1.1.0(Dec 4, 2019)

    • Feature: Added strict parameter to dump to indicate that dumping a certain cls will ignore any extra data.
    • Feature: When using dump(obj, cls=x), x can now be any class (previously, only a class with __slots__).
    • Feature: Support for dumping Decimal (thanks to herdigiorgi).
    • Feature: Primitives are now cast if possible when dumping (e.g. dump(5, str)).
    • Feature: Dumping iterables with generic types (e.g. dump(obj, List[str])) will now dump with respect to that types (if strict)
    • Feature: The default_dict serializer now optionally accepts types: Optional[Dict[str, type]].
    • Change: Improved performance when dumping using strict=True (up to 4 times faster!).
    • Bugfix: set_validator with multiple types did not work.
    Source code(tar.gz)
    Source code(zip)
  • v1.0.0(Oct 7, 2019)

    • Feature: Added a serializer/deserializer for time.
    • Feature: Added a serializer/deserializer for timezone.
    • Feature: Added a serializer/deserializer for timedelta.
    • Feature: Added a serializer/deserializer for date.
    • Bugfix: Dumping verbose did not store the types of dicts (Dict[K, V]).
    • Bugfix: Loading with List (no generic type) failed.
    • Bugfix: Loading with Dict (no generic type) failed.
    • Bugfix: Loading with Tuple (no generic type) failed.
    Source code(tar.gz)
    Source code(zip)
    jsons-1.0.0.tar.gz(59.06 KB)
Py4J enables Python programs to dynamically access arbitrary Java objects

Py4J Py4J enables Python programs running in a Python interpreter to dynamically access Java objects in a Java Virtual Machine. Methods are called as

Barthelemy Dagenais 1k Jan 2, 2023
Freeze your objects in python

gelidum Freeze your objects in python. Latin English Caelum est hieme frigidum et gelidum; myrtos oleas quaeque alia assiduo tepore laetantur, asperna

Diego J. 51 Dec 22, 2022
Connect Playground - easy way to fill in your account with production-like objects

Just set of scripts to initialise accpunt with production-like data: A - Basic Distributor Account Initialization INPUT Distributor Account Token ACTI

CloudBlue 5 Jun 25, 2021
Utility to play with ADCS, allows to request tickets and collect information about related objects

certi Utility to play with ADCS, allows to request tickets and collect information about related objects. Basically, it's the impacket copy of Certify

Eloy 185 Dec 29, 2022
py-js: python3 objects for max

Simple (and extensible) python3 externals for MaxMSP

Shakeeb Alireza 39 Nov 20, 2022
A way to write regex with objects instead of strings.

Py Idiomatic Regex (AKA iregex) Documentation Available Here An easier way to write regex in Python using OOP instead of strings. Makes the code much

Ryan Peach 18 Nov 15, 2021
Kivy program for identification & rotation sensing of objects on multi-touch tables.

ObjectViz ObjectViz is a multitouch object detection solution, enabling you to create physical markers out of any reliable multitouch solution. It's e

TangibleDisplay 8 Apr 4, 2022
dynamically create __slots__ objects with less code

slots_factory Factory functions and decorators for creating slot objects Slots are a python construct that allows users to create an object that doesn

Michael Green 2 Sep 7, 2021
TB Set color display - Add-on for Blender to set multiple objects and material Display Color at once.

TB_Set_color_display Add-on for Blender with operations to transfer name between object, data, materials and action names Set groups of object's or ma

null 1 Jun 1, 2022
This Python library searches through a static directory and appends artist, title, track number, album title, duration, and genre to a .json object

This Python library searches through a static directory (needs to match your environment) and appends artist, title, track number, album title, duration, and genre to a .json object. This .json object is then used to post data to a specified table in a local MySQL database, credentials of which the user must set.

Edan Ybarra 1 Jun 20, 2022
A Python Based Utility for Processing GST-Return JSON Files to Multiple Formats

GSTR 1/2A Utility by Shan.tk Open Source GSTR 1/GSTR 2A JSON to Excel utility based on Python. Useful for Auditors in Verifying GSTR 1 Return Invoices

Sudharshan TK 1 Oct 8, 2022
Transparently load variables from environment or JSON/YAML file.

A thin wrapper over Pydantic's settings management. Allows you to define configuration variables and load them from environment or JSON/YAML file. Also generates initial configuration files and documentation for your defined configuration.

Lincoln Loop 90 Dec 14, 2022
Small tool to use hero .json files created with Optolith for The Dark Eye/ Das Schwarze Auge 5 to perform talent probes.

DSA5-ProbeMaker A little tool for The Dark Eye 5th Edition (Das Schwarze Auge 5) to load .json from Optolith character generation and easily perform t

null 2 Jan 6, 2022
Nuclei - Burp Extension allows to run nuclei scanner directly from burp and transforms json results into the issues

Nuclei - Burp Extension Simple extension that allows to run nuclei scanner directly from burp and transforms json results into the issues. Installatio

null 106 Dec 22, 2022
Todos os exercícios do Curso de Python, do canal Curso em Vídeo, resolvidos em Python, Javascript, Java, C++, C# e mais...

Exercícios - CeV Oferecido por Linguagens utilizadas atualmente O que vai encontrar aqui? ?? Esse repositório é dedicado a armazenar todos os enunciad

Coding in Community 43 Nov 10, 2022
PyDy, short for Python Dynamics, is a tool kit written in the Python

PyDy, short for Python Dynamics, is a tool kit written in the Python programming language that utilizes an array of scientific programs to enable the study of multibody dynamics. The goal is to have a modular framework and eventually a physics abstraction layer which utilizes a variety of backends that can provide the user with their desired workflow

PyDy 307 Jan 1, 2023
A Python script made for the Python Discord Pixels event.

Python Discord Pixels A Python script made for the Python Discord Pixels event. Usage Create an image.png RGBA image with your pattern. Transparent pi

Stanisław Jelnicki 4 Mar 23, 2022
this is a basic python project that I made using python

this is a basic python project that I made using python. This project is only for practice because my python skills are still newbie.

Elvira Firmansyah 2 Dec 14, 2022
Analisador de strings feito em Python // String parser made in Python

Este é um analisador feito em Python, neste programa, estou estudando funções e a sua junção com "if's" e dados colocados pelo usuário. Neste código,

Dev Nasser 1 Nov 3, 2021