Troubles linking my watson studio with my github repo - github

I cannot find a way to link my watson studio with github repo.
I followed these steps:
in watson studio I navigate to integrations and generate an access token.
I copy the string of 40 characters and pasted it in the box.
I navigate to my projects' settings and in the "integrations" section I added the address to my repo from github.
All that done, when I try to share one of my jupyter notebooks i get the following error:
"Se ha producido un error al publicar el notebook Vuelva a intentarlo
más adelante."
in Spanish.
In english should be something like:
"An error took place while publishing your notebook. Try again later."
There is no code, no reference, just try again later. This happens since 3 weeks, renewing the keys, redoing the accounts, etc.
I don't know where to find for further clues to find the problem.
Any help will be really appreciated since having troubles in something so basic is very annoying.
Best

Ok, the issue is that github doesn't name the default branch as master anymore.
Watson Studio looks for this branch and if it doesn't find it gives the above error.
Creating a new branch named "master" and making it the default branch solved the issue.

Related

How to resolve Github Nuget Packages Error 500?

I have packages in my private GitHub account as well as in that of my organisation, which I have always used. Now I wanted to add new to them, so I created a new PAT and tried it out a bit. But now I have the problem that my packages can no longer be accessed. I can access the link:
https://nuget.pkg.github.com/%5BNAME%5D/index.json
but when I try to add this in Visual Studio I get the error message: “Failed to retrieve metadata from source ‘https://nuget.pkg.github.com/%5BNAME%5D/query?q=&skip=0&take=26&prerelease=false&supportedFramework=.NETFramework,Version=v4.8&semVerLevel=2.0.0%E2%80%99.
Response status code does not indicate success: 500 (Internal Server Error).” When I call the link I get the text: {“error”: “The GitHub Packages service encountered an error.”} . Can anyone help me?
PAT has the rights to all repos, as well as write and delete packages.
I have tried deleting all the packages and uploading them again, I have created a PAT with all the permissions and tried this from different PCs on different networks.
Created a Ticket https://support.github.com/
It seems to be a bug with GitHub itself. They've been working on it for almost a month now.

I am trying to get vscode extension gitlab workflow to connect, but get invalid url error

When I launch VSCode with the GitLab workflow extension, I get this error message:
Invalid URL: git#gitlab.com:#####/######.git/
(I have removed address with #).
If I right click and open folder in terminal, I can git push.
When I set up extension, I accepted the GitLab instance and pasted my personal access token.
Do you think I cloned the wrong URL?
This is about GitLab VS Code Extension, code at gitlab-org/gitlab-vscode-extension
First, you should not paste a token for an SSH URL: a token is only used as password for HTTPS URL.
Second, this is followed by gitlab-org/gitlab-vscode-extension issue 385 (initially about HTTPS URL, but with questions around SSH URL as well)
It recommends:
checking the gitlab.instanceUrl setting, or the presence of instanceUrl in your VS Code settings.json.
reviewing the extension logs (CMD+SHIFT+P and enter GitLab: Show extension logs command)
trying to start the VS Code editor, but make sure that the GitLab sidebar is hidden during the start (make sure that you are on, for example, the "explorer" tab when you are closing the VS Code editor so it will start on the "explorer" tab): just to avoid any extension initialization bug.
The error:
[info]: Found gitlab.com in the PAT list and git remotes, using it as the instanceUrl
was seen in gitlab-org/gitlab-vscode-extension issue 307.
And lead to issue 281.
I suggest telling it clearly on the readme to avoid group name in the URL configuration as it is taken from the workspace name.
Note that GitLab 15.0 (May 2022) offers an alternative:
Multiple account support for GitLab Workflow in VS Code
When setting up GitLab Workflow for VS Code, you must provide a token to authenticate to GitLab. This token authenticates you to your GitLab instance as a particular user for checking out code, seeing issues, reviewing merge requests, and more.
In GitLab Workflow 3.44, you can now use multiple tokens to authenticate to the same GitLab instance. This can be great for users who have both work and personal accounts, or accounts with separated duties.
We’ve also improved key storage for tokens, which will now be stored in VS Code’s SecretStorage, and is backed by your operating system keychain.
See Documentation and Issue.
And See GitLab 15.1 (June 2022) adds:
GitLab.com sign-in for GitLab Workflow for VS Code
Getting started with GitLab Workflow for VS Code has been challenging: install the extension, only to learn you needed to follow several extra steps to set the extension up properly. The most difficult aspect of getting started was generating a personal access token with the right scope and adding it to the extension.
Release v3.47.0 of GitLab Workflow now supports OAuth for GitLab.com, removing the need to manually generate a token. This is a huge step in making it easier for you to start using GitLab inside of VS Code.
See Documentation and Epic.

Jira integration in Backstage giving 404 error

I'm currently testing Backstage for my company, and I tried various continuous integration pipelines like Github, Jira, Jenkins, and more. But I'm facing an issue with the Jira plugin. Maybe it's just a bad setup.
In my component, I can see the Jira entity, but every time, it says:
failed to fetch data, status 404: Not Found
When I look in the browser's console (network), I can see this 404, and this is the query used:
http://localhost:7007/api/proxy/jira/api/rest/api/latest/project/undefined
Why do I have undefined? Is it because the jira/project-key variable is not at the right place? Actually, it's in the catalog-info.yaml under metadata.
I followed all documentation I could find, but one section is not enough clear for me. It's about the annotations thing. It says `Add annotation to the yaml config file of a component. I created a component yesterday, but I don't see any file for it.
Thanks in advance.
Ok, I found the solution.
In the documentation, the file, called catalog-info.yaml, is not the one at the Backstage repository's root, but to a file in a different repository that will be used as component template in Backstage.
If you create a new repository (ex a fork from Symfony), you will have to add the file catalog-info.yaml with various informations if you want to use this repository as template for your projects.

How to get current repository in VSTS Code Hub

I am researching on extending visual studio services by adding a code hub. With the help of the online samples and documentation, I am able to add a hub under code hub group. But now the issue is that i am not able find any way in my hub page to know the currently selected repository. Please guide me on this. I am specifically targeting git repositories in my hub.
Edited:
Screenshot Showing the project dropdown , repository dropdown and new custom Code Hub named "Git Graph"
What I need is an option to know which repository is selected while the user is in the custom code hub. the method getWebContext() only lists the information till the project level. Where as it should give me the current repository too.

"page build failed" when pushing a new blog post to github

I've got a blog hosted on github using jekyll bootstrap. It's been working for a while now, but the last new times I've tried to post a new blog page it's failed the pushed to github:
The page build failed with the following error:
page build failed
For information on troubleshooting Jekyll see
https://help.github.com/articles/using-jekyll-with-pages#troubleshooting
If you have any questions please contact GitHub Support.
I've tried deleting the recent posts I've added so that I'm consistent with the "live" version, and I've run jekyll --safe locally (no issues). I can run jekyll --server and run the site locally and all is fine, but when I push it, no joy. I've removed my jekyll gems and its dependencies, and re-added using the versions that match the versions being used by github, and no joy there either.
Before I revert to deleting the entire blog and starting it again, can anyone suggest something else to try?
Fixed it.
For some reason my categories in my posts were surrounded in square brackets which represents a collection - this is not supported any more (likely it was never supported but just let me get away with it). Changed this and all is working now.