Coder Social home page Coder Social logo

Comments (6)

herschel666 avatar herschel666 commented on June 27, 2024

@KillerCodeMonkey Hi. Could you please paste your actual config object here, not the stringified one?

from untool.

KillerCodeMonkey avatar KillerCodeMonkey commented on June 27, 2024

@herschel666 good question :D. I am really new into that whole thing.

our whole .hopsrc.js looks like this:

module.exports = {
  languageTags: ['native-ads'],
  languages: ['de', 'en'],
};

but sadly i do know where the config in untool comes from.
I debugged the code through hops-config to untool and found that peace of code in @untool/core

So as a noob you have to guide me a little bit. maybe this an issue with hops-config because passing functions are not allowed

from untool.

herschel666 avatar herschel666 commented on June 27, 2024

@KillerCodeMonkey Hmm, that config you pasted obviously lacks the very properties, that are causing the error. Without knowing your codebase, I can't tell where those props are defined. Look for a custom Hops preset, that you are consuming in your main app.

Besides, it would be helpful if you could at least confirm, that there's a piece in your final config object, that looks something like this:

{
  config: () => ({
    prop: '[SOME_ENV_VAR]',
  }),
}

from untool.

KillerCodeMonkey avatar KillerCodeMonkey commented on June 27, 2024

@herschel666 thanks for your patience

like i said i am more a noob in the untool/xing world and i do not where the other parts of the config comes from.

Here is the complete output of the config passed to the environmentalize function.

{
      rootDir: '/Users/xxx/dev/xxx/xxx',
      name: '@xingternal/xxx',
      version: '0.3.0',
      managerEntries: [Function: managerEntries],
      config: [Function: config],
      'browsers.0': '> 0.5%',
      'browsers.1': 'last 2 versions',
      'browsers.2': 'Firefox ESR',
      'browsers.3': 'not dead',
      node: 'current',
      locations: [],
      basePath: '',
      assetPath: '/assets/<name>',
      buildDir: '<distDir>',
      serverDir: '<rootDir>/node_modules/.cache/untool',
      serverFile: 'server.js',
      statsFile: 'stats.json',
      https: false,
      host: '[HOST]',
      port: '[PORT]',
      distDir: '<rootDir>/dist',
      gracePeriod: 30000,
      logFormat: ':req[x-forwarded-for] (:remote-addr) - :remote-user [:date[clf]] ":method :url HTTP/:http-version" :status :res[content-length]',
      'logjam.appName': '<name>',
      'logjam.locations': [],
      'userAuth.redirectLoggedOut': true,
      'userAuth.loginAppUrl': null,
      'userAuth.mockLanguageMap.1': 'de',
      'userAuth.mockLanguageMap.2': 'en',
      'userAuth.handleInvalidLoginCookie': true,
      'userAuth.allowSoftLogin': false,
      'languages.0': 'de',
      'languages.1': 'en',
      i18nDir: '<rootDir>/i18n',
      i18nProjectId: '6d96f77dfdb867677f18dd85119815d3',
      'languageTags.0': 'xxx,
      fallbackLanguage: 'en',
      'csrf.trustedOrigins': '.+\\.xing\\.com$',
      'sentry.dsn': '',
      'sentry.environment': '[SENTRY_ENV]',
      'sentry.release': '[APP_REVISION]'
    }

in the repo we are using @xingternal/malt-network, which is using hops-config that calls getConfig with hops as argument.

And the hopsconfig.js in our project is just

module.exports = {
  languageTags: ['native-ads'],
  languages: ['de', 'en'],
};

This is working when i do not upgrade any deps in our yarn.lock. But since one hops dependency updates newer untool versions are used and the problem occurs.

Like i said, maybe it is a hopsconfig problem.

Thanks again mate.

from untool.

KillerCodeMonkey avatar KillerCodeMonkey commented on June 27, 2024

nice, thanks man!

from untool.

janraasch avatar janraasch commented on June 27, 2024

Hi @herschel666, could you give us an ETA on when this is going to land in a 1.10.x-release?

from untool.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.