Skip to main content

Questions tagged [dependencies]

A dependency exists between two elements if changes to the definition of one element may cause changes to the other.

Filter by
Sorted by
Tagged with
2923 votes
16 answers
1.0m views

What's the difference between dependencies, devDependencies, and peerDependencies in NPM package.json file?

This documentation answers my question very poorly. I didn't understand those explanations. Can someone say in simpler words? Maybe with examples if it's hard to choose simple words? Also added ...
Vitalii Korsakov's user avatar
1653 votes
35 answers
1.7m views

How to add local jar files to a Maven project?

How do I add local jar files (not yet part of the Maven repository) directly in my project's library sources?
Praneel PIDIKITI's user avatar
1347 votes
28 answers
2.1m views

Automatically create file 'requirements.txt'

Sometimes I download the Python source code from GitHub and don't know how to install all the dependencies. If there isn't any requirements.txt file I have to create it by hand. Given the Python ...
Igor Barinov's user avatar
  • 24.1k
920 votes
62 answers
1.4m views

The located assembly's manifest definition does not match the assembly reference

I am trying to run some unit tests in a C# Windows Forms application (Visual Studio 2005), and I get the following error: System.IO.FileLoadException: Could not load file or assembly 'Utility, ...
leora's user avatar
  • 194k
906 votes
12 answers
766k views

How do I tell Maven to use the latest version of a dependency?

In Maven, dependencies are usually set up like this: <dependency> <groupId>wonderful-inc</groupId> <artifactId>dream-library</artifactId> <version>1.2.3</...
Anders Sandvig's user avatar
674 votes
14 answers
413k views

How to find unused packages in package.json?

Is there a way to determine if you have packages in your package.json file that are no longer needed? For instance, when trying out a package and later commenting or deleting code, but forgetting to ...
Josh C's user avatar
  • 8,121
507 votes
8 answers
243k views

Gradle Implementation vs API configuration

I'm trying to figure out what is the difference between api and implementation configuration while building my dependencies. In the documentation, it says that implementation has better build time, ...
reinaldomoreira's user avatar
483 votes
6 answers
316k views

Depend on a branch or tag using a git URL in a package.json?

Say I've forked a node module with a bugfix and I want to use my fixed version, on a feature branch of course, until the bugfix is merged and released. How would I reference my fixed version in the ...
hurrymaplelad's user avatar
426 votes
17 answers
322k views

Why does npm install say I have unmet dependencies?

I have a node package. When I run npm install from the package root, it installs a bunch of things, but then prints several error messages that look like this: npm WARN unmet dependency /Users/...
Sean Mackesey's user avatar
424 votes
65 answers
262k views

Duplicate class in Kotlin Android

I kept on getting an error that there is a duplicate error in classes. This is what I have under org.jetbrains.kotlin folder .idea/libraries It seems like the problem is because there is two different ...
midnighthowlers's user avatar
367 votes
19 answers
152k views

Detecting superfluous #includes in C/C++

I often find that the headers section of a file gets larger and larger all the time, but it never gets smaller. Throughout the life of a source file, classes may have moved and been refactored and it'...
shoosh's user avatar
  • 78.2k
366 votes
26 answers
551k views

The engine "node" is incompatible with this module

I am getting below yarn error when deploying to AWS: error [email protected]: The engine "node" is incompatible with this module. Expected version ">=6 <7 || >=8". Got "...
JN_newbie's user avatar
  • 5,902
340 votes
25 answers
770k views

Maven: Failed to read artifact descriptor

I am hoping someone can help me with a problem I am struggling with. When I try to build my project from the terminal I get this error: Failed to read artifact descriptor for com.morrislgn....
Morrislgn's user avatar
  • 3,807
315 votes
4 answers
566k views

How do I install package.json dependencies in the current directory using npm

I have a web app: fooapp. I have a package.json in the root. I want to install all the dependencies in a specific node_modules directory. How do I do this? What I want Lets say I have two widget ...
Daniel Beardsley's user avatar
310 votes
10 answers
700k views

How to get a dependency tree for an artifact?

dependency:tree can be used to see the dependency tree for a given project. But what I need is to see the dependency tree for a 3rd party artifact. I guess I can create an empty project, but I'm ...
IttayD's user avatar
  • 28.9k
308 votes
27 answers
277k views

How to set compileJava' task ( 11) and 'compileKotlin' task (1.8) jvm target compatibility to the same Java version in build.gradle.kts?

Build.gradle.kts buildscript { repositories { google() mavenCentral() gradlePluginPortal() } dependencies { classpath ("com.android.tools.build:gradle:...
jitendra kumar's user avatar
302 votes
16 answers
355k views

Make Maven to copy dependencies into target/lib

How do I get my project's runtime dependencies copied into the target/lib folder? As it is right now, after mvn clean install the target folder contains only my project's jar, but none of the ...
Michael's user avatar
  • 3,149
300 votes
20 answers
179k views

MSBuild doesn't copy references (DLL files) if using project dependencies in solution

I have four projects in my Visual Studio solution (everyone targeting .NET 3.5) - for my problem only these two are important: MyBaseProject <- this class library references a third-party DLL file ...
toebens's user avatar
  • 4,059
299 votes
13 answers
360k views

npm install private github repositories by dependency in package.json

I'm trying to install github private repository by npm that includes other private github repositories as dependency. Have tried a lot of ways and posts but none is working. Here is what i'm doing : ...
vashishatashu's user avatar
280 votes
12 answers
458k views

How to check for DLL dependency?

Sometimes when I'm doing a little project I'm not careful enough and accidentally add a dependency for a DLL that I am not aware of. When I ship this program to a friend or other people, "it doesn't ...
orlp's user avatar
  • 115k
273 votes
12 answers
311k views

Exclude all transitive dependencies of a single dependency

In Maven2, to exclude a single transitive dependency, I have to do something like this: <dependency> <groupId>sample.group</groupId> <artifactId>sample-artifactB</...
pbreault's user avatar
  • 14.4k
271 votes
10 answers
410k views

Maven: add a dependency to a jar by relative path

I have a proprietary jar that I want to add to my pom as a dependency. But I don't want to add it to a repository. The reason is that I want my usual maven commands such as mvn compile, etc, to work ...
flybywire's user avatar
  • 269k
259 votes
17 answers
496k views

Fix the upstream dependency conflict installing NPM packages

I am trying to npm install vue-mapbox mapbox-gl, and I'm getting a dependency tree error. I'm running Nuxt.js SSR with Vuetify and haven't installed anything related to Mapbox prior to running this ...
connorcode's user avatar
  • 2,771
225 votes
17 answers
283k views

node.js TypeError: path must be absolute or specify root to res.sendFile [failed to parse JSON]

[add] So my next problem is that when i try adding a new dependence (npm install --save socket.io). The JSON file is also valid. I get this error: Failed to parse json npm ERR! Unexpected string npm ...
IE8IsBetterThenGoogleChrome's user avatar
218 votes
17 answers
138k views

Multi-project test dependencies with gradle

I have a multi-project configuration and I want to use gradle. My projects are like this: Project A -> src/main/java -> src/test/java Project B -> src/main/java (depends on src/main/java on ...
mathd's user avatar
  • 2,525
212 votes
8 answers
82k views

Maven check for updated dependencies in repository

Is there a Maven plugin that allows you to check if there are newer versions of dependencies available in the repository? Say, you are using dependency X with version 1.2. Now a new version of X is ...
froethen's user avatar
  • 2,133
194 votes
14 answers
115k views

Problem duplicate class androidx.lifecycle.viewmodel found in modules

I got these errors when I try to run the emulator Duplicate class androidx.lifecycle.ViewModelLazy found in modules jetified-lifecycle-viewmodel-ktx-2.3.1-runtime (androidx.lifecycle:lifecycle-...
Martin GGR's user avatar
  • 1,941
186 votes
35 answers
186k views

Failed to load c++ bson extension

A total node noob here. I've been trying to set up a sample node app but the following error keeps popping up every time I try to run: node app Failed to load c++ bson extension, using pure JS ...
Theja's user avatar
  • 2,448
186 votes
5 answers
289k views

Maven: how to override the dependency added by a library

Here's my generic problem: My project P depends on A which depends on B which depends on C which depends on version 1.0.1 of D. There's a problem with version 1.0.1 of D and I want to force the use of ...
wishihadabettername's user avatar
183 votes
1 answer
79k views

How can I have linked dependencies in a git repo?

In my scripts, I often use libraries (mine or others') that have their own repos. I don't want to duplicate those in my repo and get stuck with updating them every time a new version comes out. ...
Lea Verou's user avatar
  • 23.8k
181 votes
18 answers
319k views

scipy.misc module has no attribute imread?

I am trying to read an image with scipy. However it does not accept the scipy.misc.imread part. What could be the cause of this? >>> import scipy >>> scipy.misc <module 'scipy....
ustroetz's user avatar
  • 6,102
178 votes
10 answers
108k views

What is the difference in Maven between dependency and plugin tags in pom.xml?

Created project with Spring, Hibernate & Maven. My question is what is the logic behind plugin versus dependency ?
Soumyaansh's user avatar
  • 8,900
164 votes
17 answers
134k views

Dependency graph of Visual Studio projects

I'm currently migrating a big solution (~70 projects) from VS 2005 + .NET 2.0 to VS 2008 + .NET 3.5. Currently I have VS 2008 + .NET 2.0. The problem is that I need to move projects one by one to new ...
Migol's user avatar
  • 8,381
163 votes
3 answers
136k views

What is the difference between "pom" type dependency with scope "import" and without "import"?

Starting from Maven 2.0.9 there is possibility to include <type>pom</type> <scope>import</scope> in the <dependencyManagement> section. As I understand it, it will be ...
grafthez's user avatar
  • 4,011
161 votes
11 answers
62k views

Unit testing code with a file system dependency

I am writing a component that, given a ZIP file, needs to: Unzip the file. Find a specific dll among the unzipped files. Load that dll through reflection and invoke a method on it. I'd like to unit ...
Judah Gabriel Himango's user avatar
155 votes
4 answers
154k views

HintPath vs ReferencePath in Visual Studio

What exactly is the difference between the HintPath in a .csproj file and the ReferencePath in a .csproj.user file? We're trying to commit to a convention where dependency DLLs are in a "releases" svn ...
toasteroven's user avatar
  • 2,780
154 votes
7 answers
221k views

Downloading all maven dependencies to a directory NOT in repository?

I started to convert my project to maven because I needed to use a library that was distributed in binary form over maven only, but after banging my head against the wall on it for far too long I've ...
chubbsondubs's user avatar
  • 38.2k
153 votes
8 answers
208k views

Print a list of all installed node.js modules

In a node.js script that I'm working on, I want to print all node.js modules (installed using npm) to the command line. How can I do this? console.log(__filename); //now I want to print all ...
Anderson Green's user avatar
149 votes
1 answer
31k views

What does '->' (arrow) mean in gradle's dependency graph?

I'm trying to run some Android tests, however, the compiler complains that multiple dex files exist. Multiple dex files define Lorg/hamcrest/MatcherAssert; So I'm trying to filter duplicated ...
Some Noob Student's user avatar
147 votes
13 answers
194k views

What is Dependency Injection and Inversion of Control in Spring Framework?

"Dependency Injection" and "Inversion of Control" are often mentioned as the primary advantages of using the Spring framework for developing Web frameworks Could anyone explain what it is in very ...
Chillax's user avatar
  • 4,637
146 votes
28 answers
82k views

Xcode 11.4 compile error 'Missing package product <package name>'

When I integrate a local package in my Xcode project everything is fine initially but when i switch branches and want to run the app Xcode gives me the compile error Missing package product <...
blackjacx's user avatar
  • 10.1k
146 votes
5 answers
279k views

Add a dependency in Maven

How do I take a jar file that I have and add it to the dependency system in maven 2? I will be the maintainer of this dependency and my code needs this jar in the class path so that it will compile.
Milhous's user avatar
  • 14.6k
144 votes
2 answers
113k views

Different dependencies for different build profiles

Is it possible to have a different set of dependencies in a maven pom.xml file for different profiles? e.g. mvn -P debug mvn -P release I'd like to pick up a different dependency jar file in one ...
izb's user avatar
  • 51.2k
138 votes
12 answers
100k views

is there a yarn alternative for npm audit?

need pinned resolution feature of yarn, but also want to audit with npm audit? Is there a yarn alternative to npm audit? Or, alternately, will pinning resolutions of dependencies of dependencies work ...
sjt003's user avatar
  • 2,537
137 votes
1 answer
242k views

Android Studio 3.6.1 | Error: "This project uses AndroidX dependencies" [duplicate]

I have updated my Android Studio and the targetSdkVersion (build.gradle) to 29. I migrated to AndroidX. Now the Gradle build gives me these two errors: This project uses AndroidX dependencies, but ...
Sklero Mc's user avatar
  • 1,405
137 votes
3 answers
86k views

When installing packages with Yarn, what does "incorrect peer dependency" mean?

I've just cloned a repo, which recommends the use of Yarn to install dependencies. When I run yarn install, it seems to be okay, but it provides this warning: yarn install v0.20.3 [1/4] 🔍 Resolving ...
shrewdbeans's user avatar
  • 12.3k
136 votes
12 answers
191k views

How do I determine the dependencies of a .NET application?

How do I determine the dependencies of a .NET application? Does Dependency Walker work with managed apps? I've downloaded the latest and tried profiling the app, but it just exits without much of an ...
Brian Stewart's user avatar
135 votes
1 answer
169k views

Install packages in Alpine docker

How do I write Dockerfile commands to install the following in alpine docker image: software-properties-common openjdk-8-jdk python3 nltk Flask
Ankur100's user avatar
  • 1,359
133 votes
4 answers
124k views

Gradle: What is the difference between classpath and compile dependencies?

When adding dependencies to my project I am never sure what prefix I should give them, e.g. "classpath" or "compile". For example, should my dependencies below be compile time or classpath? Also, ...
java123999's user avatar
  • 7,274
132 votes
10 answers
128k views

How to handle dependency injection in a WPF/MVVM application

I am starting a new desktop application and I want to build it using MVVM and WPF. I am also intending to use TDD. The problem is that I don´t know how I should use an IoC container to inject my ...
Fedaykin's user avatar
  • 4,522

1
2 3 4 5
264