Project

General

Profile

Task #4185

[pyramid] switch routing to be fully pyramid only

Added by Marcin Kuzminski [staff] about 3 years ago. Updated about 1 year ago.

Status:
Closed
Priority:
Normal
Assignee:
-
Category:
-
Target version:
Start date:
05.09.2016
Due date:
% Done:

100%

Estimated time:
(Total: 0.00 h)
Sorting:
Commit Number:

Description

We need to start moving the code back to pyramid. We should start with making routes work only in PYRAMID, if that's possible.

  • need to investigate if we can make it work
  • we should have a one common place to define those like we had before
  • can we support pylons DELETE/PUT fake request mapping, or should we re-do all the routes not to use them (it's really a POST faked by special parameter to mimic DELETE/PUT)

Subtasks

Task #4214: Remove all Pylons DELETE/PUT/UPDATE callsClosed

History

#1 Updated by Daniel D about 3 years ago

One issue with moving urls to pyramid is that generating urls for tests can't use the url generator.

You can't use request.route_path('someroute') unless there is a request context - which means the tests would have to be done as:

url = ADMIN_PREFIX + '/some/route/' + str(id)

vs

url = request.route_path('someroute', id=id)

Although this might be good in actually finding route changing mistakes.

#2 Updated by Daniel D almost 3 years ago

We can add middleware to support the fake _method arg, but it's a better idea to use POST/GET's for everything, since web browsers only support that and the endpoints are not actually REST in the end.

#3 Updated by Marcin Kuzminski [staff] almost 3 years ago

Yes, firstly we should remove all DELETE/UPDATE/PUT fake calls.

  • probably already needs route changing and matching

as for ADMIN prefix, there for sure must be a way to generate urls for tests.

#4 Updated by Marcin Kuzminski [staff] almost 3 years ago

  • Target version changed from v4.4 to v4.5

#5 Updated by Marcin Kuzminski [staff] almost 3 years ago

  • Target version changed from v4.5 to v4.6

#6 Updated by Marcin Kuzminski [staff] over 2 years ago

  • Target version changed from v4.6 to v4.7

#7 Updated by Marcin Kuzminski [staff] over 2 years ago

  • Target version changed from v4.7 to v5.0

#8 Updated by Redmine Integration over 2 years ago

pullrequest created by marcink (status: under_review). https://internal-code.rhodecode.com/rhodecode-enterprise-ce/pull-request/2892

#11 Updated by Marcin Kuzminski [staff] about 1 year ago

  • Status changed from New to Closed

resolved many time ago

Also available in: Atom PDF