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

fix: avoid useless config file saves #2520

Draft
wants to merge 1 commit into
base: develop
Choose a base branch
from

Conversation

sanzoghenzo
Copy link
Contributor

It compiles but I haven't tested it yet. Time to 🛌

@jmcouffin
Copy link
Contributor

It does compile indeed but... sorry
image
image

I can say it did appear less frequently while laucnhing like 5x2024 and 5x2023 😃

Retry mechanism is not the solution... but it works for messy process/code 😄_

@sanzoghenzo
Copy link
Contributor Author

I don't have much time now, but may I ask you to run pyrevit clones --debug and see if it says that it is setting/saving a config value?

@jmcouffin
Copy link
Contributor

PS C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit> pyrevit clones --debug
clones = True
Debug: Checking for all: wiki 
Debug: Missing: wiki
Debug: Checking for all: blog
Debug: Missing: blog
Debug: Checking for all: docs
Debug: Missing: docs
Debug: Checking for all: source
Debug: Missing: source
Debug: Checking for all: youtube
Debug: Missing: youtube
Debug: Checking for all: support
Debug: Missing: support
Debug: Checking for all: env
Debug: Missing: env
Debug: Checking for all: update
Debug: Missing: update
Debug: Checking for all: clone
Debug: Missing: clone
Debug: Checking for all: clones
Debug: Checking for all: info
Debug: Missing: info
Debug: Checking for all: open
Debug: Missing: open
Debug: Checking for all: add
Debug: Missing: add
Debug: Checking for all: forget
Debug: Missing: forget
Debug: Checking for all: rename
Debug: Missing: rename
Debug: Checking for all: delete
Debug: Missing: delete
Debug: Checking for all: branch
Debug: Missing: branch
Debug: Checking for all: version
Debug: Missing: version
Debug: Checking for all: commit
Debug: Missing: commit
Debug: Checking for all: origin
Debug: Missing: origin
Debug: Checking for all: deployments
Debug: Missing: deployments
Debug: Checking for all: engines
Debug: Missing: engines
Debug: Checking for all: update
Debug: Missing: update
==> Registered Clones (full git repos)
Debug: Try getting config as dict "environment:clones" 
Debug: Try getting config "environment:clones"
Debug: Config "environment:clones" = "{"dev":"C:\\Users\\Local Admin\\Documents\\GitHub\\pyr-dev\\pyRevit"}"
Debug: Normalizing "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit" 
Debug: Normalized as "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit" 
Debug: Searching for valid clones above: C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit
Debug: Normalizing "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit"
Debug: Normalized as "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit"
Debug: Checking pyRevit clone validity "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit"
Debug: Checking clone validity by directory structure...
Debug: Normalizing "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit\pyrevitlib"
Debug: Normalized as "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit\pyrevitlib"
Debug: Normalizing "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit\pyrevitlib\pyrevit"
Debug: Normalized as "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit\pyrevitlib\pyrevit"
Debug: Checking pyRevit path "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit\pyrevitlib\pyrevit"
Debug: Clone directory structure is valid.
Debug: Checking clone validity by git repo...
Debug: Verifying repo validity "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit"
Debug: Valid pyRevit clone "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit" 
Debug: Valid clone found at: C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit 
Debug: Normalizing "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit"
Debug: Normalized as "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit"
Debug: Normalizing "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit"
Debug: Normalized as "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit"
Debug: Checking pyRevit clone validity "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit"
Debug: Checking clone validity by directory structure...
Debug: Normalizing "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit\pyrevitlib"
Debug: Normalized as "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit\pyrevitlib"
Debug: Normalizing "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit\pyrevitlib\pyrevit"
Debug: Normalized as "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit\pyrevitlib\pyrevit"
Debug: Checking pyRevit path "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit\pyrevitlib\pyrevit"
Debug: Clone directory structure is valid.
Debug: Checking clone validity by git repo...
Debug: Verifying repo validity "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit"
Debug: Valid pyRevit clone "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit"
Debug: Verified clone "dev=C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit"
Debug: Updating config "environment:clones = {"dev":"C:\\Users\\Local Admin\\Documents\\GitHub\\pyr-dev\\pyRevit"}" 
Debug: Saving config file "C:\Users\Local Admin\AppData\Roaming\pyRevit\pyRevit_config.ini"
Debug: Reading image clone parmeters from "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit\.pyrevitargs" 
Debug: Image Path: "https://github.com/pyrevitlabs/pyRevit/archive/master.zip"
Debug: Branch: "master"
Debug: Deployment: "basepublic"
Debug: Url: "https://github.com/pyrevitlabs/pyRevit/archive/master.zip" | Branch: "master" | Deployment: "basepublic"
Debug: "core" : "["bin", "pyrevitlib", "site-packages", "pyRevitfile"]" 
Debug: "corex" : "["bin", "extensions/pyRevitCore.extension", "extensions/extensions.json", "pyrevitlib", "site-packages", "pyRevitfile"]" 
Debug: "base" : "["bin", "extensions/pyRevitCore.extension", "extensions/pyRevitTags.extension", "extensions/pyRevitTools.extension", "extensions/extensions.json", "pyrevitlib", "site-packages", "pyRevitfile"]"
Debug: "basepublic" : "["bin", "extensions/pyRevitCore.extension", "extensions/pyRevitTags.extension", "extensions/pyRevitTools.extension", "extensions/pyRevitTutor.extension", "extensions/extensions.json", "pyrevitlib", "site-packages", "pyRevitfile"]"
Debug: "basex" : "["bin", "extensions", "pyrevitlib", "site-packages", "pyRevitfile"]"
Debug: Normalizing "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit"
Debug: Normalized as "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit"
Debug: Checking pyRevit clone validity "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit"
Debug: Checking clone validity by directory structure...
Debug: Normalizing "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit\pyrevitlib"
Debug: Normalized as "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit\pyrevitlib"
Debug: Normalizing "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit\pyrevitlib\pyrevit"
Debug: Normalized as "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit\pyrevitlib\pyrevit"
Debug: Checking pyRevit path "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit\pyrevitlib\pyrevit"
Debug: Clone directory structure is valid.
Debug: Checking clone validity by git repo...
Debug: Verifying repo validity "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit"
Debug: Valid pyRevit clone "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit"
Debug: Verifying repo validity "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit"
Debug: Normalizing "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit" 
Debug: Normalized as "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit"
Debug: Checking pyRevit clone validity "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit"
Debug: Checking clone validity by directory structure...
Debug: Normalizing "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit\pyrevitlib"
Debug: Normalized as "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit\pyrevitlib"
Debug: Normalizing "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit\pyrevitlib\pyrevit"
Debug: Normalized as "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit\pyrevitlib\pyrevit"
Debug: Checking pyRevit path "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit\pyrevitlib\pyrevit"
Debug: Clone directory structure is valid.
Debug: Checking clone validity by git repo...
Debug: Verifying repo validity "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit"
Debug: Valid pyRevit clone "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit"
Debug: Normalizing "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit\pyrevitlib"
Debug: Normalized as "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit\pyrevitlib"
Debug: Normalizing "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit\pyrevitlib\pyrevit"
Debug: Normalized as "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit\pyrevitlib\pyrevit"
Debug: Normalizing "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit\pyrevitlib\pyrevit\version"
Debug: Normalized as "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit\pyrevitlib\pyrevit\version"
dev | Deploy: "basepublic" | Branch: "pr/sanzoghenzo/2520" | Version: "5.0.0.24174+2300" | Path: "C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit"
==> Registered Clones (deployed from archive/image)
PS C:\Users\Local Admin\Documents\GitHub\pyr-dev\pyRevit> 

@jmcouffin
Copy link
Contributor

image
image

@sanzoghenzo
Copy link
Contributor Author

Thanks, it seems that the check for string equality doesn't work at all since it writes the same exact value (at least my eyes can't find any difference on the smartphone screen) 😓
Will try again asap

@jmcouffin
Copy link
Contributor

Thanks, it seems that the check for string equality doesn't work at all since it writes the same exact value
pyrevit clones --debug

I am running the CLI that is already installed doing so.
Maybe, this does not use the DLL that I build from my dev environment? Are the files you modified and I compile locally part of the regular install of the CLI?
We might look at it the right way

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

Successfully merging this pull request may close these issues.

2 participants