Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions .pylintrc
Original file line number Diff line number Diff line change
Expand Up @@ -460,7 +460,6 @@ disable=assignment-from-none,
missing-param-doc,
raise-missing-from,
raw-checker-failed,
super-with-arguments,
suppressed-message,
too-few-public-methods,
too-many-ancestors,
Expand All @@ -477,7 +476,6 @@ disable=assignment-from-none,
unsubscriptable-object,
use-implicit-booleaness-not-comparison-to-string,
use-implicit-booleaness-not-comparison-to-zero,
useless-object-inheritance,
useless-suppression,
use-symbolic-message-instead

Expand Down
1 change: 0 additions & 1 deletion artifactsrc/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
"""ForensicArtifacts.com Artifact Repository resources."""

__version__ = '20260411'
5 changes: 2 additions & 3 deletions artifactsrc/resource_file.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
"""Windows Message Resource file."""

import logging
Expand All @@ -7,7 +6,7 @@
import pywrc


class MessageResourceFile(object):
class MessageResourceFile:
"""Windows Message Resource file.

Attributes:
Expand All @@ -28,7 +27,7 @@ def __init__(
preferred_language_identifier (Optional[int]): preferred language
identifier (LCID).
"""
super(MessageResourceFile, self).__init__()
super().__init__()
self._ascii_codepage = ascii_codepage
self._exe_file = pyexe.file()
self._exe_file.set_ascii_codepage(self._ascii_codepage)
Expand Down
7 changes: 3 additions & 4 deletions artifactsrc/volume_scanner.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
"""Volume scanner for artifact definitions."""

import logging
Expand All @@ -23,7 +22,7 @@
from artifactsrc import resource_file


class CheckResults(object):
class CheckResults:
"""Check results.

Attributes:
Expand All @@ -33,7 +32,7 @@ class CheckResults(object):

def __init__(self):
"""Initializes check results."""
super(CheckResults, self).__init__()
super().__init__()
self.data_formats = set()
self.number_of_file_entries = 0

Expand Down Expand Up @@ -102,7 +101,7 @@ def __init__(self, artifacts_registry, mediator=None):
mediator (Optional[dfvfs.VolumeScannerMediator]): a volume scanner
mediator.
"""
super(ArtifactDefinitionsVolumeScanner, self).__init__(mediator=mediator)
super().__init__(mediator=mediator)
self._ascii_codepage = 'cp1252'
self._artifacts_registry = artifacts_registry
self._checks_definitions = None
Expand Down
1 change: 0 additions & 1 deletion docs/conf.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
"""Sphinx build configuration file."""

import os
Expand Down
10 changes: 4 additions & 6 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"

[project]
name = "artifactsrc"
version = "20260411"
version = "20260501"
description = "Digital Forensics Artifact knowledge base"
maintainers = [
{ name = "Joachim Metz", email = "joachim.metz@gmail.com" },
Expand Down Expand Up @@ -64,13 +64,11 @@ Documentation = "https://artifactsrc.readthedocs.io/en/latest"
Homepage = "https://github.com/ForensicArtifacts/artifacts-kb"
Repository = "https://github.com/ForensicArtifacts/artifacts-kb"

[tool.setuptools]
package-dir = {"artifactsrc" = "artifactsrc"}

[tool.setuptools.package-data]
artifactsrc = [
"*.yaml",
"data/*.yaml",
]

[tool.setuptools.packages.find]
where = ["."]
include = ["artifactsrc"]
exclude = ["docs", "tests", "tests.*", "utils"]
1 change: 0 additions & 1 deletion run_tests.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""Script to run the tests."""

from __future__ import print_function
Expand Down
1 change: 0 additions & 1 deletion tests/__init__.py
Original file line number Diff line number Diff line change
@@ -1 +0,0 @@
# -*- coding: utf-8 -*-
13 changes: 6 additions & 7 deletions tests/resource_file.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""Tests for the Windows Message Resource (WRC) file class."""

import unittest
Expand All @@ -9,7 +8,7 @@
from tests import test_lib


class TestWrcResource(object):
class TestWrcResource:
"""Windows Resource Compiler (WRC) resource for testing.

Attributes:
Expand All @@ -18,7 +17,7 @@ class TestWrcResource(object):

def __init__(self):
"""Initializes a resource."""
super(TestWrcResource, self).__init__()
super().__init__()
self.items = []

# pylint: disable=invalid-name
Expand All @@ -43,7 +42,7 @@ def get_item_by_index(self, index):
return self.items[index]


class TestWrcResourceItem(object):
class TestWrcResourceItem:
"""Windows Resource Compiler (WRC) resource item for testing.

Attributes:
Expand All @@ -57,7 +56,7 @@ def __init__(self, identifier):
Args:
identifier (int]): identifier.
"""
super(TestWrcResourceItem, self).__init__()
super().__init__()
self.identifier = identifier
self.resource_data = None
self.sub_items = []
Expand Down Expand Up @@ -92,7 +91,7 @@ def read(self):
return self.resource_data


class TestWrcStream(object):
class TestWrcStream:
"""Windows Resource Compiler (WRC) stream for testing.

Attributes:
Expand All @@ -101,7 +100,7 @@ class TestWrcStream(object):

def __init__(self):
"""Initializes a stream."""
super(TestWrcStream, self).__init__()
super().__init__()
self.resources = {}

# pylint: disable=invalid-name
Expand Down
5 changes: 2 additions & 3 deletions tests/test_lib.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
"""Shared test case."""

import os
Expand Down Expand Up @@ -50,12 +49,12 @@ def _SkipIfPathNotExists(self, path):
raise unittest.SkipTest(f'missing test file: {filename:s}')


class TempDirectory(object):
class TempDirectory:
"""Class that implements a temporary directory."""

def __init__(self):
"""Initializes a temporary directory."""
super(TempDirectory, self).__init__()
super().__init__()
self.name = ''

def __enter__(self):
Expand Down
1 change: 0 additions & 1 deletion tools/__init__.py
Original file line number Diff line number Diff line change
@@ -1,2 +1 @@
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
1 change: 0 additions & 1 deletion tools/check_artifacts.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""Script to check artifact definitions on a storage media image."""

import argparse
Expand Down
9 changes: 4 additions & 5 deletions tools/generate_docs.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""Script to generate artifact definition documentation."""

import argparse
Expand All @@ -14,12 +13,12 @@
from artifacts import registry as artifacts_registry


class IndexRstOutputWriter(object):
class IndexRstOutputWriter:
"""Index.rst output writer."""

def __init__(self, path):
"""Initializes an index.rst output writer."""
super(IndexRstOutputWriter, self).__init__()
super().__init__()
self._file_object = None
self._path = path

Expand Down Expand Up @@ -55,14 +54,14 @@ def WriteArtifactDefinition(self, artifact_name):
f' {artifact_name:s} <{artifact_name:s}>\n')


class MarkdownOutputWriter(object):
class MarkdownOutputWriter:
"""Markdown output writer."""

_URL_PREFIX = 'https://artifacts-kb.readthedocs.io/en/latest/sources/'

def __init__(self, path):
"""Initializes a Markdown output writer."""
super(MarkdownOutputWriter, self).__init__()
super().__init__()
self._file_object = None
self._path = path

Expand Down
1 change: 0 additions & 1 deletion utils/check_dependencies.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""Script to check for the availability and version of dependencies."""

import sys
Expand Down
11 changes: 5 additions & 6 deletions utils/dependencies.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
# -*- coding: utf-8 -*-
"""Helper to check for availability and version of dependencies."""

import configparser
import os
import re


class DependencyDefinition(object):
class DependencyDefinition:
"""Dependency definition.

Attributes:
Expand Down Expand Up @@ -36,7 +35,7 @@ def __init__(self, name):
Args:
name (str): name of the dependency.
"""
super(DependencyDefinition, self).__init__()
super().__init__()
self.dpkg_name = None
self.is_optional = False
self.l2tbinaries_name = None
Expand All @@ -52,7 +51,7 @@ def __init__(self, name):
self.version_property = None


class DependencyDefinitionReader(object):
class DependencyDefinitionReader:
"""Dependency definition reader."""

_VALUE_NAMES = frozenset([
Expand Down Expand Up @@ -106,7 +105,7 @@ def Read(self, file_object):
yield dependency_definition


class DependencyHelper(object):
class DependencyHelper:
"""Dependency helper.

Attributes:
Expand All @@ -127,7 +126,7 @@ def __init__(
test_dependencies_file (Optional[str]): path to the test dependencies
configuration file.
"""
super(DependencyHelper, self).__init__()
super().__init__()
self._test_dependencies = {}
self.dependencies = {}

Expand Down
Loading