Rubberduck: Source Control Issue - crash on init, selecting working directory or cloning

Created on 14 Jun 2016  Â·  37Comments  Â·  Source: rubberduck-vba/Rubberduck

I am trying to use RubberDuck VBA to perform GIT commits of my database. I am able to perform a repeatable crash on my machine when trying to perform any actions to start the connection from MS Access to Git.

  1. Starting from a new database file (C:Users\SpriggsJ\Documents\Database1.accdb)
  2. Close the initial table
  3. Select the "Create" Tab on the ribbon, select "Visual Basic"
  4. Create a new module, by right clicking on "Database1 (Database1)", select "Insert", select "Module"
  5. Save the new module, by pressing Ctrl+S
  6. Name the module "Module 1"
  7. Select "Rubberduck" menu.
  8. Select "Source Control option"
  9. Select the "Settings" tab, and set the settings for User Name, Email Address, Default Repository Location. Click Update.
  10. Click the unlabelled button, with the tool tip "Init New Repo from this Project"
  11. Select a path (C:Users\spriggsj\Documents\RD-Demo), click OK
  12. Crash.

Trace rubberduck.log.txt
Debug rubberduck.log.txt

Similarly:

  1. Pre-initialize the Git Repo using the Github application.
  2. re-open the database file mentioned before
  3. go into VBA
  4. Select "Rubberduck" menu
  5. Select "Source Control"
  6. Click the unlabelled button, with the tool tip "Open working directory"
  7. Select the same path as before, click OK.
  8. Crash

rubberduck.log.txt

I've noticed the same when trying to clone a repo.

This is on Windows 7 Professional, using Microsoft Office Professional 2013.

bug feature-source-control

Most helpful comment

Credit to @comintern for implementing the patch. I'm closing this issue--if it happens again after the next release, please make a new issue.

All 37 comments

No repro.

What can I do to help? Would something like process explorer help, is there a version with enhanced debugging I could run (or you could build) that might identify where the issues are?

I'm behind a corporate proxy with little unfettered internet access, so if there are online resources it's calling out to, that might be an issue?

The machine is an x64, but the version of office is the x86 version, so that might not be helping?

I don't know what else to suggest? Might it be worth populating the repo section of the config file to circumvent any initialisation issues and see if it just "appears"? Fortunately I'm just working on this one project, so if there's a small manual work-around on this issue, I don't mind using it.

It shouldn't be calling out to any external resources, except for Clone. If you could provide a stack trace, or maybe a minimal, verifiable example, it would help. I wonder if there is a stray COM exception I need to catch somewhere? How far does it get in it? Does it crash trying to reparse after the repo is created, or does it crash instantly?

I'm not sure how to provoke a stack trace, and the example I gave before you can't reproduce.

It doesn't create the repo files in the directory when you perform the init, and I can't see anything from the debug or trace files submitted before that would imply it was or wasn't working during opening an existing repo.

I'll run it up in process explorer tomorrow (it's 10:30pm here now) and see if anything screams at me.

Can you enable all logging (Trace level in the settings) and upload the log file from "C:Users{username}\AppData\Roaming\Rubberduck"?

Forgot to add, it does crash immediately.

It's in the original bug report

Oh, right. Thanks for the report, one way or another.

I'll re-run that tomorrow as well though.

Do you know which build you are running? Is it the latest 2.0 beta update 1, or are you building from VS?

Beta1

Cool. At this point, I'm really kind of stumped, but I'll keep an eye out for potential causes.

I don't have access to VS to step through, but might it be worth adding more trace lines to the git sequences of code for a custom build for just me and I can try running that to see what happens?

I'll probably do another release this Friday--would that be soon enough? I'll just stick more logging in the main release.

Sure :) that would be awesome! This project is 3 years old now, it would
just be useful to keep it in git :)
On 14 Jun 2016 22:48, "Hosch250" [email protected] wrote:

I'll probably do another release this Friday--would that be soon enough?

—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/rubberduck-vba/Rubberduck/issues/1814#issuecomment-226026464,
or mute the thread
https://github.com/notifications/unsubscribe/AAN9P0qDKnaQSXKirMkeVzbTI2rLnSH8ks5qLyGggaJpZM4I1Jl9
.

I just hit this too.

Existing project
A few forms, LOTS of code
"Init new repo from this project"
immediate crash.

Here are the Doc Watson logs in the hopes that some of this is useful:
RD Access crash.zip

It seems that the logging was not turned on when it crashed, so I don't have the RD logs. I will attempt to reproduce and provide logs.

I _think_ I finally solved this. The VBE's ActiveProject is probably null. I'll need to check if it is, and if there is only one VBProject, I'll replace it with that. Otherwise, I'll raise an error.

I won't close this until you guys verify it, but I'm pretty sure this is the issue.

That build you provided doesn't work - I get "Rubberduck Could not be loaded, Remove it from the list of available add-ins?" Yes/No.

If I swap back to the Beta1 build, is there something I can perform from the "Immediate Window" to determine whether the condition you're referring to is set?

Just make sure that the VBE.ActiveProject isn't Nothing.

On my version of MS Access, here's what I've got.
capture

Note, VBE.ActiveProject doesn't exist, but VBE.ActiveVBProject does.

I'm getting a similar issue - every time I try to create a new repository, or import one that I've created using git, the VBE and Excel crash and have to restart.

Well, I can't reproduce. I did make a change that might address this, and added logging to try to help me figure out where/what is happening. I'll make a release tonight, so please check it sometime next week.

Will do. Very many thanks for your help so far!

Jon "The Nice Guy" Spriggs

On 17 June 2016 at 16:22, Hosch250 [email protected] wrote:

Well, I can't reproduce. I did make a change that might address this, and
added logging to try to help me figure out where/what is happening. I'll
make a release tonight, so please check it sometime next week.

—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/rubberduck-vba/Rubberduck/issues/1814#issuecomment-226799191,
or mute the thread
https://github.com/notifications/unsubscribe/AAN9PwKmCUanSNAC8i7K-1slhHR8VFo8ks5qMrvBgaJpZM4I1Jl9
.

Please download the updated release and try again.

I hate to pile on, but I'm experiencing the same issue with Excel. Just used the most recent updated release. I used the Init Repo method and it did create the working directory and a copy of all files in the project. It also added a specific log file that is not the in the project which is attached below. Not sure if you need any more specific details, but the RD log is attached as well.

DataSourceManagerForm.zip

rubberduck.zip

@mmorrisisund there is a rubberduck.sourcecontrol.config xml file that gets saved in your user's AppData folder if I recall correctly; this file contains information about the repositories Rubberduck knows about - there have been instances in (much) earlier versions, of that file containing illegitimate (duplicated) data that wrecked the whole SC feature... is that file in the .zip?

We need to make that file more accessible and discoverable... @Hosch250 what do you think?

Nope, but here you go.

SourceControl.zip

Sorry you are having this trouble. I'm running the debug build and cannot reproduce any of this--maybe it is specific to the release build? This seems really, really strange. I don't use many events for this, but I'll check for potential events that are running out of order. It apparently is crashing when the branches tab is refreshing, according to the log--can the rest of you see if you can duplicate the issue with the latest release and upload your logs? I'll definitely keep looking into this.

Latest release works for me :)

Thanks Hosch250

I'm happy for this to be closed, should the other people with issues also have had them resolved in this release.

I've still had this with beta (1 and 2). But it appears to be just me.

I installed the beta today and was consistently crashing when trying to initialize a repo or open a working directory. Based on the earlier comments, I tried to turn on the logging but it would not save any changes I made to the log level selection and clicking on "Show Log Folder" would silently fail. Looking in ~/AppData/Roaming, there was no Rubberduck folder. I uninstalled and tried Beta 1 with the same issue. After uninstalling THAT and then installing 1.4.3, the profile folder was created. After seeing that, I decided to try my luck with the beta again.

I have now upgraded to Beta 2 again and can now set the logging levels but it is now successfully allowing me to connect to my local git and perform commits and such.

Just wanted to put that out there as a possible approach to anyone else experiencing crashing problems.

_Jaw hits the floor_ So _that's_ it!!!! @retailcoder The file _is_ in the same directory as the settings file. @Zak-Michael-Armstrong @mmalixi the way we handle settings changed so the folder is not correctly created on first install. There is an unreleased patch for this that creates the folder when RD boots.

Credit to @comintern for implementing the patch. I'm closing this issue--if it happens again after the next release, please make a new issue.

Anyone know which PR it was for posterity?

That'd be #1870
interestingly that means, that #1841 is related to this.

:+1:

Was this page helpful?
0 / 5 - 0 ratings

Related issues

bclothier picture bclothier  Â·  3Comments

ghost picture ghost  Â·  3Comments

retailcoder picture retailcoder  Â·  4Comments

susnick picture susnick  Â·  3Comments

Gener4tor picture Gener4tor  Â·  3Comments