Find bugs in nopCommerce 4.10 BETA and earn $10

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
5 years ago
Dear community!

We have released a BETA version of nopCommerce 4.10 (find more information here). We would like you to test it and share any bugs you find. For bugs that are not yet identified and mentioned in our Github issue tracker we will be granting $10. Please, share your finding in this topic. After a bug is reported and confirmed by our team, please send us a link to the forum post along with your name via our contact form

This offer is valid only until the official nopCommerce 4.10 release (2-3 weeks)

P.S. Typos and other very small issues are not counted for the monetary bonus, though we would appreciate if you point them out.
5 years ago
Great news!! Thanks.
5 years ago
I am not sure if this is classified as a bug or a feature, but there seems to be a lack of functionality when a customer has an item in their cart and then our admin disables that product before the customer can check out.  When using the one page checkout, the process is looped and there is no notification that they cannot checkout due to this unpublished sku other than some small text under the product name.  Very difficult for customers to see this when there may be 100 sku's in their cart.  I would expect the sku to be automatically removed and a popup stating this, or an error message stating the checkout process cannot be complete because you have invalid sku's in your cart.
5 years ago
Great News !!
5 years ago
Added https://github.com/nopSolutions/nopCommerce/issues/3140
5 years ago
Congratulations to the whole team!
5 years ago
customer registered view

same if condition twice

@if (Model.AllowCustomersToSetTimeZone)
            {
                <div class="fieldset">
                    <div class="title">
                        <strong>@T("Account.Preferences")</strong>
                    </div>
                    <div class="form-fields">
                        @if (Model.AllowCustomersToSetTimeZone)
                        {
                            <div class="inputs">
                                <label asp-for="TimeZoneId" asp-postfix=":"></label>
                                <select asp-for="TimeZoneId" asp-items="Model.AvailableTimeZones"></select>
                                <span asp-validation-for="TimeZoneId"></span>
                            </div>
                        }
                    </div>
                </div>
            }
5 years ago
hezyz wrote:
same if condition twice

Thanks a lot, Hezy! Fixed
5 years ago
In Libraries/Nop.Services/Messages/MessageTokenProvider.cs line 845:

        /// <summary>
        /// Generates an absolute URL for the specified store, routeName and route values
        /// </summary>
        /// <param name="storeId">Store identifier; Pass 0 to load URL of the current store</param>
        /// <param name="routeName">The name of the route that is used to generate URL</param>
        /// <param name="routeValues">An object that contains route values</param>
        /// <returns>Generated URL</returns>
        protected virtual string RouteUrl(int storeId = 0, string routeName = null, object routeValues = null)
        {
            //try to get a store by the passed identifier
            var store = _storeService.GetStoreById(storeId) ?? _storeContext.CurrentStore
                ?? throw new Exception("No store could be loaded");

            //ensure that the store URL is specified
            if (string.IsNullOrEmpty(store.Url))
                throw new Exception("URL cannot be null");

            //generate a URL with an absolute path
            var urlHelper = _urlHelperFactory.GetUrlHelper(_actionContextAccessor.ActionContext);
            var url = new PathString(urlHelper.RouteUrl(routeName, routeValues));

            //remove the application path from the generated URL if exists
            var pathBase = _actionContextAccessor.ActionContext?.HttpContext?.Request?.PathBase ?? PathString.Empty;
            url.StartsWithSegments(pathBase, out url);

            //compose the result
            return Uri.EscapeUriString(WebUtility.UrlDecode($"{store.Url.TrimEnd('/')}{url}"));
        }



This code only send emails with http URLs to customers.
It should return https URLs if available.

var storeUrl = store.SslEnabled ? store.SecureUrl : store.Url;
//compose the result
return Uri.EscapeUriString(WebUtility.UrlDecode($"{storeUrl.TrimEnd('/')}{url}"));
5 years ago
In Presentation/Nop.Web.Framework/Security/Captcha/GReCaptchaValidator.cs line 53:

/// <summary>
        /// Validate
        /// </summary>
        /// <returns></returns>
        public GReCaptchaResponse Validate()
        {
            GReCaptchaResponse result = null;
            var httpClient = new HttpClient();
            var requestUri = string.Empty;
            requestUri = string.Format(RECAPTCHA_VERIFY_URL, SecretKey, Response, RemoteIp);

            try
            {
                var taskResult = httpClient.GetAsync(requestUri);
                taskResult.Wait();
                var response = taskResult.Result;
                response.EnsureSuccessStatusCode();
                var taskString = response.Content.ReadAsStringAsync();
                taskString.Wait();
                result = ParseResponseResult(taskString.Result);
            }
            catch
            {
                result = new GReCaptchaResponse { IsValid = false };
                result.ErrorCodes.Add("Unknown error");
            }
            finally
            {
                httpClient.Dispose();
            }

            return result;
        }


This code does not work when nopCommerce is behind a proxy.

I had to add a WebProxy with the proxy address and a HttpClientHandler which is passed to the HttpClient.

It would be nice if you could add a setting in the administration area to configure a proxy.

Then the code above should have a if proxy is enabled condition.

Here is my code if it may help you. I may have set too many parameters but it currently works well so I won't touch it.

var webProxy = new WebProxy("proxy address")
{
  BypassProxyOnLocal = true,
  Credentials = CredentialCache.DefaultCredentials,
  UseDefaultCredentials = true,
};

var handler = new HttpClientHandler()
{
  UseDefaultCredentials = true,
  Proxy = webProxy,
  PreAuthenticate = true,
};

var httpClient = new HttpClient(handler);
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.