// npm package
@antv/dw-analyzer
数据类型分析
weekly
63
monthly
420
versions
46
maintainers
51
license
MIT
first publish
2019-08-27
publisher
pddpd
tarball
108,382 B
AUTO-PUBLISHED·1 version indexed·latest published 2021-05-27
// publisher campaignby pddpd
6 caught packages from this accountThis is not an isolated catch. The same publisher has shipped 5 other packages that our pipeline flagged — the shape of a coordinated campaign, not a one-off. Each link below opens that sibling's analysis.
// offending code· @1.1.5· no static-pattern hits
llm: benign · 0.85→ No suspicious destination, no remote-exec shape — 1 known-vendor host(s).
- @1.1.5··AUTO-PUBLISHED·publisher: pddpdheuristic 75/100static flags 0llm benign (0.85) via ollamamature-packageosv-flagged:MAL-2026-3875
→ No suspicious destination, no remote-exec shape — 1 known-vendor host(s).
// offending code· no static-pattern hits
--- package.json (entry) --- { "name": "@antv/dw-analyzer", "version": "1.1.5", "description": "数据类型分析", "private": false, "browser": "dist/index.js", "main": "lib/index.js", "module": "es/index.js", "types": "lib/index.d.ts", "scripts": { "build": "rm -rf lib && tsc --pretty", "module": "rm -rf es && tsc -t ES5 -m ESNext --outDir es", "prepublish": "npm run module && npm run build && npm run pack", "pack": "webpack --config=webpack.config.js", "lint": "eslint --ext .ts src __tests__", "watch": "yarn module && yarn build --w" }, "publishConfig": { "access": "public" }, "license": "MIT", "keywords": [], "author": "AFX", "devDependencies": { "@babel/core": "^7.4.5", "@babel/plugin-proposal-class-properties": "^7.4.4", "@babel/plugin-proposal-object-rest-spread": "^7.4.4", "@babel/preset-env": "^7.4.5", "@babel/preset-typescript": "^7.7.4", "babel-loader": "^8.0.6", "tslib": "^2.2.0", "typescript": "^3.2.2", "webpack": "^4.41.2", "webpack-cli": "^3.3.9" }, "gitHead": "c0deb4ade08685f3620f45321efdd30102687265" } --- index.js (entry) --- "use strict"; /** * Analysis field type * * @example * * ```javascript * * import { type } from '@antv/dw-analyzer'; * * const a = [1, 2, 3] * * const info = type(a); * ``` * * @packageDocumentation */ Object.defineProperty(exports, "__esModule", { value: true }); exports.pearson = exports.isTime = exports.isNominal = exports.isInterval = exports.isContinuous = exports.isDiscrete = exports.isUnique = exports.isConst = exports.isOrdinal = exports.typeAll = exports.type = exports.isDateFieldInfo = exports.isNumberFieldInfo = exports.isStringFieldInfo = void 0; var tslib_1 = require("tslib"); var is_date_1 = require("./is-date"); var Stat = tslib_1.__importStar(require("./statistic")); var utils_1 = require("./utils"); /** * Determine what type a value is, may be one of [integer float date string null] */ function WhatType(source) { if (utils_1.isNull(source)) return 'null'; if (typeof source === 'number') { if (Number.isInteger(source)) return 'integer'; return 'float'; } if (typeof source === 'string') { if (utils_1.isDigit(source)) { if (source.includes('.')) return 'float'; --- bundled output (OSV-MAL flagged — LLM scope expansion) --- --- dist/index.js (bundled) --- !function(t,n){"object"==typeof exports&&"object"==typeof module?module.exports=n():"function"==typeof define&&define.amd?define([],n):"object"==typeof exports?exports.Analyzer=n():t.Analyzer=n()}(window,(function(){return function(t){var n={};function e(r){if(n[r])return n[r].exports;var o=n[r]={i:r,l:!1,exports:{}};return t[r].call(o.exports,o,o.exports,e),o.l=!0,o.exports}return e.m=t,e.c=n,e.d=function(t,n,r){e.o(t,n)||Object.defineProperty(t,n,{enumerable:!0,get:r})},e.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},e.t=function(t,n){if(1&n&&(t=e(t)),8&n)return t;if(4&n&&"object"==typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(e.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&n&&"string"!=typeof t)for(var o in t)e.d(r,o,function(n){return t[n]}.bind(null,o));return r},e.n=function(t){var n=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(n,"a",n),n},e.o=function(t,n){return Object.prototype.hasOwnProperty.call(t,n)},e.p="",e(e.s=2)}([function(t,n,e){"use strict";function r(t){return function(t){if(Array.isArray(t))return i(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||o(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function o(t,n){if(t){if("string"==typeof t)return i(t,n);var e=Object.prototype.toString.call(t).slice(8,-1);return"Object"===e&&t.constructor&&(e=t.constructor.name),"Map"===e||"Set"===e?Array.from(t):"Arguments"===e||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e)?i(t,n):void 0}}function i(t,n){(null==n||n>t.length)&&(n=t.length);for(var e=0,r=new Array(n);e<n;e++)r[e]=t[e];return r}Object.defineProperty(n,"__esModule",{value:!0}),n.isDateString=function(t)
