Skip to content
This repository has been archived by the owner on Aug 31, 2023. It is now read-only.

🐛 chmod should be performed at pkg creation time instead of with postinstall hook #3799

Closed
1 task done
castarco opened this issue Nov 19, 2022 · 0 comments · Fixed by #3800
Closed
1 task done
Labels
A-CLI Area: CLI S-Bug: confirmed Status: report has been confirmed as a valid bug

Comments

@castarco
Copy link
Contributor

Environment information

yarn run v1.22.15
$ /home/castarco/Code/pencil4ts/node_modules/.bin/rome rage
CLI:
  Version:              10.0.1
  Color support:        true

Platform:
  CPU Architecture:     x86_64
  OS:                   linux

Environment:
  ROME_LOG_DIR:         unset
  NO_COLOR:             unset
  TERM:                 "xterm-256color"

Rome Configuration:
  Status:               loaded
  Formatter disabled:   false
  Linter disabled:      false

Workspace:
  Open Documents:       0

Discovering running Rome servers...

Running Rome Server: ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

i The client isn't connected to any server but rage discovered this running Rome server.

Server:
  Version:              10.0.1
  Name:                 rome_lsp
  CPU Architecture:     x86_64
  OS:                   linux

Workspace:
  Open Documents:       0

Other Active Server Workspaces:

Workspace:
  Open Documents:       1
  Client Name:          Visual Studio Code
  Client Version:       1.73.1

Workspace:
  Open Documents:       1
  Client Name:          Visual Studio Code
  Client Version:       1.73.1

Rome Server Log:

! Please review the content of the log file before sharing it publicly as it may contain sensitive information:
  * Path names that may reveal your name, a project name, or the name of your employer.
  * Source code

├─1632175ms INFO rome_lsp::server Starting Rome Language Server...

Done in 0.12s.

What happened?

  1. I had disabled postinstall scripts in my .npmrc file, to avoid/mitigate potential security issues.
  2. When I installed rome, I found it was failing. The reason was that the binary being called was not executable. After digging a bit, I discovered that this was happening because its "executable" flag depended on a postinstall hook being executed.

Expected result

The packaged binary should be executable from the very beginning. This can be done at packaging time, removing the need to call any postinstall hook.

Code of Conduct

  • I agree to follow Rome's Code of Conduct
@castarco castarco added the S-To triage Status: user report of a possible bug that needs to be triaged label Nov 19, 2022
@MichaReiser MichaReiser added the A-CLI Area: CLI label Nov 21, 2022
@MichaReiser MichaReiser added this to the 11.0.0 milestone Nov 21, 2022
MichaReiser pushed a commit that referenced this issue Nov 21, 2022
@ematipico ematipico added S-Bug: confirmed Status: report has been confirmed as a valid bug and removed S-To triage Status: user report of a possible bug that needs to be triaged labels Nov 30, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
A-CLI Area: CLI S-Bug: confirmed Status: report has been confirmed as a valid bug
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

3 participants