Package Details: semgrep-bin 1.97.0-1

Git Clone URL: https://aur.archlinux.org/semgrep-bin.git (read-only, click to copy)
Package Base: semgrep-bin
Description: Fast and syntax-aware semantic code pattern search for many languages: like grep but for code
Upstream URL: https://github.com/returntocorp/semgrep
Keywords: code grep
Licenses: LGPL2.1
Provides: semgrep
Submitter: aloxaf
Maintainer: username227 (ejedev)
Last Packager: username227
Votes: 7
Popularity: 0.79
First Submitted: 2020-05-23 02:08 (UTC)
Last Updated: 2024-11-20 05:29 (UTC)

Latest Comments

« First ‹ Previous 1 2 3 4 Next › Last »

Bujiraso commented on 2021-08-26 11:26 (UTC)

This is failing to install for me. I'm getting conflicts on python-pyroute2 since the tests are now in .../python3.9/...

Is it possible to wildcard this so that version changes don't impact the install? I don't see a point to keeping any tests.

Changing "3.8" to an unquoted wildcard (*) fixes here.

invidian commented on 2021-08-18 14:29 (UTC)

It seems the following change must be done to update to latest version:

diff --git PKGBUILD PKGBUILD
index d88d665..299708d 100644
--- PKGBUILD
+++ PKGBUILD
@@ -2,24 +2,22 @@

 pkgname=semgrep-bin
 _name=semgrep
-pkgver=0.59.0
+pkgver=0.62.0
 pkgrel=1
 pkgdesc="Fast and syntax-aware semantic code pattern search for many languages: like grep but for code"
 arch=(x86_64)
 url=https://github.com/returntocorp/semgrep
 license=(LGPL2.1)
 makedepends=('python-setuptools' 'python-wheel')
-depends=('python' 'python-attrs' 'python-colorama' 'python-junit-xml' 'python-requests' 'python-ruamel-yaml' 'python-tqdm' 'python-packaging' 'python-jsonschema')
+depends=('python' 'python-attrs' 'python-colorama' 'python-junit-xml' 'python-requests' 'python-ruamel-yaml' 'python-tqdm' 'python-packaging' 'python-jsonschema' 'python-peewee' 'python-wcmatch')
 provides=('semgrep')
 options=('!strip')
 source=(
   "https://github.com/returntocorp/semgrep/releases/download/v${pkgver}/semgrep-v${pkgver}-ubuntu-16.04.tgz"
   "https://files.pythonhosted.org/packages/source/${_name::1}/${_name}/${_name}-${pkgver}.tar.gz"
 )
-sha256sums=(
-  'ace2ce52e314a7c0450dfd7c31c2fd38b36b47f5a99c34e54a36ac4131f7513b'
-  '2d2a3e913ec779f53f5cb6db2ec10e949ed5b44996d5b185aab9c5dc5e2e5d58'
-)
+sha256sums=('ea48f88f4a45c8e32e9f4eec3b5a8f07c011ec4f082ad96d4f8d87c109156839'
+            '5b04fde7fdc880b541200c071ad00d26192494448cea812899b89a32e31518db')
 # https://github.com/returntocorp/semgrep/releases/download/v${pkgver}/semgrep-v${pkgver}-ubuntu-16.04.tgz.sha256

 build() {

lmartinez-mirror commented on 2021-07-21 05:36 (UTC) (edited on 2021-07-21 05:36 (UTC) by lmartinez-mirror)

This should be reuploaded as semgrep since it builds from source.

0xdbe commented on 2021-04-27 12:20 (UTC)

@aloxaf

It's working with yay.

Many thanks.

aloxaf commented on 2021-04-27 10:05 (UTC)

@0xdbe

Fixed. Please try again with yay.

0xdbe commented on 2021-04-27 08:47 (UTC)

This package failed to build with yay (yay v10.2.1 - libalpm v12.0.2):

==> WARNING: Using existing $srcdir/ tree
==> Starting build()...
Traceback (most recent call last):
  File "~/.cache/yay/semgrep-bin/src/semgrep-0.48.0/setup.py", line 85, in <module>
    src = find_executable(binary_env, binary_name)
  File "~/.cache/yay/semgrep-bin/src/semgrep-0.48.0/setup.py", line 73, in find_executable
    raise Exception(
Exception: Could not find 'semgrep-core' executable, tried 'SEMGREP_CORE_BIN' and system 'semgrep-core'
==> ERROR: A failure occurred in build().
    Aborting...

aloxaf commented on 2021-01-19 13:00 (UTC)

@dkasak Oh sorry! It's a stupid mistake -- I forgot to remove the debug code.

dkasak commented on 2021-01-19 12:47 (UTC)

@aloxaf, the latest version failed to build for me with yay. I then cloned the repository and tried running makepkg directly but it failed again:

[...]

running egg_info
writing semgrep.egg-info/PKG-INFO
writing dependency_links to semgrep.egg-info/dependency_links.txt
writing entry points to semgrep.egg-info/entry_points.txt
writing requirements to semgrep.egg-info/requires.txt
writing top-level names to semgrep.egg-info/top_level.txt
reading manifest file 'semgrep.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
writing manifest file 'semgrep.egg-info/SOURCES.txt'
copying semgrep/rule_schema.yaml -> build/lib/semgrep
chmod: cannot access 'build/lib/semgrep/bin/semgrep-core': No such file or directory
chmod: cannot access 'build/lib/semgrep/bin/spacegrep': No such file or directory
==> ERROR: A failure occurred in build().
    Aborting...

I then did some manual mucking around in the pkg dir after which the makepkg succeeded. I'm not sure what made it succeed, but one of the things I did was to copy semgrep-core and spacegrep from $srcdir/semgrep-files to $srcdir/semgrep-0.37.0/semgrep/bin manually.

TL;DR: The package doesn't build cleanly as it stands and I think you might have missed it because you did a manual step like me before.

aloxaf commented on 2020-11-10 14:04 (UTC)

@dkasak

Thanks. They are now removed.

dkasak commented on 2020-11-10 13:39 (UTC)

@aloxaf, the conflict with the python-hypothesis package is still present in the new version of the package. I guess it's an upstream packaging error; it's a bit weird to use a non-namespaced tests package.

Perhaps you could just delete everything under /usr/lib/python3.8/site-packages/tests from this package as a workaround, given that it appears it's just test code?