Repository Analysis

darktable-org/darktable

darktable is an open source photography workflow application and raw developer

1.9 Likely human-written View on GitHub
1.9
Adjusted Score
1.9
Raw Score
100%
Time Factor
2026-05-30
Last Push
12,470
Stars
C
Language
582,783
Lines of Code
1015
Files
941
Pattern Hits
2026-05-31
Scan Date

Score History

Severity Breakdown

CRITICAL 0HIGH 2MEDIUM 72LOW 867

Pattern Findings

941 matches across 11 categories. Click a row to expand file-level details.

Over-Commented Block835 hits · 835 pts
SeverityFileLineSnippet
LOWpackaging/macosx/3_make_hb_darktable_package.sh1#!/bin/bash
LOWtools/memory_leaks.py1#
LOWtools/rawspeed-diff-cameras-xml.rb1#!/usr/bin/env ruby
LOWtools/create_control_svg.sh1#!/bin/bash
LOWtools/purge_from_cache.sh1#!/bin/bash
LOWtools/dngmeta.rb1#!/usr/bin/env ruby
LOWtools/rawspeed-check-canon.rb1#!/usr/bin/env ruby
LOWtools/rawspeed-check-canon.rb61
LOWtools/appimage-build-script.sh1#!/usr/bin/env bash
LOWtools/appimage-build-script.sh21mkdir {build,AppDir}
LOWtools/appimage-build-script.sh41# AppImage, for the nightly builds we did this in the GitHub Action.
LOWtools/generate_styles_string.sh1#!/usr/bin/env bash
LOWtools/rawspeed-check-nikon-modes.rb1#!/usr/bin/env ruby
LOWtools/tiling.py1#
LOWtools/watch_folder.sh1#!/bin/bash
LOWtools/dngmeta.sh1#!/bin/bash
LOWtools/authors_h.sh1#!/bin/bash
LOWtools/authors_h.sh81# kate: tab-width: 2; replace-tabs on; indent-width 2; tab-indents: off;
LOWtools/basecurve/darktable-curve-tool.c21#include <stdint.h>
LOWtools/release/devel-stats.sh1#!/bin/bash
LOWtools/release/generate-translation.sh1#!/bin/bash
LOWtools/release/generate-authors.sh1#!/bin/bash
LOWtools/introspection/scanner.pm1# This file is part of darktable,
LOWtools/introspection/code_gen.pm1# This file is part of darktable,
LOWtools/introspection/parser.pl1#!/usr/bin/perl
LOWtools/introspection/parser.pm1# This file is part of darktable,
LOWtools/introspection/ast.pm1# This file is part of darktable,
LOWtools/introspection/ast.pm1141# modelines: These editor modelines have been set for all relevant files by tools/update_modelines.sh
LOWtools/ai/install-ort-amd-build.sh1#!/bin/bash
LOWtools/noise/graph2.sh21# only canon mark 2+3
LOW.ci/ci-script.sh1#!/bin/bash
LOWdev-doc/README.md41
LOWdata/kernels/common.h41#ifndef M_PI_2f
LOWdata/kernels/common.h61
LOWdata/kernels/common.h81 #pragma OPENCL FP_CONTRACT ON
LOWdata/style/lightbox.css1#lightbox{ position: absolute; left: 0; width: 100%; z-index: 100; text-align: center; line-height: 0;}
LOWdata/style/lightbox.css21#imageData{ padding:0 10px; color: #666; }
LOWdata/styles/CMakeLists.txt1#
LOWdata/themes/darktable.css1921 #thumb-main (GtkOverlay -- thumbnail widget)
LOWsrc/is_supported_platform.h21// WARNING: do not #include anything in here!
LOWsrc/is_supported_platform.h41#else
LOWsrc/is_supported_platform.h61#if !DT_SUPPORTED_X86 && !DT_SUPPORTED_ARMv8A && !DT_SUPPORTED_PPC64 && !DT_SUPPORTED_RISCV64 && !DT_SUPPORTED_LOONGARCH
LOWsrc/is_supported_platform.h81// modelines: These editor modelines have been set for all relevant files by tools/update_modelines.py
LOWsrc/main.c21#include "develop/develop.h"
LOWsrc/main.c181// vim: shiftwidth=2 expandtab tabstop=2 cindent
LOWsrc/config.cmake.h21
LOWsrc/config.cmake.h41#define __GNUC_PREREQ(maj, min) ((__GNUC__ << 16) + __GNUC_MINOR__ >= ((maj) << 16) + (min))
LOWsrc/config.cmake.h61
LOWsrc/config.cmake.h81 * OpenCL 1.2 is the version supported by Apple, otherwise we use 3.0
LOWsrc/develop/blend.h521 const dt_iop_roi_t *roi_out);
LOWsrc/develop/pixelpipe_cache.h101// vim: shiftwidth=2 expandtab tabstop=2 cindent
LOWsrc/develop/blend_gui.c21#include "common/debug.h"
LOWsrc/develop/imageop.c21#include "common/collection.h"
LOWsrc/develop/imageop.c41#include "dtgtk/gradientslider.h"
LOWsrc/develop/imageop_math.c961
LOWsrc/develop/lightroom.c21#include "common/colorspaces.h"
LOWsrc/develop/develop.c21#include <math.h>
LOWsrc/develop/develop.c41#include "develop/imageop.h"
LOWsrc/develop/develop.c1841 // Next section is to recover old edits where all modules with
LOWsrc/develop/tiling.h81 const int max_bpp);
775 more matches not shown…
Decorative Section Separators48 hits · 144 pts
SeverityFileLineSnippet
MEDIUMbuild.sh12# ---------------------------------------------------------------------------
MEDIUMbuild.sh14# ---------------------------------------------------------------------------
MEDIUMbuild.sh44# ---------------------------------------------------------------------------
MEDIUMbuild.sh46# ---------------------------------------------------------------------------
MEDIUMbuild.sh137# ---------------------------------------------------------------------------
MEDIUMbuild.sh139# ---------------------------------------------------------------------------
MEDIUMbuild.sh194# ---------------------------------------------------------------------------
MEDIUMbuild.sh196# ---------------------------------------------------------------------------
MEDIUMbuild.sh299# ---------------------------------------------------------------------------
MEDIUMbuild.sh301# ---------------------------------------------------------------------------
MEDIUMbuild.sh323# ---------------------------------------------------------------------------
MEDIUMbuild.sh325# ---------------------------------------------------------------------------
MEDIUMbuild.sh338# ---------------------------------------------------------------------------
MEDIUMbuild.sh340# ---------------------------------------------------------------------------
MEDIUMbuild.sh361# ---------------------------------------------------------------------------
MEDIUMbuild.sh363# ---------------------------------------------------------------------------
MEDIUMtools/noise/subr.sh1# --------------------------------------------------------------------
MEDIUMtools/noise/subr.sh3# --------------------------------------------------------------------
MEDIUMtools/noise/subr.sh251# --------------------------------------------------------------------
MEDIUMtools/noise/subr.sh253# --------------------------------------------------------------------
MEDIUMtools/noise/subr.sh508# --------------------------------------------------------------------
MEDIUMtools/noise/subr.sh510# --------------------------------------------------------------------
MEDIUMsrc/gui/welcome.c31// ── internal types ────────────────────────────────────────────────────────────
MEDIUMsrc/gui/welcome.c85// ── helpers ───────────────────────────────────────────────────────────────────
MEDIUMsrc/gui/welcome.c118// ── logo ──────────────────────────────────────────────────────────────────────
MEDIUMsrc/gui/welcome.c145// ── checkbox callback ─────────────────────────────────────────────────────────
MEDIUMsrc/gui/welcome.c154// ── dirchooser callbacks ──────────────────────────────────────────────────────
MEDIUMsrc/gui/welcome.c194// ── combobox callback ─────────────────────────────────────────────────────────
MEDIUMsrc/gui/welcome.c213// ── navigation state ──────────────────────────────────────────────────────────
MEDIUMsrc/gui/welcome.c272// ── page widget builder ───────────────────────────────────────────────────────
MEDIUMsrc/gui/welcome.c472// ── public API ────────────────────────────────────────────────────────────────
MEDIUMsrc/gui/welcome.c686 // ── static header (logo + app name) – never moves between pages ──────────
MEDIUMsrc/gui/welcome.c698 // ── stack of pages ────────────────────────────────────────────────────────
MEDIUMsrc/gui/welcome.c717 // ── footer ────────────────────────────────────────────────────────────────
MEDIUMsrc/gui/welcome.c751 // ── navigation state ──────────────────────────────────────────────────────
MEDIUMsrc/gui/welcome.c786// ── content definition & entry point ─────────────────────────────────────────
MEDIUMsrc/gui/welcome.c792 // ── Page 0: intro (hardcoded) ─────────────────────────────────────────────
MEDIUMsrc/gui/welcome.c807 // ── Dynamic conf pages (driven from darktableconfig.xml.in) ──────────────
MEDIUMsrc/gui/welcome.c833 // ── Last page: outro (hardcoded) ──────────────────────────────────────────
MEDIUMsrc/external/LibRaw-cmake/CMakeLists.txt1# ===========================================================
MEDIUMsrc/external/LibRaw-cmake/CMakeLists.txt23# ============================================================
MEDIUMsrc/external/LibRaw-cmake/CMakeLists.txt44# ==================================================================================================
MEDIUMsrc/external/LibRaw-cmake/CMakeLists.txt81# ==================================================================================================
MEDIUMsrc/external/LibRaw-cmake/CMakeLists.txt100# ==================================================================================================
MEDIUMsrc/control/conf.c942// ── welcome-screen metadata ───────────────────────────────────────────────────
MEDIUMsrc/iop/overlay.c366 // ── Acquire / refresh the scaled overlay buffer ──────────────────────────
MEDIUMsrc/iop/overlay.c393 // ── Allocate the Cairo output canvas ─────────────────────────────────────
MEDIUMsrc/iop/overlay.c428 // ── Cairo rendering ───────────────────────────────────────────────────────
Self-Referential Comments12 hits · 36 pts
SeverityFileLineSnippet
MEDIUMtools/memory_leaks.py2# This file is part of darktable,
MEDIUMtools/create_control_svg.sh3# This file is part of darktable,
MEDIUMtools/dtstyle_to_xmp.py30# Create a new xml structure.
MEDIUMtools/tiling.py2# This file is part of darktable,
MEDIUMtools/release/devel-stats.sh3# This file is part of darktable,
MEDIUMtools/release/generate-authors.sh3# This file is part of darktable,
MEDIUMtools/introspection/scanner.pm1# This file is part of darktable,
MEDIUMtools/introspection/code_gen.pm1# This file is part of darktable,
MEDIUMtools/introspection/parser.pl2# This file is part of darktable,
MEDIUMtools/introspection/parser.pm1# This file is part of darktable,
MEDIUMtools/introspection/ast.pm1# This file is part of darktable,
MEDIUM.ci/ci-script.sh3# This file is part of darktable.
AI Slop Vocabulary10 hits · 30 pts
SeverityFileLineSnippet
MEDIUMtools/noise/noiseprofile.c298 // estimate noise by robust statistic (assumes zero mean of HH band):
MEDIUMsrc/common/camera_control.c1225 // TODO: find a more robust way for this, once we find out how to do it with non-EOS cameras
MEDIUMsrc/common/ai/restore_raw_bayer.h62// tile postprocess so tile boundaries stay seamless.
MEDIUMsrc/views/lighttable.c1228 // we are not using the int value directly so it's robust against
MEDIUMsrc/views/lighttable.c1263 // we are not using the int value directly so it's robust against
MEDIUMsrc/views/darkroom.c1952 // we are not using the int value directly so it's robust against changes on lcms' side
MEDIUMsrc/views/darkroom.c1984 // we are not using the int value directly so it's robust against changes on lcms' side
MEDIUMsrc/dtgtk/culling.c647 // feels seamless rather than stepped. This must come before the integer-
MEDIUMsrc/iop/blurs.c238 // so we don't shift pixels. This is meant to allow seamless connection
MEDIUMsrc/iop/useless.c179// version. This is robust even if reordered. If only new fields were
Verbosity Indicators18 hits · 27 pts
SeverityFileLineSnippet
LOWsrc/libs/import.c432 // Step 1: try to check whether the image contains embedded thumbnail
LOWsrc/libs/import.c464 // Step 2: if we were not able to get a thumbnail at step 1,
LOWsrc/iop/ashift.c811 // Step 1: flip x and y coordinates (see above)
LOWsrc/iop/ashift.c818 // Step 2: rotation of image around its center
LOWsrc/iop/ashift.c832 // Step 3: apply shearing
LOWsrc/iop/ashift.c846 // Step 4: apply vertical lens shift effect
LOWsrc/iop/ashift.c861 // Step 5: horizontal compression
LOWsrc/iop/ashift.c874 // Step 6: flip x and y back again
LOWsrc/iop/ashift.c888 // Step 7: now we can apply horizontal lens shift with the same matrix format as above
LOWsrc/iop/ashift.c903 // Step 8: vertical compression
LOWsrc/iop/ashift.c916 // Step 9: apply aspect ratio scaling
LOWsrc/iop/ashift.c928 // Step 10: find x/y offsets and apply according correction so that
LOWsrc/iop/colorharmonizer.c641 // Step 1: compute per-pixel correction maps + cache JCH.
LOWsrc/iop/colorharmonizer.c654 // Step 2: Gaussian-blur corrections spatially.
LOWsrc/iop/colorharmonizer.c662 // Step 3: apply smoothed corrections from cached JCH → output.
LOWsrc/iop/demosaicing/rcd.c171 // Step 0: fill data and make sure data are not negative.
LOWsrc/iop/demosaicing/rcd.c506 // Step 2: Low pass filter incorporating green, red and blue local samples from the raw data
LOWsrc/iop/demosaicing/rcd.c511 // Step 3: populate the green channel at blue and red CFA positions
Synthetic Comment Markers2 hits · 15 pts
SeverityFileLineSnippet
HIGHsrc/common/mipmap_cache.c972 // we're write locked here, as requested by the alloc callback.
HIGHsrc/common/darktable.c1454 // Set directories as requested or default.
Excessive Try-Catch Wrapping4 hits · 6 pts
SeverityFileLineSnippet
LOWtools/discordrpc.py69 except Exception as e:
MEDIUMtools/discordrpc.py70 print(f"Error connecting to Discord: {e}")
LOWtools/discordrpc.py81 except Exception as e:
MEDIUMtools/discordrpc.py82 print(f"Error closing Discord connection: {e}")
Redundant / Tautological Comments3 hits · 4 pts
SeverityFileLineSnippet
LOWpackaging/macosx/1_install_hb_dependencies.sh13# Check if brew exists
LOWtools/dtstyle_to_xmp.py12# Check if the input file exists.
LOWtools/dtstyle_to_xmp.py17# Check if the requested output file already exist
Slop Phrases3 hits · 4 pts
SeverityFileLineSnippet
LOWsrc/libs/metadata_view.c130// list, don't forget to make changes to the SQL query as well.
LOWsrc/gui/gtk.c3675 // NOTE: When changing the default theme, don't forget to change it here!
LOWsrc/control/progress.h44/** cancel the job linked to with dt_control_progress_attach_job(). don't forget to call
Unused Imports3 hits · 3 pts
SeverityFileLineSnippet
LOWtools/update_modelines.py3
LOWtools/derive_filmic_v6_gamut_mapping.py5
LOWtools/extract_wb.py4
Deep Nesting3 hits · 3 pts
SeverityFileLineSnippet
LOWtools/update_modelines.py33
LOWtools/discordrpc.py36
LOWtools/tiling.py46