summaryrefslogtreecommitdiff
path: root/rdflib/tools
Commit message (Collapse)AuthorAgeFilesLines
* fix: eliminate bare `except:` (#2350)Iwan Aucamp2023-04-123-4/+4
| | | | | | | | | | | Replace bare `except:` with `except Exception`, there are some cases where it can be narrowed further, but this is already an improvement over the current situation. This is somewhat pursuant to eliminating [flakeheaven](https://github.com/flakeheaven/flakeheaven), as it no longer supports the latest version of flake8 [[ref](https://github.com/flakeheaven/flakeheaven/issues/132)]. But it also is just the right thing to do as bare exceptions can cause problems.
* refactor: eliminate inheritance from object (#2339)Iwan Aucamp2023-04-101-2/+2
| | | | | This change removes the redundant inheritance from `object` (i.e. `class Foo(object): pass`) that is no longer needed in Python 3 and is a relic from Python 2.
* fix: reference to global inside `get_target_namespace_elements` (#2311)Iwan Aucamp2023-03-251-1/+1
| | | | | | | `get_target_namespace_elements` references the `args` global, which is not defined if the function is called from outside the module. This commit fixes that instead referencing the argument passed to the function. - Closes <https://github.com/RDFLib/rdflib/issues/2072>.
* fix: correctly handle resources with multiple comments in ↵Han Kruiger2023-03-141-1/+2
| | | | | | | defined_namespace_creator (#2254) FIxed a bug in defined_namespace_creator so that when a resource in an ontology is commented on multiple times (with e.g. rdfs:comment), it creates only a single class variable in the resulting DefinedNamespace where the Python comment is the concatenation of the rdfs:comments.
* feat: diverse type hints (#2264)Iwan Aucamp2023-03-122-10/+27
| | | | | | | Add some small diverse type hints. Type hints make RDFLib safer to use and change, as changes and usage can be validated using static analysers like mypy. This change does not have a runtime impact.
* build(deps-dev): bump black from 22.12.0 to 23.1.0 (#2248)dependabot[bot]2023-03-113-5/+0
|
* add chunk serializer & tests (#1968)Nicholas Car2022-08-121-0/+132
| | | | | | | | | This file provides a single function `serialize_in_chunks()` which can serialize a Graph into a number of NT files with a maximum number of triples or maximum file size. There is an option to preserve any prefixes declared for the original graph in the first file, which will be a Turtle file. Co-authored-by: Iwan Aucamp <aucampia@gmail.com>
* [pre-commit.ci] auto fixes from pre-commit.com hookspre-commit-ci[bot]2022-04-155-23/+18
| | | | for more information, see https://pre-commit.ci
* Add isort (#1689)eggplants2022-02-211-4/+2
| | | | | | | | | | | | | | | | | | | | | | | | * add: isort configure file * fix: isort $ isort . * add: isort to dev deps * add: isort to CI * fix: move .isort.cfg into setup.cfg * fix: re-formatted * fix: isort target path * Use pre-commit to check isort pre-commit CI can auto fix this, and this way we can idenpendently evaluate the formatting of the code from the validity of the code. Co-authored-by: Iwan Aucamp <aucampia@gmail.com>
* Black rdflib except for rdflib/namespace/_GEO.pyIwan Aucamp2022-01-021-5/+5
| | | | | | Probably we should ingore generated namespaces in black or format them on generation, or mark them for ignoring by formatter. Will look at that later.
* Update rdflib/tools/rdfs2dot.pyNicholas Car2021-12-171-1/+1
| | | Co-authored-by: Iwan Aucamp <aucampia@gmail.com>
* style fixes onlynicholascar2021-12-162-27/+25
|
* Merge pull request #1489 from RDFLib/hextuplesNicholas Car2021-12-091-5/+3
|\ | | | | Hextuples Serializer
| * Flak8 improvementsnicholascar2021-12-071-5/+3
| |
* | addressed @aucampia's 2 commentsnicholascar2021-12-071-47/+51
| |
* | add script to generated DefinedNamespaces, with testssdo-httpsnicholascar2021-12-011-0/+182
|/
* Fix typos discovered by codespellChristian Clauss2021-10-141-1/+1
|
* rename arg LOVE to nsjimman20032021-10-061-2/+2
|
* blacked everything6.0.0Nicholas Car2021-07-201-1/+4
|
* Merge branch 'master' into hsolbrig/masterEdmond Chuc2021-07-085-43/+34
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | # Conflicts: # rdflib/__init__.py # rdflib/compat.py # rdflib/namespace/__init__.py # rdflib/plugins/parsers/rdfxml.py # rdflib/plugins/serializers/rdfxml.py # rdflib/tools/csv2rdf.py # test/test_dawg.py # test/test_namespace.py # test/test_nt_misc.py # test/test_rdfxml.py # test/test_seq.py # test/test_trig.py # test/testutils.py
| * minor docco updatesNicholas Car2021-06-181-1/+3
| |
| * removed RDFa since format no longer supportedNicholas Car2021-04-251-2/+2
| |
| * fix: fixes #1208Blake Regalia2020-12-031-1/+1
| |
| * replace cgi by html, fixes issue #1110angus2020-08-271-2/+2
| |
| * Merge pull request #1149 from ashleysommer/t0b3_githubNicholas Car2020-08-275-35/+25
| |\ | | | | | | Remove all remnants of Python2 compatibility
| | * re-run blackAshley Sommer2020-08-271-1/+1
| | |
| | * fix escaping (deprecated since py 3.6)t0b32020-06-221-1/+1
| | | | | | | | | | | | Signed-off-by: t0b3 <thomas.bettler@gmail.com>
| | * 2to3 whole sourcebaset0b32020-06-225-35/+25
| | | | | | | | | | | | Signed-off-by: t0b3 <thomas.bettler@gmail.com>
| * | simplify yieldDonny Winston2020-08-051-1/+1
| | |
| * | make csv2rdf work in py3; add testDonny Winston2020-06-121-4/+3
| |/
* | Change to absolute imports to attempt to fix a Travis issuehsolbrig2020-05-261-1/+1
|/ | | | Fix a few odd's and ends warnings as well
* changes for flake8Nicholas Car2020-05-173-19/+18
|
* blacked all python filesNicholas Car2020-05-165-171/+307
|
* removal of all uses of package sixNicholas Car2020-05-162-10/+5
|
* a slightly opinionated autopep8 runGunnar Aastrand Grimnes2018-10-305-7/+17
| | | | | | | | opinions is mainly: no to long lines, but not at any cost. notation3.py crashses autopep :D Also rdflib/__init__.py gets completely broken
* bool support for csv2rdfGunnar Aastrand Grimnes2017-04-111-1/+16
|
* fixed tiny bug with literal columns in csv2rdfGunnar Aastrand Grimnes2017-04-111-1/+1
|
* default column conversions for csv2rdfGunnar Aastrand Grimnes2017-02-021-5/+16
|
* converted csv2rdf to sixGunnar Aastrand Grimnes2017-01-301-1/+4
|
* removed most of the six import from py3compatGunnar Aastrand Grimnes2017-01-301-1/+1
| | | | now six is used throughout.
* converted csv2rdfGunnar Aastrand Grimnes2017-01-301-12/+13
|
* trivial py3 conversion of toolsGunnar Aastrand Grimnes2017-01-304-2/+10
|
* removed compat code for supporting legacy python versionsGunnar Aastrand Grimnes2017-01-271-26/+1
|
* fixed a handful of stupid bugs in the csv2rdf toolGunnar Aastrand Grimnes2015-10-271-6/+9
|
* rdfpipe: open stdout in buffer mode in Python3 formatDan Scott2014-04-021-0/+4
| | | | | | | | Due to sys.stdout being string mode in Python 3 and all of the serializing happening in bytes mode, we need to open sys.stdout.buffer instead to avoid the exception "TypeError: must be str, not bytes". Closes #375. Signed-off-by: Dan Scott <dan@coffeecode.net>
* Allow colon in rdfpipe format kwargs and base as kwNiklas Lindström2013-10-221-3/+5
|
* minor rdf2dot whitespace fixGunnar Aastrand Grimnes2013-07-291-1/+1
|
* Do not add extra namespace bindings in rdfpipe (clutters output unnecessarily)Niklas Lindström2013-07-191-12/+1
|
* Use ConjunctiveGraph in rdfpipe to support parsing and serialization of datasetsNiklas Lindström2013-07-191-9/+12
|
* doc updatesgromgull2013-05-165-2/+38
|