How to get rid of the hash symbol (`#`) in the URL in UI5-routing? - sapui5

Starting the 1.83.x/1.84.x OpenUI5 versions there is a possibility to omit the hash symbol (#) from the browser routing URL.
The new URL-format vs. the old-one:
https://openui5.hana.ondemand.com/topic/1b6dcd39a6a74f528b27ddb22f15af0d
https://sapui5.hana.ondemand.com/#/topic/1b6dcd39a6a74f528b27ddb22f15af0d
I've checked the OpenUI5 documentation but could not find how to get rid of this # in the URL.
Is it somewhere in manifest.json?

The OpenUI5 Demo Kit is using a custom Router in order to improve its SEO. See commit 4614eb0.
Routing without # is not officially supported yet. There is an enhancement request though: https://github.com/SAP/openui5/issues/2993

Related

GitHub Releases Download URL Redirect Doesn't Seem to Work

I've checked out this here on Stack Overflow, but following what's outlined there, I'm still getting "not found" on pages that I know have releases.
For example, if I want to download the latest URL for something like https://github.com/storybookjs/storybook/releases, for a number of repositories dynamically, why do I get a 404 when I use https://github.com/storybookjs/storybook/releases/latest/download/package.zip
What am I missing here?
Thanks in advance!
It might be easier to use GitHub's API for that, as documented for releases. The URL format is
https://api.github.com/repos/{owner}/{repo}/releases
For example, https://api.github.com/repos/symfony/symfony/releases lists all releases for a PHP package. The JSON node zipball_url contains a link to a ZIP package for each release.

TeamCity REST Api supported requests and names of parameters

I was trying to use the REST API of TeamCity but i can't find a list of all supported requests and the names of parameters. I wanted to look it up in their official documentation (https://confluence.jetbrains.com/display/TCD10/REST+API)
where a link to exactly this list is provided
(http://teamcity:8111/app/rest/application.wadl)
but i just can't connect to it. Seems like the page is down.
I have googled all kinds of stuff in the hope to find this list somewhere else but i couldn't find anything smart.
Does anyone know where to find such a list or can provide one? That would be fantastic.
Thanks
You can find available API on the public teamcity:
https://teamcity.jetbrains.com/app/rest/swagger.json
You can navigate through the response inside the paths and look at supported methods, and required parameters for each API.
You can also access to the .wadl on the public teamcity server:
https://teamcity.jetbrains.com/app/rest/application.wadl
When you are inside the documentation of teamcity, they use teamcity:8111 as your own teamcity, installed on your server.
The URL examples on this page assume that your TeamCity server web UI is accessible via the http://teamcity:8111 URL.
If you download a copy of teamcity, start a copy of the server, and then connect to /app/rest/application.wadl, you will probably get a copy of representation.

How to specify SonarQube rule description as a markdown/html resource file instead of using annotation?

I have my custom rule, let's say with AEM-1 key. So, as it is done here, I make my AEM-1.html resource file with some simple html content and it does not get's picked up by SonarQube 5.1. It refuses to start, because no description is provided for the rule.
I tried different packages names, tried to look for convention in source code etc. What's missing? Is there any documentation on that?
The naming convention is org/sonar/l10n/{plugin key}_{language}/rules/{repository key}/{rule key}.html.
It was documented in http://docs.sonarqube.org/display/DEV/Internationalization at the time rule descriptions supported localization. That's not the case anymore since version 4.2, but these HTML bundles are still supported.
The correct way since version 4.3 is to use the low-level API org.sonar.api.server.rule.RulesDefinition. It allows you to implement any kind over layer over it (xml, json, annotations, ...).

Collecting GitHub project issues statistics programmatically?

I'm collecting GitHub issue statistics over time on our project: total number of issues, number of issues with a particular label, number of issues in a given state (open/closed). Right now, I have a Python script to parse the project webpage with the desired labeling/state for the info I want, e.g., http://github.com/<projectname>/issues?label=<label_of_interest>&state=<state_of_interest>
However, parsing the HTML is fragile since if the GitHub API changes, more often than not, my code fails.
Does someone describe how to use the GitHub API (or barring that, know of some other way, preferably in Python) to collect these statistics without relying on the underlying HTML?
May I be so forward as to suggest that you use my wrapper around the GitHub API for this? With github3.py, you can do the following:
import github3
github = github3.login("braymp", "braymp's super secret password")
repo = github.repository("owner", "reponame")
open_issues = [i for i in repo.iter_issues()]
closed_issues = [i for i in repo.iter_issues(state='closed')]
A call to refresh may be necessary because I don't honestly recall if GitHub sends all of the issue information upon the iteration like that (e.g., replace i.refresh() for i in <generator> as the body of the list comprehensions above).
With those, you can iterate over the two lists and you will be able to use the labels attribute on each issue to figure out which labels are on an issue. If you decide to merge the two lists, you can always check the status of the issue with the is_closed method.
I suspect the actual statistics you can do yourself. :)
The documentation for github3.py can be found on ReadTheDocs and you'll be particularly interested in Issue and Repository objects.
You can also ask further questions about github3.py by adding the tag for it in your StackOverflow question.
Cheers!
I'd take a look at Octokit. Which doesn't support Python currently, but does provide a supported interface to the GitHub API for Ruby.
https://github.com/blog/1517-introducing-octokit
Although this doesn't fully meet your specifications (the "preferably Python" part), Octokit is a fantastic (and official - it's developed by GitHub) way of interacting with the GitHub API. You wrote you'd like to get Issues data. It's as easy as installing, requiring the library, and getting the data (no need for authentication if the project is public).
Install:
gem install octokit
Add this to your Ruby file to require the Octokit library:
require 'octokit'
Although there are a lot of things you can get from Octokit::Client::Issues, you may want to get a paginated list of all the issues in a repository:
Octokit.list_issues('octokit/octokit.rb')
# => [Array<Sawyer::Resource>] A list of issues for a repository.
If you're really keen on using Python, you might want to have a look at the GitHub API docs for Issues. Really, it's as easy as getting a URL like: https://api.github.com/repos/octokit/octokit.rb/issues and get the JSON data (although I'm not familiar with Python, I'm sure these some JSON parsing library); no need for authentication for public repos.

bing maps v7 production URL

I applied on the site bingmaps ajax controll v7. I have before me the task: apply the production URL. Throughout the documentation used by the reference to the map: http://ecn.dev.virtualearth.net/mapcontrol... - this is URL for developers.
Tell me if there is a some sort production URL?
The link in your original question has been truncated so it's a bit hard to see exactly what URL you are attempting to use, but the correct URL for the v7 AJAX map control is:
http://ecn.dev.virtualearth.net/mapcontrol/mapcontrol.ashx?v=7.0
Don't be misled by the fact there's a "dev" in the URL - this is the URL that you'd use for a production app. You might also find this page useful: http://msdn.microsoft.com/en-us/library/gg427624.aspx
The Staging environment reference to the map control is:
http://staging.dev.virtualearth.net/mapcontrol/mapcontrol.ashx?v=6.2
The Production environment reference to the map control is:
http://ecn.dev.virtualearth.net/mapcontrol/mapcontrol.ashx?v=6.2