Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Warning: Unknown error: "File not found node_modules/directus-template-cli/dist/lib/downloads/official/agencyos/src/policies.json" #129

Closed
hyperfocus1337 opened this issue Dec 15, 2024 · 4 comments
Labels
bug Something isn't working

Comments

@hyperfocus1337
Copy link

npx directus-template-cli@latest apply
=== Directus Template CLI - Apply

? What type of template would you like to apply? Community templates
? Select a template. AgencyOS
You selected AgencyOS
------------------
What is your Directus URL? [http://localhost:8055]: 
? How do you want to log in? Directus Access Token
What is your Directus Admin Token?: xxx
-- Logged in as Admin User
=== Applying template - AgencyOS to http://localhost:8055

Loading 76 collections and 700 fields... done
Loading 176 relations... done
Loading 4 roles... done
 ›   Warning: Unknown error: "File not found: /Users/user/.npm/_npx/623fa71c079d6ec8/node_modules/directus-template-cli/dist/lib/downloads/official/agencyos/src/policies.json"
    Error: ENOENT: no such file or directory, open '/Users/user/.npm/_npx/623fa71c079d6ec8/node_modules/directus-template-cli/dist/lib/downloads/official/agencyos/src/policies.json'
    Code: ENOENT
@MansourAbdi
Copy link

I get the same error on Directus 10.13.1

@MansourAbdi
Copy link

In Directus 10.13.1 it worked with the following command
npx [email protected] apply

@ChuTungLinh
Copy link

is there still no general solution for this ?

@bryantgillespie
Copy link
Contributor

is there still no general solution for this ?

This is resolved in the latest version of the template CLI tool. There was an issue where it was loading the cached version of templates instead of downloading them fresh from the repo.

See directus-labs/directus-template-cli#68 (comment)

@bryantgillespie bryantgillespie added the bug Something isn't working label Dec 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants