Giter Club home page Giter Club logo

melpazoid's People

Contributors

conao3 avatar dependabot[bot] avatar leotaku avatar peterhoeg avatar purcell avatar riscy avatar silex avatar sqrtminusone avatar zzkt avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

melpazoid's Issues

Using only the license checker

Is it possible to run melpazoid.py (or its licence checker) without Docker?

I'm trying to integrate melpazoid into Nix, and I've successfully run extra checks provided by melpazoid.el in Nix: akirak/elinter#24 (Note: I plan on rewriting the project from scratch for much less code, so the PR is just a demonstration.)

I'm also trying to run melpazoid.py (for the license checker) in Nix, but it invokes make test, which in turn starts building a Docker container, which causes the same issue as #1.

Since Docker is often used for similar purposes to Nix, it would be better if melpazoid.py could be run without Docker, or allow running only the license checker. There are many CI solutions for elisp projects out there, but AFAIK none of them check license, so it would be convenient to allow using the license checker independently.

file-missing Searching for program: "No such file or directory git"

Hi,

I am trying to write my first emacs package. While going through all the bells and whistles and the thought of submitting it later on melpa, I am trying to use this workflow. However, I get the following error on https://github.com/f3sch/b4.el/tree/fix_melpazoid (on master I tried to modify the action):
image

Not sure what is going on there...
On master it is failing with the same message and using the action provided by https://github.com/alphapapa/makem.sh works.

Any help is appreciated as I am not really familiar with github actions.
Thanks.

Sharp-quoting inside define-obsolete-function-alias forms

Hello, I followed the sharp-quoting advice from melpazoid.el and changed my code as follows:

;; error
(define-obsolete-function-alias #'org-starter-load-local-variables
  #'org-starter-org-mode-hook
  "0.2.9")

However, this causes a byte-compilation error (with Emacs 27.1) of org-starter-load-local-variables not being known to be defined.

The following code doesn't cause the byte-compilation error:

;; ok
(define-obsolete-function-alias 'org-starter-load-local-variables
  #'org-starter-org-mode-hook
  "0.2.9")

Likewise, sharp-quoting the first function in the following defalias form caused the same error:

;; error
(defalias #'org-starter-get-files-in-path #'org-starter--get-files-in-path)

According to the behavior of the byte-compiler, it is apparently wrong to sharp-quote obsolete functions. The following tests will need changes:

    ;; BTW, there shouldn't be the closing parenthesis at the end of this pattern
    (melpazoid-misc "(defalias '[^#()]*)" msg)
    (melpazoid-misc "(define-obsolete-function-alias '[[:graph:]]+ '[[:graph:]]" msg)

Note that the error doesn't occur when second functions are sharp-quoted. This must be because they are defined in prior to the alias definitions.

Mention compilation features in docs

Thanks for the scripts.
Today I was using melpazoid on a package I'm developing and was surprised to see:

byte-compile (using Emacs 27.1):

wikinfo.el:254:1:Warning: the following functions are not known to be defined:
    json-parse-string, libxml-parse-html-region

I assume the docker image is not compiled w JSON or libxml support.
Editing the file is easy enough, but it might be worth it to mention this in the docs and/or introduce another environmental variable to add compile options for the container's Emacs build.

Deprecated warnings for melpazoid actions

The following warnings are produced when running GitHub actions using the current melpazoid.yml:

  1. Node.js version warning

    build
    Node.js 12 actions are deprecated. For more information see: https://github.blog/changelog/2022-09-22-github-actions-all-actions-will-begin-running-on-node16-instead-of-node12/. Please update the following actions to use Node.js 16: actions/checkout@v2, actions/setup-python@v1

  2. Environment Files upgrade:

    The set-output command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/

Warning: docstring has wrong usage of unescaped single quote

Warning when updating melpazoid

With emacs-30 (build from master), I'm getting warnings.

In melpazoid--package-load-paths:
.config/emacs/local/melpazoid.el:58:2: Warning: docstring has wrong usage of unescaped single quotes (use \=' or different quoting such as `...')

In melpazoid--buffer-almost-empty-p:
.config/emacs/local/melpazoid.el:70:2: Warning: docstring has wrong usage of unescaped single quotes (use \=' or different quoting such as `...')

Issue with pkg-info erroring on present package-lint

I fixed a local copy with the following patch:

                     (buffer-name)
-                    (pkg-info-format-version
-                     (pkg-info-package-version "package-lint")))
+                     (pkg-info-version-info "package-lint"))
ELISP> (symbol-file 'package-lint 'provide)
"/home/user/.emacs.d/straight/build/package-lint/package-lint.elc"
ELISP> (pkg-info-package-version "package-lint")
*** Eval error ***  Can’t find installed package package-lint
ELISP> (pkg-info-version-info "package-lint")
"0"
ELISP> (epl-find-installed-package 'package-lint)
nil
ELISP> 

πŸ€·β€β™‚οΈ

I think epl might be broken, but I can't really follow it farther.

In any case, just to pump a message out to a buffer, I think pkg-info-version-info is fine.

update setup-python version

The current version (at d482d5d) didn't seem to work for me.

With an update to actions/checkout and actions/setup-python it looks like it's working as expected (and entered as an issue rather than PR since there may be something i'm overlooking)

    - uses: actions/checkout@v3
    - name: Set up Python 3.10
      uses: actions/setup-python@v4
      with:
        python-version: '3.10'

Conflict on installing requirements.txt

Hi. Dependency conflict occurs on installing requirements.txt. (Python 3.9.6)

>> pip install -r requirements.txt
Collecting requests==2.24
  Using cached requests-2.24.0-py2.py3-none-any.whl (61 kB)
Collecting certifi==2020.6.20
  Using cached certifi-2020.6.20-py2.py3-none-any.whl (156 kB)
Collecting chardet==3.0.4
  Using cached chardet-3.0.4-py2.py3-none-any.whl (133 kB)
Collecting urllib3==1.26.5
  Using cached urllib3-1.26.5-py2.py3-none-any.whl (138 kB)
Collecting idna==2.10
  Using cached idna-2.10-py2.py3-none-any.whl (58 kB)
ERROR: Cannot install -r requirements.txt (line 1) and urllib3==1.26.5 because these package versions have conflicting dependencies.

The conflict is caused by:
    The user requested urllib3==1.26.5
    requests 2.24.0 depends on urllib3!=1.25.0, !=1.25.1, <1.26 and >=1.21.1

To fix this you could try to:
1. loosen the range of package versions you've specified
2. remove package versions to allow pip attempt to solve the dependency conflict

meta: support for podman

This is probably a huge ask but would it be possible to support podman? Trying to run this locally gives:

python3 melpazoid/melpazoid.py
Using local repository at /Users/sean/projects/org-cv
<!-- Building container for ox-altacv... 🐳 -->


Stderr output while compiling/loading:
\ ```
make[1]: docker: No such file or directory
make[1]: *** [image] Error 1
\ ```

Package and license:
- Prefer the default recipe or `:defaults`, if possible.
- GNU General Public License v3.0 (via API)
- GPL* -- org-cv-utils.el: Common utility functions for CV exporters
- GPL* -- ox-altacv.el: LaTeX altacv Back-End for Org Export Engine

I'm totally willing to try to help but wanted to bring up this discussion first!

Stack at building container

Hi!

This project looks so cool!
But I try this project, stack at Building container...

$ MELPA_PR_URL=https://github.com/melpa/melpa/pull/6725 make
python melpazoid.py
Cloning https://github.com/srfi-explorations/emacs-srfi
Building container... 🐳
^CTraceback (most recent call last):
  File "melpazoid.py", line 563, in <module>
    check_melpa_pr(os.environ['MELPA_PR_URL'])
  File "melpazoid.py", line 495, in check_melpa_pr
    return run_checks(recipe, elisp_dir, clone_address, pr_data)
  File "melpazoid.py", line 82, in run_checks
    check_containerized_build(_package_name(recipe))
  File "melpazoid.py", line 91, in check_containerized_build
    output = subprocess.check_output(['make', 'test', f"PACKAGE_NAME={package_name}"])
  File "/usr/lib/python3.8/subprocess.py", line 411, in check_output
    return run(*popenargs, stdout=PIPE, timeout=timeout, check=True,
  File "/usr/lib/python3.8/subprocess.py", line 491, in run
    stdout, stderr = process.communicate(input, timeout=timeout)
  File "/usr/lib/python3.8/subprocess.py", line 1011, in communicate
    stdout = self.stdout.read()
KeyboardInterrupt
make: *** [Makefile:6: run] Interrupt

How to debug this issue?
My OS is linux, Emacs-26.3

Warning even when fset is used to define a prefix command

It's common to first define a keymap and then define a prefix command using fset:

(defvar apprentice-phoenix-command-map
  (let ((map (make-sparse-keymap)))
    (define-key map (kbd "n w") #'apprentice-phoenix-find-web)
    (define-key map (kbd "n v") #'apprentice-phoenix-find-views)
    (define-key map (kbd "n c") #'apprentice-phoenix-find-controllers)
    (define-key map (kbd "n l") #'apprentice-phoenix-find-channels)
    (define-key map (kbd "n t") #'apprentice-phoenix-find-templates)
    (define-key map (kbd "n m") #'apprentice-phoenix-find-models)
    (define-key map (kbd "n s") #'apprentice-phoenix-find-static)
    (define-key map (kbd "n r") #'apprentice-phoenix-router)
    (define-key map (kbd "n R") #'apprentice-phoenix-routes)
    map)
  "Keymap for Apprentice Phoenix commands after `apprentice-key-command-prefix'.")

(fset 'apprentice-phoenix-command-map apprentice-phoenix-command-map)

Melpazoid currently raises a false positive in this situation:

  • apprentice-phoenix.el#L116: Ensure this fset isn't being used as a surrogate defalias

Is it possible to suppress this kind of warning?

Trouble using `melpazoid` on Windows

I'm integrating melpazoid to Eask, so I'm trying to use this tool through the command line.

$ python melpazoid /path/to/my/openai/

It gives me this error output:

Set a recipe with: [--recipe RECIPE]

Then I tried the options --recipe:

$ python melpazoid /path/to/my/openai/ '(openai :fetcher github :repo "emacs-openai/openai")'

it gives me:

usage: melpazoid.py [-h] [--license] [--recipe RECIPE] [target]
melpazoid.py: error: argument --recipe: '(openai :fetcher github :repo emacs-openai/openai)' must be a valid MELPA recipe

If I tried using batch file:

set LOCAL_REPO=D:/_workspace/_eask/openai
set RECIPE=(openai :fetcher github :repo "jcs090218/openai")

make

it gives me:

Traceback (most recent call last):
  File "D:\_workspace\_eask\melpazoid\melpazoid\melpazoid.py", line 995, in <module>
    _main()
  File "D:\_workspace\_eask\melpazoid\melpazoid\melpazoid.py", line 987, in _main
    check_melpa_recipe(os.environ['RECIPE'])
  File "D:\_workspace\_eask\melpazoid\melpazoid\melpazoid.py", line 672, in check_melpa_recipe
    clone_address = _clone_address(recipe)
                    ^^^^^^^^^^^^^^^^^^^^^^
  File "D:\_workspace\_eask\melpazoid\melpazoid\melpazoid.py", line 826, in _clone_address
    (package-recipe--upstream-url {_recipe_struct_elisp(recipe)}))
                                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\_workspace\_eask\melpazoid\melpazoid\melpazoid.py", line 842, in _recipe_struct_elisp
    return eval_elisp(
           ^^^^^^^^^^^
  File "D:\_workspace\_eask\melpazoid\melpazoid\melpazoid.py", line 871, in eval_elisp
    raise ChildProcessError(f"Emacs crashed: {result.stderr.decode()}")
ChildProcessError: Emacs crashed: Non-hex character used for Unicode escape: s (115)

make: *** [Makefile:7: run] Error 1

I've tried several packages but they all have the same result. I'm pretty sure the recipe format is a valid MELPA recipe. Does this tool support local package? πŸ€”

Additional information:

  • Windows python3 will just be python.
  • I'm using Python version 3.11.5.

Check for existing packages by the same name

Melpa isn't a complete archive of Emacs packages. I think you should also check the Emacsmirror (including Emacsattic). You could use the epkg package for that purpose or you could just get the necessary information from the Emacsmirror's data repository directly.

As an example, this would have allowed you to notice when accepting melpa/melpa#6725 that https://www.emacswiki.org/emacs/download/srfi.el also exists. (You won't be able to see that now anymore, because I am updating the Emacsmirror to mirror that new implementation. That often is the right thing to do but its still a good idea to inspect the older implementation and to make the author of the new one aware of it in case they want to lift some ideas or something.)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.