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

simplified git config causes remote upstream rewrite on every run #332

Closed
aschleifer opened this issue Feb 22, 2022 · 9 comments · Fixed by #365
Closed

simplified git config causes remote upstream rewrite on every run #332

aschleifer opened this issue Feb 22, 2022 · 9 comments · Fixed by #365
Labels

Comments

@aschleifer
Copy link
Contributor

If I use a simple config entry like:

~/test/cvspull:
  mypackage: 'git+ssh://[email protected]/mygroup/mypackage.git'

I always see the line about Updating remote origin:

Updating remote origin (ssh://[email protected]/mygroup/mypackage.git) with git+ssh://[email protected]/mygroup/mypackage.git

which then in turn causes a retry of the update.

To fix this issue I have to use a config like this:

~/test/cvspull:
  mypackage:
    url: 'git+ssh://[email protected]/mygroup/mypackage.git'
    remotes:
      origin: 'ssh://[email protected]/mygroup/mypackage.git'

This then works, but I would like to have a more compact/simplified config with only one line per repo.

(repogroup and name have been abstracted, as the used gitlab is internal ;) )

Best regards
Segaja

@tony tony added the bug label Feb 22, 2022
@tony
Copy link
Member

tony commented Feb 22, 2022

@aschleifer Thank you, good catch!

If you want to start a pull request you are welcome. If not I will hopefully get around to it soon - I've also been getting it

@aschleifer
Copy link
Contributor Author

I don't think I'm deep enough in the code to easily do it right now and my python is a bit rusty.

@tony
Copy link
Member

tony commented Feb 22, 2022

@aschleifer No problem, it's about time I give a tests a top-down review

@aschleifer
Copy link
Contributor Author

@tony once this bug is fixed I'm happy to fix the new scripts to use the simplified configuration again. But you can also do it in the same PR where you fix this.

tony added a commit that referenced this issue Feb 27, 2022
- test_config.py -> test_config_file.py
- Add `load_yaml()` test fixture for easier setup of config tests
- `make watch_test_entr` -> `make watch_test`

This makes it easier to recreate regression issues like #332
@aschleifer
Copy link
Contributor Author

@tony just a headsup: since now the new structure is in, i will wait for this fix before i look at the add command and into moving the gitlab generator script into the actual package.

@tony
Copy link
Member

tony commented Mar 2, 2022

@aschleifer Noted, and looking into this during the weekend

@tony
Copy link
Member

tony commented Mar 6, 2022

@aschleifer Fix is still a WIP

Will continue next weekend

After this issue and #338 is fixed, will move onto making libvcs and vcspull easier to read. I originally started this 8 years ago when totally new at python.

@tony tony added this to vcspull Mar 28, 2022
tony added a commit that referenced this issue Apr 3, 2022
tony added a commit that referenced this issue Apr 3, 2022
@tony tony closed this as completed in #365 Apr 3, 2022
tony added a commit that referenced this issue Apr 3, 2022
@tony tony moved this to Done in vcspull Apr 3, 2022
@tony
Copy link
Member

tony commented Apr 3, 2022

@aschleifer If you try pip install --user -U vcspull, is the prerelease any better?

Fix is live is in 1.12.0b0

@tony
Copy link
Member

tony commented Apr 24, 2022

@aschleifer Better with 1.12.0?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

2 participants