Skip to content
This repository has been archived by the owner on Dec 15, 2022. It is now read-only.

Cannot publish new package from windows #780

Closed
1 task done
calebmeyer opened this issue Apr 6, 2018 · 5 comments
Closed
1 task done

Cannot publish new package from windows #780

calebmeyer opened this issue Apr 6, 2018 · 5 comments

Comments

@calebmeyer
Copy link

calebmeyer commented Apr 6, 2018

Prerequisites

Description

I created a new package yesterday, https://github.com/calebmeyer/vim-mode-plus-macros

I went to publish it using apm publish minor, and ran into several issues across the two windows machines I own.

Steps to Reproduce

  1. Create a package using the package generator. Delete all the view related bits, just keep the console.log
  2. Update the package.json to have your name and the correct repository
  3. Open up powershell, then run apm publish minor to publish version 0.1.0

Expected behavior: The package publishes successfully

Actual behavior:
Work laptop: npm throws an error trying to rename the temporary package.json
https://gist.github.com/calebmeyer/bda5031f00e164612af0763b94b7bf32

Home Desktop: git throws an error about not being authenticated, and doesn't let you provide credentials (though it does on push)
https://gist.github.com/calebmeyer/6d77848739d35c706168c1ef890d3c99

Reproduces how often: The first time, until a successful publish

Versions

versions
windows version

Additional Information

My gitconfig only contains my name and email. I installed git with the credential manager on windows.

@calebmeyer
Copy link
Author

I followed @lee-dohm's recommendation to do an apm publish --tag v0.1.0. That worked.

I later made some changes and tried apm publish patch... It worked. So I'm super confused now.

@thomasjo
Copy link
Contributor

thomasjo commented Apr 9, 2018

The npm problem seems to be the same as this: npm/npm#12059. Sadly, that issue has been automatically closed, yet seems unresolved. Scanning through the comments, the problem seems to be caused by the file IO subsystem in Windows, and triggered by anti-virus software, text editors, Windows Search indexing service, etc.

We should investigate whether it's possible to work around the problem in npm by catching these errors, and re-issuing the npm command.

Looking at the error message for the Git credential issue, it looks like you're hitting this issue: git-for-windows/git#327. In the comments near the end there are mentions of a new interactive credential manager. @calebmeyer Can you check whether you're using the new bits? I don't really know whether there are still new and old credential managers on Windows, or whether it's just the new one.

@calebmeyer
Copy link
Author

I am using the credential manager. I'll see about updating my desktop to avoid the issue. In the mean time, I can publish from my laptop just fine now. Guess I just needed to prime the pump.

I'll close the issue for now, since it's resolved for me, and we have a workaround for others (use the --tag flag after doing the other steps manually)

@thomasjo
Copy link
Contributor

thomasjo commented Apr 9, 2018

@calebmeyer If you at some point manage to reproduce the problem, please let us know. If we figure out how to reproduce the problems you encounted, we might be able to fix it properly or at least document how to "prime the pump" 🙇‍♂️

@lee-dohm
Copy link
Contributor

lee-dohm commented Apr 9, 2018

Thanks @calebmeyer for helping us dig into this!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants