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

Android project fails to build with error "DroidApp/DroidApp/obj/Release/lp/ is not empty" #2183

Closed
manish opened this issue Sep 13, 2018 · 0 comments
Labels
vs-sync For internal use only; creates a VSTS "mirror" issue.
Milestone

Comments

@manish
Copy link

manish commented Sep 13, 2018

Steps to Reproduce

  1. Create an Android project
  2. Select Release config
  3. Close and reopen the project
  4. When "Updating Resources..." is running, click on Build.

Project Bundle

Expected Behavior

Project builds without any issues

Actual Behavior

Since "Updating Resources..." is already in progress, running Build at that time, fails the build with

 [Line]: 3042
 [Description]: Directory /Users/builder/agent/_work/r1/a/XQA.VSMac/XQA.VisualStudioMac/TestResults/26ff4d25/
TestAndroidEnableAOTEnterprise/Temp/DroidApp/DroidApp/obj/Release/lp/ is not empty
 [File]: Xamarin.Android.Common.targets
 [Project]: DroidApp"

Diagnostic Build Output

Version Information

About VS for Mac

Log File

VS Mac Ide.log

Screen Recording

VS bug #690373

jonathanpeppers added a commit to jonathanpeppers/xamarin-android that referenced this issue Sep 13, 2018
…n first build

Fixes: xamarin#2183
Context: xamarin#2177
Context: xamarin#1878
Context: http://work.devdiv.io/661455

We are seeing reports of issues related to VS for Mac displaying
`Updating Android Resources...` in the title bar, and a build running
at the same time.

This is effectively running two commands at the same time:

    msbuild YourAndroid.csproj /t:UpdateAndroidResources
    msbuild YourAndroid.csproj /t:Build

In the case such as xamarin#2183, we get the failure:

    Task "RemoveDirFixed"
        Xamarin.Android.Common.targets(3042,2): error : Directory /Users/builder/agent/_work/r1/a/XQA.VSMac/XQA.VisualStudioMac/TestResults/26ff4d25/TestAndroidEnableAOTEnterprise/Temp/DroidApp/DroidApp/obj/Release/lp/ is not empty

In this case, the error is coming from
`_CleanIntermediateIfNuGetsChange`, which has an issue we can improve.
The target is *meant* to only run when NuGets change, but is currently
running on a first build.

If we skip the call to `_CleanMonoAndroidIntermediateDir` if
`$(_AndroidNuGetStampFile)` does not exist, then our
`_CleanIntermediateIfNuGetsChange` target will only clean files in
later builds when NuGets change.

I've not found anything we can do for the root cause of the VS for Mac
issue, but this will at least help matters on the initial build.
jonathanpeppers added a commit to jonathanpeppers/xamarin-android that referenced this issue Sep 17, 2018
…n first build

Fixes: xamarin#2183
Context: xamarin#2177
Context: xamarin#1878
Context: http://work.devdiv.io/661455

We are seeing reports of issues related to VS for Mac displaying
`Updating Android Resources...` in the title bar, and a build running
at the same time.

This is effectively running two commands at the same time:

    msbuild YourAndroid.csproj /t:UpdateAndroidResources
    msbuild YourAndroid.csproj /t:Build

In the case such as xamarin#2183, we get the failure:

    Task "RemoveDirFixed"
        Xamarin.Android.Common.targets(3042,2): error : Directory /Users/builder/agent/_work/r1/a/XQA.VSMac/XQA.VisualStudioMac/TestResults/26ff4d25/TestAndroidEnableAOTEnterprise/Temp/DroidApp/DroidApp/obj/Release/lp/ is not empty

In this case, the error is coming from
`_CleanIntermediateIfNuGetsChange`, which has an issue we can improve.
The target is *meant* to only run when NuGets change, but is currently
running on a first build.

If we skip the call to `_CleanMonoAndroidIntermediateDir` if
`$(_AndroidNuGetStampFile)` does not exist, then our
`_CleanIntermediateIfNuGetsChange` target will only clean files in
later builds when NuGets change.

I've not found anything we can do for the root cause of the VS for Mac
issue, but this will at least help matters on the initial build.
jonpryor pushed a commit that referenced this issue Sep 19, 2018
…n first build (#2184)

Fixes: #2183
Context: #2177
Context: #1878
Context: dd36614
Context: http://work.devdiv.io/661455

We are seeing reports of issues related to Visual Studio for Mac
displaying "Updating Android Resources..." in the title bar, and a
build running at the same time.

This is effectively running two commands at the same time:

	msbuild YourAndroid.csproj /t:UpdateAndroidResources
	msbuild YourAndroid.csproj /t:Build

In the case such as Issue #2183, we get the failure:

	Task "RemoveDirFixed"
	    Xamarin.Android.Common.targets(3042,2): error : Directory /Users/builder/agent/_work/r1/a/XQA.VSMac/XQA.VisualStudioMac/TestResults/26ff4d25/TestAndroidEnableAOTEnterprise/Temp/DroidApp/DroidApp/obj/Release/lp/ is not empty

In this case, the error is coming from the
`_CleanIntermediateIfNuGetsChange` target, which has an issue we can
improve.  The target is *meant* to only run when NuGets change, but
is currently running on a first build.

If we skip the call to the `_CleanMonoAndroidIntermediateDir` target
if `$(_AndroidNuGetStampFile)` does not exist, then our
`_CleanIntermediateIfNuGetsChange` target will only clean files in
later builds when NuGets change.

I've not found anything we can do for the root cause of the
Visual Studio for Mac issue, but this will help on initial builds.
@jonathanpeppers jonathanpeppers added this to the d16-0 milestone Sep 24, 2018
@jonathanpeppers jonathanpeppers added the vs-sync For internal use only; creates a VSTS "mirror" issue. label Sep 24, 2018
dellis1972 pushed a commit that referenced this issue Oct 2, 2018
…n first build (#2184)

Fixes: #2183
Context: #2177
Context: #1878
Context: dd36614
Context: http://work.devdiv.io/661455

We are seeing reports of issues related to Visual Studio for Mac
displaying "Updating Android Resources..." in the title bar, and a
build running at the same time.

This is effectively running two commands at the same time:

	msbuild YourAndroid.csproj /t:UpdateAndroidResources
	msbuild YourAndroid.csproj /t:Build

In the case such as Issue #2183, we get the failure:

	Task "RemoveDirFixed"
	    Xamarin.Android.Common.targets(3042,2): error : Directory /Users/builder/agent/_work/r1/a/XQA.VSMac/XQA.VisualStudioMac/TestResults/26ff4d25/TestAndroidEnableAOTEnterprise/Temp/DroidApp/DroidApp/obj/Release/lp/ is not empty

In this case, the error is coming from the
`_CleanIntermediateIfNuGetsChange` target, which has an issue we can
improve.  The target is *meant* to only run when NuGets change, but
is currently running on a first build.

If we skip the call to the `_CleanMonoAndroidIntermediateDir` target
if `$(_AndroidNuGetStampFile)` does not exist, then our
`_CleanIntermediateIfNuGetsChange` target will only clean files in
later builds when NuGets change.

I've not found anything we can do for the root cause of the
Visual Studio for Mac issue, but this will help on initial builds.
@xamarin xamarin locked as resolved and limited conversation to collaborators Jun 7, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
vs-sync For internal use only; creates a VSTS "mirror" issue.
Projects
None yet
Development

No branches or pull requests

2 participants