• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

Jaded-Encoding-Thaumaturgy / vs-jetpack / 14233061884 / 1
66%
main: 66%

Build:
DEFAULT BRANCH: main
Ran 03 Apr 2025 01:41AM UTC
Files 67
Run time 3s
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

03 Apr 2025 01:36AM UTC coverage: 59.591% (+0.4%) from 59.234%
14233061884.1

push

github

web-flow
vskernels: Replace `__init_subclass__` by a metaclass and instantiation check (#51)

The current implementation of `vskernels` checks the inherited classes
within the `__init_subclass__` method defined in `BaseScaler` when the
classes are constructed.

However, this approach has several issues:
- The `abstract_kernels` list is hardcoded with default values in a
separate location, leading to a cumbersome design where you have to wait
for these abstract classes to load.
- Abstract classes are bypassed and can be instantiated by the user,
even if they haven't specified a kernel radius.
- Declaring "abstract" classes in a `__abstract__` list at the top of
the file is misleading and questionable. These classes aren't truly
abstract since they can still be instantiated, and the kernel radius
check is simply skipped.

My proposed solution:
- Add a metaclass to `BaseScaler` to explicitly define abstract
classes—those that shouldn't be instantiated.
- Introduce a `partial_abstract` argument to bypass the kernel radius
check, preserving the current behavior for classes like
`vsscale.GenericScaler`.
- Classes like `Scaler` or `Kernel` will NOT continue to function as they did before. They will throw an error at class instantiation.
- The `kernel_radius` check will occur during class instantiation rather
than class construction, eliminating the need to explicitly add an
abstract argument when defining the abstract interface.
- All logic will be contained within the same file, avoiding scattered
code across multiple files.

3613 of 6063 relevant lines covered (59.59%)

0.6 hits per line

Source Files on job 67 - 3.12 - 14233061884.1
  • Tree
  • List 67
  • Changed 3
  • Source Changed 3
  • Coverage Changed 2
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Build 14233061884
  • c6e095ea on github
  • Prev Job for on main (#14232894077.2)
  • Next Job for on main (#14235354224.2)
  • Delete
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc