Comments (5)
Closing this because the new CLI has been released
from extism.
Maybe this needs to change to require sudo: https://github.com/extism/cli/blob/987f0fdbcfe103a578fc57c385bf831c8733ecc4/extism_cli/__init__.py#L349
from extism.
Looks like it is asking for your password though. So that's confusing
from extism.
I cannot seem to repro. Trying a new bash session too:
[I] ben@m1lap ~ [1]> rm /usr/local/include/extism.h
override rwxr-xr-x root/wheel for /usr/local/include/extism.h?
[I] ben@m1lap ~> extism install latest
Getting release for latest
Installing to /usr/local/ (version v0.1.0)
Password:
Installed /usr/local/lib/libextism.dylib
Installed /usr/local/include/extism.h
from extism.
I believe the issue is because I did not have a /usr/local/include
folder, and the /usr/local
dir is only writable by root on my Mac. If you look at the cp
definition itself, it will auto-sudo if the path is in /usr/
.
However, the python makedirs command is being used to create the directory. Even though the script does a sudo later for writing the file, and that works correctly if the path already exists, the script fails if you do not yet have /usr/local/include
. I think os.mkdir needs to be wrapped in an auto-sudo like the cp function (and run mkdir -p {path}
to recursively make the directory from a subprocess.)
Here are the permissions for my /usr/local
showing it's only writable by root
➜ local ls -al /usr/local
total 0
drwxr-xr-x 6 root wheel 192 Dec 29 17:09 .
drwxr-xr-x@ 11 root wheel 352 Aug 24 01:59 ..
drwxr-xr-x 14 root wheel 448 Dec 22 21:58 bin
drwxr-xr-x 3 root wheel 96 Dec 29 17:09 include
drwxr-xr-x 4 root wheel 128 Dec 29 17:08 lib
drwxr-xr-x 3 root wheel 96 Dec 19 19:14 share
Here's the listing of my include dir showing extism is the only thing in there. you may have already had this directory created so didn't run into this issue, since the cp command is correctly sudoing. The only issue seems to be in the mkdir part.
➜ local ls -al /usr/local/include
total 8
drwxr-xr-x 3 root wheel 96 Dec 29 17:09 .
drwxr-xr-x 6 root wheel 192 Dec 29 17:09 ..
-rw-r--r-- 1 root wheel 3042 Dec 29 17:09 extism.h
from extism.
Related Issues (20)
- Regression: Can't cancel multiple calls for the same plugin instance HOT 1
- Implement Java PDK HOT 1
- The runtime only returns a generic error when calling `extism_plugin_error` HOT 1
- Improve MSVC support HOT 5
- via proto conversation: refine extism error message when plugin calls fail
- via proto conversation: add example of using extism+tracing to rust runtime HOT 1
- Build linux libextism on manylinux/musllinux containers HOT 8
- Add extism_load_v128/extism_store_v128 HOT 5
- Double mutable borrow issue for `host_fn` with Rust SDK HOT 4
- Error when passing an empty String from Plugin to Runtime via a host function or a logging macro HOT 3
- Add building and installing cmake config mode package
- [Question] How to reload plugin with new wasm file? HOT 6
- extism_length returns garbage values when an ExtismPointer is not aligned with an alloc HOT 1
- feature: Give users a way to manage timeouts from inside host functions HOT 3
- [Question] nodejs call rust wasm function failed. HOT 2
- [Question] C plugin example build failed HOT 2
- Consider reverting `length` safety improvement HOT 3
- sdk: consider switching away from null terminated strings to ptr and length HOT 1
- runtime: update `Plugin::function_extists` and `extism_plugin_function_exists` to check the type of the functions too HOT 4
- derive that forwards From/ToBytes to specific encoding HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from extism.