Registry error when using Selenium webdriver with Chrome - google-chrome

The error occurs when running the illustrative example of Selenium-Webdriver with the latest Chromedriver executable. Chrome is correctly launched but there's an error in the console.
I am using Windows 10.
run>>regedit>>Chrome.
Computer\HKEY_LOCAL_MACHINE\SOFTWARE\Google\Chrome ::
I am able to get only this path.
HKLM\SOFTWARE\Policies\Google\Chrome:: this path is not availble.
2212:9152:0703/185315.194:ERROR:install_util.cc(589)] Unable to create registry key HKLM\SOFTWARE\Policies\Google\Chrome for reading result=2 [2212:196:0703/185315.598:ERROR:cache_util_win.cc(20)] Unable to move the cache: 5 [2212:196:0703/185315.598:ERROR:cache_util.cc(134)] Unable to move cache folder C:\Users\Anchal\AppData\Local\Google\Chrome\User Data\ShaderCache\GPUCache to C:\Users\Anchal\AppData\Local\Google\Chrome\User Data\ShaderCache\old_GPUCache_000 [2212:196:0703/185315.598:ERROR:disk_cache.cc(169)] Unable to create cache

jarmake posted the solution of this error on github issues:
He made a little tutorial, I'll paste here but if you want the original post, here the source.
Open registry with regedit (just click on Windows start menu and
start typing regedit, it should come up)
From the registry explorer, expand HKEY_LOCAL_MACHINE, and from there
expand SOFTWARE Expand Policies. I was missing everything from this
point.
So what I had to do was to select the Policies by left clicking on
it, and then right click and from the context menu select New > Key
and name it Google. Once that is created, select that and right click
and again select New > Key and name that Chrome.
Select that folder, and right click. Choose New > String. Name it as
MachineLevelUserCloudPolicyEnrollmentToken and leave the value empty.
If you alreade have Google and Chrome under Policies, I think only
adding the key as in step 6 should work. I've attached a picture to
show how it should look like when it's done.
And just as a clarifier. This is under SOFTWARE/Policies, not
directly under SOFTWARE.

Related

How to force Chrome to always open as application without command line or shortcut

How are you?
I hope you are safe and sound.
I was wondering how can edit the Windows 10 in order to make chrome/edge to always open always open as the following flags:--app and -userdatadir=C:/temp
Don't want via shortcut or command line.
Thanks.
From your previous comment, I understand that you want to set the User Data Directory using the registry key for the MS Edge Chromium browser.
Here, I am showing you 2 approaches. Using registry key and using group policy.
Below are the steps to set the User Data Directory using the registry key.
Open Registry editor.
Browse to the location below.
Computer\HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Edge
Create a new string value and name it as UserDataDir.
Doubble click on it and set the directory value.
Close the Registry editor and relaunch the MS Edge browser.
Below are the steps to set the User Data Directory using the Group policy.
Open Local group policy editor.
Browse to the location below.
Computer configuration -> Administrative templates -> Microsoft Edge
Find and double click on Set the user data directory policy.
Click on enabled option and then set the desire value.
Close the Local group policy editor and relaunch the MS Edge browser.
Reference:
Create Microsoft Edge user data directory variables

cannot stop Chrome from updating from 43 to 44

