Comments (23)
@monsieurtanuki the auth.pl cookie is not in prod in .org yet, it will be deployed early this week.
from smooth-app.
@teolemon Probably linked to the fact that the cookie is null.
from smooth-app.
@stephanegigandet for some reason, the cookie is null.
from smooth-app.
@stephanegigandet We expect the cookie in headers?['set-cookie']
after a call to auth.pl
.
Something has changed recently?
from smooth-app.
it's weird, because I believe nothing has changed server side, this API is superrecent.
@monsieurtanuki did you ever manage to see the new Nutri-Score on products ?
from smooth-app.
it's weird, because I believe nothing has changed server side, this API is superrecent.
Could be a merge issue in off-dart. In my latest PR, I rebuilt the generated files as needed, and found out that the "user" generated file changed, unexpectedly. I'll have a look at it today.
@monsieurtanuki did you ever manage to see the new Nutri-Score on products ?
Never, but as I currently struggle to even run the app due to "macbook/android emulator/api 34" BS I strongly limit my use of the app.
from smooth-app.
@teolemon @stephanegigandet We're supposed to get a "cookie" somewhere, but that's not there.
Response body:
{
"status":1,
"status_verbose":"user signed-in",
"user":{
"admin":0,
"country":"",
"moderator":0,
"name":"the user name",
"preferred_language":"en"
},
"user_id":"grumpf"
}
Response header:
{
connection: keep-alive,
access-control-allow-origin: *,
transfer-encoding: chunked,
date: Mon, 06 May 2024 15:40:35 GMT,
strict-transport-security: max-age=63072000,
access-control-expose-headers: Content-Length,Content-Range,
content-type: application/json; charset=utf-8,
x-xss-protection: 1; mode=block,
server: nginx/1.18.0,
x-request-id: 5gj3d4KDRYZYrtyV,
access-control-allow-headers: DNT,User-Agent,X-Requested-With,If-Modified-Since,Cache-Control,Content-Type,Range,If-None-Match,Authorization,
access-control-allow-methods: HEAD, GET, PATCH, POST, PUT, OPTIONS,
x-download-options: noopen,
x-content-type-options: nosniff,nosniff
}
Our input is a POST to cgi/auth.pl
, with
- header:
{Accept: application/json, User-Agent: - off-dart integration tests, From: grumpf}
- body:
{body: 1, comment: dart API test, user_id: grumpf, password: ****, app_name: off-dart integration tests}
from smooth-app.
Discussed yesterday evening with @stephanegigandet , and nothing has changed server side
from smooth-app.
@teolemon I've just had a look at @g123k's related PRs, and the files are 99% untouched:
- openfoodfacts/openfoodfacts-dart#914: ok
- openfoodfacts/openfoodfacts-dart#916: ok
- openfoodfacts/openfoodfacts-dart#911: slightly different for generated file
user.g.dart
, because the json related build tool was not run after changes touser.dart
I've never seen the new nutriscore logos in the app.
Could it be that the cookie feature was only tested on emulators, and not on devices?
from smooth-app.
I'm sorry I'm abroad and don't have access to a computer.
But as a reminder, the server was not deployed and switching to DEV was mandatory
from smooth-app.
arigatou g123k san.
from smooth-app.
@monsieurtanuki @g123k DEV does not improve the shebang: it's already been deployed to .org if you're logged in: https://fr.openfoodfacts.org/produit/4613448779566/chocapic#
from smooth-app.
from smooth-app.
@teolemon @stephanegigandet Regardless of the new nutriscore being deployed in DEV, TEST or PROD, our problem is that cookies are NOT returned by the PROD server through auth.pl
.
But they are by the TEST server, something like:
set-cookie: session=user_id&openfoodfacts-dart&user_session&NYF1KHwKQe71Wce7EvcJepGqN9lm1cQJzSP52OcnUj5i4n2hnTm6kHJsN0C4hnkW; domain=.openfoodfacts.net; path=/; SameSite=Lax
So as long as we don't get cookie, we won't send them back, and we won't get new nutriscore depending on the sent cookie.
If it's not a matter of code difference between PROD and TEST, maybe it's a server parameter. Worst case scenario: a server parameter that cannot be set to this value in production.
from smooth-app.
It's ok for me after a sign-out/log-in:
Could you confirm this works for you?
from smooth-app.
I don't know if I'm supposed to see it, but anyway I don't see the new formula.
from smooth-app.
I don't know if I'm supposed to see it, but anyway I don't see the new formula.
Or maybe, do your account have moderator rights?
(cc @teolemon)
from smooth-app.
@monsieurtanuki are you using .net, and is your country set to Germany ?
from smooth-app.
(you are a moderator anyway)
from smooth-app.
(but @stephanegigandet made the Nutri-Score generally available outside France on .net)
from smooth-app.
I've just tested successfully with .net
, Andorra and English:
from smooth-app.
Ok, so perfect.
So I guess we can close this issue, isn't it?
from smooth-app.
Indeed
from smooth-app.
Related Issues (20)
- Bad logos for "Signal a problem" in offline
- Empty chip in some cases on price page HOT 1
- Add a pathway to price per kilo HOT 3
- The photo list performs very badly HOT 1
- Crash reports on category addition (and possibly others) on iOS HOT 1
- White on white onboarding? HOT 2
- Add an item about Data Quality in the Contribute Section HOT 2
- F-Droid build failed HOT 3
- The app could disallow Emoji’s in brand names HOT 1
- Hotfix: 4.15.1 HOT 2
- Allow disabling deeplinks in iOS HOT 1
- In editing section, add a deeplink to Hunger Games logo
- Create a "Contribute to your country" link HOT 6
- Add an accessibility setting for visually impaired users
- (Brainstorm) Add a page listing all the features of the app, with icons, and the ability to deep-dive HOT 2
- Upgrade dependencies of the project HOT 1
- Harmonize search screens
- Analytics/Matomo: Add a parameter if the user is logged in
- Add events added to the code in analytics.openfoodfacts.org
- bug on opening deep link for login from nutripatrol
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from smooth-app.