I am using Selenium and Chrome to write a web test, yesterday my Chrome updated to 44 and now my test does not work, I know that it is an issue with Chrome 44 and we need to wait till the new version is given out.
So I am trying to go bake to chrome 43, i do:
1) Uninstall chrome 44
2) Install chrome 43
but as soon as the installation is done it automatically opens the chrome and it is 44 again !! I went to Run->Service.msc and disabled my chrome to update automatically, but it does not work. I remove the Update folder in User->Myname->AppData->Local->Google->Update but it does not work,
and there is nothing related to updating at chrome://plugins.
I AM STUCK
PLEASE HELP :(
I did all sulosion posted on line but non of them worked,
Have spent a loooong time trying to disable updates (literally hours, reading forums and testing various (some exotic) solutions), and this was driving me crazy. But there what seems an infallible solution (see further down).
Even using the official Google page with the templates did NOTHING : https://support.google.com/installer/answer/146164?hl=en
I followed scrupulously the instructions of that page, the keys in the registry are all correct, but still going to the "About Google Chrome" when the program is opened, I can see the wheel going around and a few seconds later the update is forced and done.
I have tried using the standalone installer of Google, on a Windows 8.1 machine 64Bits - and yes all the keys are set to :
Dword: AutoUpdateCheckPeriodMinutes Value: 0
Dword: DisableAutoUpdateChecksCheckboxValue Value: 1
Dword: UpdateDefault Value: 0
Dword: Update{8A69D345-D564-463C-AFF1-A69D9E530F96} Value: 0
... both in HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Google\Update AND HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Policies\Google\Update since it is a 64-bit machine.
So the radical solution to prevent the auto-update, if that helps anyone, is to just purely sort the program responsible for the updates itself! (Just deleting it, OR saving a copy, OR renaming it OR even better just in case I one day need to do an update: Zip the content for future potential re-use).
Easy solution :
1- Go to "C:\Program Files (x86)\Google\ and find the folder "update".
2- There are a couple of options to choose from:
A) first method: Rename the folder:
- Right click > Rename > from Update.bak to Update2.bak for example.
- Now launch Chrome: NO MORE UPDATES!! since it can not find the update program !! Finished.
B) second method: Zip the folder:
- Zip the entire folder by making an archive. (Right click the "Update" folder > Send to Compressed (zip) folder)
- A window might ask you to backup/zip and place it on the desktop, click yes. (message: Windows cannot create the compressed folders here. Do you want to be placed on the desktop instead?)
- Move the newly created zip file to the original location. A new window security might pop up > click continue. (message: You need administrator permission to copy this file). [This will be what to unzip if one day you decide to update Chrome - Just remember that when unzipped it will have the following structure : Update > Update > then all the content of the folder. Remember to move everything from inside the second update folder (copy paste) one level up so that is becomes : Update > then all the content of the folder].
- Now that you have a copy just delete the "Update" folder.
- Now launch Chrome: NO MORE UPDATES!! since it can not find the update program !! Finished.
Good luck and Enjoy.
As per Chromium
Turning off Auto-Updates on Windows
To turn off auto-updates of Google Chrome on Windows, you need to instruct Google Update to not update it. To do this, you can either:
Use the Google Update ADM templates provided on this page or as described in this article.
Set the value of
HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Google\Update\AutoUpdateCheckPeriodMinutes
to the REG_DWORD value of "0".
You can check for Mac and Linux in the first Link
To get rid of Chrome 44 and go back to 43 I downloaded a stand-alone version of chrome 43 which is an .exe file and I just double clicked on it and it was installed on my computer WITHOUT updating to Chrome 44, to find the link to Chrome 43 have a look to RobW comments to my question above and if the link is stale you can just Google for Chrome Stand-alone, or go to the bottom of this page Google Chrome 64-bit Offline Installer| 45.7 MB.
Have Fun :)

WebStorm/PhpStorm, issue with terminal on Windows 10

I decided to try Windows 10, but having problem to make terminal works inside WebStorm/PhpStorm.
When I open terminal, sometimes it's completely black, sometimes it loads the project folder but I cannot type there. There is a way to run it in the external window, but I just got accustomed to work with console like internal window inside WebStorm/PhpStorm...
I tried cmd, Power Shell - same results.
Any ideas?
Workaround: Terminal works fine in Windows 10 if you use legacy console.
To do so, open a command prompt window, right click on the title, then select Properties. At the bottom, check "Use legacy console". Confirm the dialog window and go back to WebStorm to launch a new terminal. It should work.
In any case, this is the ticket to watch after:
https://youtrack.jetbrains.com/issue/IDEA-143300 -- star/vote/comment to get notified on progress.
UPDATE:
This issue has now been resolved -- the fix will arrive in next major version -- PhpStorm v10/WebStorm v11 (or whatever that version will be as long as it's based on 142.xx branch or newer).
UPDATE:
For those who have problems with right clicking and finding "Properties" menu entry:
Just for the record: I have confirmation from JetBrains that it will be fixed (i.e. work with non-legacy mode) in WebStorm 11 which is scheduled for the beginning of November. In the EAP version it should already work.

What contract am I not specifying?

When I try to run my Windows Store app, it won't, and shows me this:
..."does not support the contract specified"? What contract? I'm not implementing any contract; I assume it means the Settings contract or some such, but I'm not doing any of those yet.
I went to the Help page suggested, and it says, in part, "To diagnose these errors
There are no sure ways to fix these errors. Use these techniques to diagnose the problem."
The first suggestion is:
Open Event Viewer (on the Windows Start menu, search for Event Viewer.) In Event Viewer, navigate in the tree to the Application and Services Log\Microsoft\Windows\Apps folder.
Filter the view to event Ids: 5900-6000
Examine the log and see what occurred.
Windows 8.1 only brings up web pages when I search for "Event Viewer"
Actually, I did write a utility to catch event logs, and I ran that. I found these:
***Type: Error
Source: Microsoft-Windows-Immersive-Shell
Time Generated: 11/27/2014 15:10:39
Message: Activation of app App.adaf78a74.a8c80.a4ff5.a99ca.a97636d548196_8wekyb3d8bbwe!Designer.App failed with error: -2144927148 See the Microsoft-Windows-TWinUI/Operational log for additional information.
Type: Error
Source: Microsoft-Windows-Immersive-Shell
Time Generated: 11/27/2014 15:20:08
Message: Activation of app axXAndSpace.Visits_qtyjefqf75sa6!App failed with error: -2144927148 See the Microsoft-Windows-TWinUI/Operational log for additional information.***
But where is "Microsoft-Windows-TWinUI/Operational log"?
The second suggestion on the Help page was:
Use the native debugger
Configure the project to run under a native debugger.
In Visual Studio, set the Debugger Type to Native Only on the Debug (Debugging in C++ and JavaScript) page of the property pages of the start-up project.
Look at the exceptions being thrown by looking at the output window. You might want to configure the debugger to stop when these exceptions are thrown.
I did that, but it gave me no more information than previously - nothing at all displays in the Output pane.
What could be the cause of this?
UPDATE
Just to update the progress:
Based on Iris Classon's suggestions, I went to Control Panel to see if my app was installed so that I could uninstall it, but it's not in that list.
If I search for the app by typing its name, it tries to start up - its splash screen displays, but goes no further than that.
I went to Program Files\WindowsApps, and when selecting it got, "You don't currently have persimmons to access this folder, click continue to continually get access"
That leads me to "You have been denied permission to access this folder; to gain access to this folder, you will need to use the security tab"
Click the "security tab" link takes me to that tab, and a "For special permissions or advanced settings, click Advanced"
I do so.
That takes me to a Permissions tab, which says, "You must have Read permissions to view the properties of this object; Click continue to attempt the operation with administrative permissions"
I then selected (one at a time, as that is all it allows):
Trusted Installer : Full control
System: Read, Write, and Execute
System: Full Control
Administrators: Read & Execute
But so far, none of that seems to do anything good.
UPDATE 2
This problem has just "gone away" today; I don't think it was anything I did. I added a UserControl, tried running the app again, and now it runs - I don't see that error message. However, I do see a seemingly unrelated one. (at least I got further).
I just had this problem on a fresh install of Windows 8.1 on my laptop. I'm not sure which one of these steps solved it, but until somebody can give you a more exact answer here is something to try as I am sure you are keen on coding.
Only Store Apps run from VS gives that error, other Store apps work fine.
I first of all changed permissions on my WindowsApps folder under Program Files and made sure that I had full access to the folder and sub folders. Restarted the laptop, still no luck.
Then I set up an admin guest account (just something I tend to do for when I need to record tutorials- so not related to trying to solve the error). Out of curiosity I tried to create and run the same Windows Store App and got an error that another user had installed the app. Strange, how was it installed if it gave me the error that it couldn't activate the app on the main account?
I logged back in as the main user and uninstalled the application (which was showing up as installed), and I can now run any Store App from VS without problems.
Not sure this is an answer since I'm not sure what made it work, but give it a try and hopefully somebody else can clear this us up. I'll investigate further, but I'm on a train right now with poor WiFi connection :)
Best of luck!
I had the same scenario, here are the steps I did to resolve:
I tried to create packages, chose not to associate with the store.
It said that the certificate is expired, I created a new test certificate.
I created the test packages successfully.
Tried to run the project from VS and it finally ran.
I believe all of this had to do with the certificate. very frustrating and time wasting issue.
I also had the same problem and following steps fixed it. Hope it will help some one else.
Open the appxmanifest file
Go to "Packaging" tab
Select "Choose Certificate" and select "Pick from certificate store" and select your cetificate and click on ok

After moving my Windows Store App project I can't compile it because .resw not found

I have a Problem with a Windows Store App.
I moved the folder and now I cant compile it, I get the error:
Fehler 2 File C:\[old path]\Strings\en-US\Resources.resw not found. C:\[new path]\MakePRI
I dont know how to fix it because the app is in the same relative path in the project as before.
any hints for a solution?
This item was probably added to the project with absolute path. You can fix that in one of two ways:
In SolutionExplorer remove Resources.resw from the project. Then click on Show All Files icon to make the file appear in its folder although it's not included in the project (I understand you did copy it over when moving the project). Now right click on the file and select Include In Project. After that you can again turn off Show All Files.
In Solution Explorer right click on the project and select Unload Project. Now right click on the project again and select Edit ProjectName.csproj. In the file find Resources.resw and replace the existing tag (and any subtags) with <PRIResource Include="Strings\en-US\Resources.resw" />. Save the changes and close the file. Right click on the project again and select Reload Project.
I got into this problem and I found an easy solution. Open the project and it will show the error. Now right click on the App name in Solution Explorer (on the right hand side) and select Build.This will set the path again and the project can be run now.